aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorMarek Szyprowski <m.szyprowski@samsung.com>2012-06-13 08:04:58 -0400
committerMarek Szyprowski <m.szyprowski@samsung.com>2012-06-13 08:25:16 -0400
commitfdb1117325ad719dc39e81209bc622d511db70e0 (patch)
treee3920c5e763fd4c1a916e3ec05dd41d543ded3fa /arch
parent4986e5c7cd91817d0f58dd15073c9080d47980cf (diff)
ARM: dma-mapping: fix debug messages in dmabounce code
This patch fixes the usage of uninitialized variables in dmabounce code intoduced by commit a227fb92 ('ARM: dma-mapping: remove offset parameter to prepare for generic dma_ops'): arch/arm/common/dmabounce.c: In function ‘dmabounce_sync_for_device’: arch/arm/common/dmabounce.c:409: warning: ‘off’ may be used uninitialized in this function arch/arm/common/dmabounce.c:407: note: ‘off’ was declared here arch/arm/common/dmabounce.c: In function ‘dmabounce_sync_for_cpu’: arch/arm/common/dmabounce.c:369: warning: ‘off’ may be used uninitialized in this function arch/arm/common/dmabounce.c:367: note: ‘off’ was declared here Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/common/dmabounce.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/arch/arm/common/dmabounce.c b/arch/arm/common/dmabounce.c
index 9d7eb530f95f..aa07f5938f05 100644
--- a/arch/arm/common/dmabounce.c
+++ b/arch/arm/common/dmabounce.c
@@ -366,8 +366,8 @@ static int __dmabounce_sync_for_cpu(struct device *dev, dma_addr_t addr,
366 struct safe_buffer *buf; 366 struct safe_buffer *buf;
367 unsigned long off; 367 unsigned long off;
368 368
369 dev_dbg(dev, "%s(dma=%#x,off=%#lx,sz=%zx,dir=%x)\n", 369 dev_dbg(dev, "%s(dma=%#x,sz=%zx,dir=%x)\n",
370 __func__, addr, off, sz, dir); 370 __func__, addr, sz, dir);
371 371
372 buf = find_safe_buffer_dev(dev, addr, __func__); 372 buf = find_safe_buffer_dev(dev, addr, __func__);
373 if (!buf) 373 if (!buf)
@@ -377,8 +377,8 @@ static int __dmabounce_sync_for_cpu(struct device *dev, dma_addr_t addr,
377 377
378 BUG_ON(buf->direction != dir); 378 BUG_ON(buf->direction != dir);
379 379
380 dev_dbg(dev, "%s: unsafe buffer %p (dma=%#x) mapped to %p (dma=%#x)\n", 380 dev_dbg(dev, "%s: unsafe buffer %p (dma=%#x off=%#lx) mapped to %p (dma=%#x)\n",
381 __func__, buf->ptr, virt_to_dma(dev, buf->ptr), 381 __func__, buf->ptr, virt_to_dma(dev, buf->ptr), off,
382 buf->safe, buf->safe_dma_addr); 382 buf->safe, buf->safe_dma_addr);
383 383
384 DO_STATS(dev->archdata.dmabounce->bounce_count++); 384 DO_STATS(dev->archdata.dmabounce->bounce_count++);
@@ -406,8 +406,8 @@ static int __dmabounce_sync_for_device(struct device *dev, dma_addr_t addr,
406 struct safe_buffer *buf; 406 struct safe_buffer *buf;
407 unsigned long off; 407 unsigned long off;
408 408
409 dev_dbg(dev, "%s(dma=%#x,off=%#lx,sz=%zx,dir=%x)\n", 409 dev_dbg(dev, "%s(dma=%#x,sz=%zx,dir=%x)\n",
410 __func__, addr, off, sz, dir); 410 __func__, addr, sz, dir);
411 411
412 buf = find_safe_buffer_dev(dev, addr, __func__); 412 buf = find_safe_buffer_dev(dev, addr, __func__);
413 if (!buf) 413 if (!buf)
@@ -417,8 +417,8 @@ static int __dmabounce_sync_for_device(struct device *dev, dma_addr_t addr,
417 417
418 BUG_ON(buf->direction != dir); 418 BUG_ON(buf->direction != dir);
419 419
420 dev_dbg(dev, "%s: unsafe buffer %p (dma=%#x) mapped to %p (dma=%#x)\n", 420 dev_dbg(dev, "%s: unsafe buffer %p (dma=%#x off=%#lx) mapped to %p (dma=%#x)\n",
421 __func__, buf->ptr, virt_to_dma(dev, buf->ptr), 421 __func__, buf->ptr, virt_to_dma(dev, buf->ptr), off,
422 buf->safe, buf->safe_dma_addr); 422 buf->safe, buf->safe_dma_addr);
423 423
424 DO_STATS(dev->archdata.dmabounce->bounce_count++); 424 DO_STATS(dev->archdata.dmabounce->bounce_count++);