|
@@ -716,7 +716,7 @@ void dma_debug_init(u32 num_entries)
|
|
|
|
|
|
for (i = 0; i < HASH_SIZE; ++i) {
|
|
|
INIT_LIST_HEAD(&dma_entry_hash[i].list);
|
|
|
- dma_entry_hash[i].lock = SPIN_LOCK_UNLOCKED;
|
|
|
+ spin_lock_init(&dma_entry_hash[i].lock);
|
|
|
}
|
|
|
|
|
|
if (dma_debug_fs_init() != 0) {
|
|
@@ -862,7 +862,7 @@ static inline bool overlap(void *addr, u64 size, void *start, void *end)
|
|
|
|
|
|
return ((addr >= start && addr < end) ||
|
|
|
(addr2 >= start && addr2 < end) ||
|
|
|
- ((addr < start) && (addr2 >= end)));
|
|
|
+ ((addr < start) && (addr2 > end)));
|
|
|
}
|
|
|
|
|
|
static void check_for_illegal_area(struct device *dev, void *addr, u64 size)
|