summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThierry Reding <treding@nvidia.com>2015-07-22 15:33:22 -0600
committerTom Warren <twarren@nvidia.com>2015-07-27 15:53:57 -0700
commit8e67c5d0475f65031e5e1687a816eea4eb609164 (patch)
tree5ca080f13088b86f9f8d59f1c51eb6e37b8252c8
parente621c7ab9ace9349787881dea801739860fedcd9 (diff)
downloadu-boot-imx-8e67c5d0475f65031e5e1687a816eea4eb609164.zip
u-boot-imx-8e67c5d0475f65031e5e1687a816eea4eb609164.tar.gz
u-boot-imx-8e67c5d0475f65031e5e1687a816eea4eb609164.tar.bz2
i2c: tegra: Build warning fixes for 64-bit
Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Tom Warren <twarren@nvidia.com> Signed-off-by: Stephen Warren <swarren@nvidia.com> Acked-by: Tom Rini <trini@konsulko.com> Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Tom Warren <twarren@nvidia.com>
-rw-r--r--drivers/i2c/tegra_i2c.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/i2c/tegra_i2c.c b/drivers/i2c/tegra_i2c.c
index fc95646..a428978 100644
--- a/drivers/i2c/tegra_i2c.c
+++ b/drivers/i2c/tegra_i2c.c
@@ -235,7 +235,7 @@ static int send_recv_packets(struct i2c_bus *i2c_bus,
if ((words == 1) && last_bytes) {
local = 0;
memcpy(&local, dptr, last_bytes);
- } else if ((unsigned)dptr & 3) {
+ } else if ((unsigned long)dptr & 3) {
memcpy(&local, dptr, sizeof(u32));
} else {
local = *wptr;
@@ -258,7 +258,7 @@ static int send_recv_packets(struct i2c_bus *i2c_bus,
local = readl(&control->rx_fifo);
if ((words == 1) && last_bytes)
memcpy(dptr, (char *)&local, last_bytes);
- else if ((unsigned)dptr & 3)
+ else if ((unsigned long)dptr & 3)
memcpy(dptr, &local, sizeof(u32));
else
*wptr = local;