summaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorRussell King <rmk+kernel@arm.linux.org.uk>2011-07-03 23:24:21 +0100
committerRussell King <rmk+kernel@arm.linux.org.uk>2011-07-03 23:24:21 +0100
commit178783622ce0fd629fad21b33b8f8f56b64c5e45 (patch)
treede3c5133acd86cca859bd24b49d79e2040eeb714 /arch
parentca56a95eedcc95f8fea7b49c87565cd961d74fe2 (diff)
downloadlinux-stable-178783622ce0fd629fad21b33b8f8f56b64c5e45.tar.gz
linux-stable-178783622ce0fd629fad21b33b8f8f56b64c5e45.tar.bz2
linux-stable-178783622ce0fd629fad21b33b8f8f56b64c5e45.zip
ARM: dmabounce: fix map_single() error return value
When map_single() is unable to obtain a safe buffer, we must return the dma_addr_t error value, which is ~0 rather than 0. Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/common/dmabounce.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm/common/dmabounce.c b/arch/arm/common/dmabounce.c
index e5681636626f..841df7d21c2f 100644
--- a/arch/arm/common/dmabounce.c
+++ b/arch/arm/common/dmabounce.c
@@ -255,7 +255,7 @@ static inline dma_addr_t map_single(struct device *dev, void *ptr, size_t size,
if (buf == 0) {
dev_err(dev, "%s: unable to map unsafe buffer %p!\n",
__func__, ptr);
- return 0;
+ return ~0;
}
dev_dbg(dev,