diff options
Diffstat (limited to 'lib/dma-debug.c')
| -rw-r--r-- | lib/dma-debug.c | 10 | 
1 files changed, 9 insertions, 1 deletions
diff --git a/lib/dma-debug.c b/lib/dma-debug.c index dace71fe41f7..8855f019ebe8 100644 --- a/lib/dma-debug.c +++ b/lib/dma-debug.c @@ -100,7 +100,7 @@ static LIST_HEAD(free_entries);  static DEFINE_SPINLOCK(free_entries_lock);  /* Global disable flag - will be set in case of an error */ -static u32 global_disable __read_mostly; +static bool global_disable __read_mostly;  /* Early initialization disable flag, set at the end of dma_debug_init */  static bool dma_debug_initialized __read_mostly; @@ -1249,6 +1249,14 @@ static void check_sync(struct device *dev,  				dir2name[entry->direction],  				dir2name[ref->direction]); +	if (ref->sg_call_ents && ref->type == dma_debug_sg && +	    ref->sg_call_ents != entry->sg_call_ents) { +		err_printk(ref->dev, entry, "DMA-API: device driver syncs " +			   "DMA sg list with different entry count " +			   "[map count=%d] [sync count=%d]\n", +			   entry->sg_call_ents, ref->sg_call_ents); +	} +  out:  	put_hash_bucket(bucket, &flags);  }  | 
