mirror of
https://github.com/u-boot/u-boot.git
synced 2025-04-16 01:44:34 +00:00
ast2600: spl: Use readl for reading mmio
u-boot was crashing in qemu as the modeled hardware enforced overly
strict memory reads.
While this code will work on existing hardware, fix to avoid future issues.
Fixes: 12770d0df0
("ast2600: spl: Add boot mode detection")
Link: https://gitlab.com/qemu-project/qemu/-/issues/2636
Signed-off-by: Joel Stanley <joel@jms.id.au>
This commit is contained in:
parent
c0e978b4b7
commit
7327218681
1 changed files with 2 additions and 2 deletions
|
@ -45,10 +45,10 @@ u32 spl_boot_device(void)
|
|||
}
|
||||
|
||||
/* boot from UART has higher priority */
|
||||
if (scu->hwstrap2 & SCU_HWSTRAP2_BOOT_UART)
|
||||
if (readl(&scu->hwstrap2) & SCU_HWSTRAP2_BOOT_UART)
|
||||
return BOOT_DEVICE_UART;
|
||||
|
||||
if (scu->hwstrap1 & SCU_HWSTRAP1_BOOT_EMMC)
|
||||
if (readl(&scu->hwstrap1) & SCU_HWSTRAP1_BOOT_EMMC)
|
||||
return BOOT_DEVICE_MMC1;
|
||||
|
||||
out:
|
||||
|
|
Loading…
Add table
Reference in a new issue