mirror of
https://github.com/u-boot/u-boot.git
synced 2024-12-03 09:33:38 +08:00
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>
This commit is contained in:
parent
e621c7ab9a
commit
8e67c5d047
@ -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;
|
||||
|
Loading…
Reference in New Issue
Block a user