diff options
author | Matt Wagantall <mattw@codeaurora.org> | 2015-03-06 17:14:55 -0800 |
---|---|---|
committer | AnilKumar Chimata <anilc@codeaurora.org> | 2015-04-21 21:30:58 +0530 |
commit | b9669094be24cd397e5de90ca280f528e9f90d1a (patch) | |
tree | e440adfa83247ef7dc60e2e7e4f3b58cbcc949d2 /include/linux | |
parent | 18d73a21404e97a9357a5155c63e5dc4e5f71146 (diff) | |
download | qcom-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.h | 2 |
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 */ |