From 0d1a62b6cad5a00818e26c3cf1f8809bb415d660 Mon Sep 17 00:00:00 2001 From: Krzysztof Halasa Date: Fri, 8 Jan 2010 14:42:36 -0800 Subject: [PATCH] --- yaml --- r: 178929 b: refs/heads/master c: 42d53b4ff7d61487d18274ebdf1f70c1aef6f122 h: refs/heads/master i: 178927: ec8c0f9026b6861fff893eb727eb5bd1eb5cfef4 v: v3 --- [refs] | 2 +- trunk/lib/dma-debug.c | 7 +++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/[refs] b/[refs] index aaafb00cd805..fd6df2fd7798 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: e992cd9b72a18122bd5c958715623057f110793f +refs/heads/master: 42d53b4ff7d61487d18274ebdf1f70c1aef6f122 diff --git a/trunk/lib/dma-debug.c b/trunk/lib/dma-debug.c index cf906201aecf..7d2f0b33e5a8 100644 --- a/trunk/lib/dma-debug.c +++ b/trunk/lib/dma-debug.c @@ -913,6 +913,9 @@ static void check_sync(struct device *dev, ref->size); } + if (entry->direction == DMA_BIDIRECTIONAL) + goto out; + if (ref->direction != entry->direction) { err_printk(dev, entry, "DMA-API: device driver syncs " "DMA memory with different direction " @@ -923,9 +926,6 @@ static void check_sync(struct device *dev, dir2name[ref->direction]); } - if (entry->direction == DMA_BIDIRECTIONAL) - goto out; - if (to_cpu && !(entry->direction == DMA_FROM_DEVICE) && !(ref->direction == DMA_TO_DEVICE)) err_printk(dev, entry, "DMA-API: device driver syncs " @@ -948,7 +948,6 @@ static void check_sync(struct device *dev, out: put_hash_bucket(bucket, &flags); - } void debug_dma_map_page(struct device *dev, struct page *page, size_t offset,