Message ID | 20210131123606.20702-6-bmeng.cn@gmail.com |
---|---|
State | Accepted |
Commit | b7324b5d5380cddbac7f17bc6229776763c08ee4 |
Delegated to: | Simon Glass |
Headers | show |
Series | Allow booting a 32-bit system with a top memory address beyond 4 GiB | expand |
From: Bin Meng <bin.meng@windriver.com> addr was delcared as fdt_addr_t which is now a 64-bit address. In a 32-bit build, this causes the following warning seen when building ax25-ae350.c: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast] Cast addr with uintptr_t. Signed-off-by: Bin Meng <bin.meng@windriver.com> --- Changes in v2: - new patch: riscv: ax25-ae350: Cast addr with uintptr_t board/AndesTech/ax25-ae350/ax25-ae350.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Applied to u-boot-dm, thanks!
diff --git a/board/AndesTech/ax25-ae350/ax25-ae350.c b/board/AndesTech/ax25-ae350/ax25-ae350.c index 59a43e4dcc..3125233488 100644 --- a/board/AndesTech/ax25-ae350/ax25-ae350.c +++ b/board/AndesTech/ax25-ae350/ax25-ae350.c @@ -77,7 +77,7 @@ int smc_init(void) if (addr == FDT_ADDR_T_NONE) return -EINVAL; - regs = (struct ftsmc020_bank *)addr; + regs = (struct ftsmc020_bank *)(uintptr_t)addr; regs->cr &= ~FTSMC020_BANK_WPROT; return 0;