aboutsummaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorMatt Wagantall <mattw@codeaurora.org>2015-03-06 17:14:55 -0800
committerAnilKumar Chimata <anilc@codeaurora.org>2015-04-21 21:30:58 +0530
commitb9669094be24cd397e5de90ca280f528e9f90d1a (patch)
treee440adfa83247ef7dc60e2e7e4f3b58cbcc949d2 /include/linux
parent18d73a21404e97a9357a5155c63e5dc4e5f71146 (diff)
downloadqcom-msm-v3.10-b9669094be24cd397e5de90ca280f528e9f90d1a.tar.gz
msm: sps: Make DESC_FULL_ADDR(flags, addr) provide a phys_addr_t result
By convention, both the 'flags' and 'addr' arguments passed to DESC_FULL_ADDR() come from struct sps_iovec, and so neither of these values are 64 bit types. To guarantee that the result of DESC_FULL_ADDR() is large enough to contain at 64bit address, add an explicit phys_addr_t cast inside the macro. Change-Id: Ie1f0ba15448e4386761e60ea22251ceca246d86a Signed-off-by: Matt Wagantall <mattw@codeaurora.org>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/msm-sps.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/msm-sps.h b/include/linux/msm-sps.h
index 125157201bb..ea447a7f896 100644
--- a/include/linux/msm-sps.h
+++ b/include/linux/msm-sps.h
@@ -24,7 +24,7 @@
/* Returns 36bits physical address from 32bit address &
* flags word */
-#define DESC_FULL_ADDR(flags, addr) (((flags & 0xF) << 32) | addr)
+#define DESC_FULL_ADDR(flags, addr) ((((phys_addr_t)flags & 0xF) << 32) | addr)
/* Returns flags word with flags and 4bit upper address
* from flags and 36bit physical address */