mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-12-12 06:12:58 +00:00
cb052d7712
Since OpenSBI commit bf3ef53bb7f5 ("firmware: Enable FW_PIC by default"), OpenSBI runs directly at the load address without any code movement. This causes the SPL version of QEMU 'virt' U-Boot does not boot Linux kernel anymore. In that case, OpenSBI is loaded and runs at 0x81000000, and it creates a 512KiB PMP window from that address. When booting the Linux kernel, moving kernel to its linking address 0x80200000 overlaps the PMP window, and a PMP access failure is raised. Update SPL_OPENSBI_LOAD_ADDR to load OpenSBI to a safe address. Reported-by: Yangjie Zhang <pyjmstr@gmail.com> Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Tested-by: Yangjie Zhang <pyjmstr@gmail.com> Reviewed-by: Rick Chen <rick@andestech.com>
72 lines
1.2 KiB
Text
72 lines
1.2 KiB
Text
if TARGET_QEMU_VIRT
|
|
|
|
config SYS_BOARD
|
|
default "qemu-riscv"
|
|
|
|
config SYS_VENDOR
|
|
default "emulation"
|
|
|
|
config SYS_CPU
|
|
default "generic"
|
|
|
|
config SYS_CONFIG_NAME
|
|
default "qemu-riscv"
|
|
|
|
config SYS_TEXT_BASE
|
|
default 0x81200000 if SPL
|
|
default 0x80000000 if !RISCV_SMODE
|
|
default 0x80200000 if RISCV_SMODE && ARCH_RV64I
|
|
default 0x80400000 if RISCV_SMODE && ARCH_RV32I
|
|
|
|
config SPL_TEXT_BASE
|
|
default 0x80000000
|
|
|
|
config SPL_OPENSBI_LOAD_ADDR
|
|
hex
|
|
default 0x80100000
|
|
|
|
config BOARD_SPECIFIC_OPTIONS # dummy
|
|
def_bool y
|
|
select GENERIC_RISCV
|
|
select SUPPORT_SPL
|
|
imply AHCI
|
|
imply SMP
|
|
imply BOARD_LATE_INIT
|
|
imply PCI_INIT_R
|
|
imply SPL_RAM_SUPPORT
|
|
imply SPL_RAM_DEVICE
|
|
imply CMD_PCI
|
|
imply CMD_POWEROFF
|
|
imply CMD_SBI
|
|
imply CMD_SCSI
|
|
imply CMD_PING
|
|
imply CMD_EXT2
|
|
imply CMD_EXT4
|
|
imply CMD_FAT
|
|
imply CMD_FS_GENERIC
|
|
imply DOS_PARTITION
|
|
imply ISO_PARTITION
|
|
imply EFI_PARTITION
|
|
imply SCSI_AHCI
|
|
imply AHCI_PCI
|
|
imply E1000
|
|
imply NVME
|
|
imply PCI
|
|
imply PCIE_ECAM_GENERIC
|
|
imply SCSI
|
|
imply DM_SCSI
|
|
imply SYS_NS16550
|
|
imply SIFIVE_SERIAL
|
|
imply HTIF_CONSOLE if 64BIT
|
|
imply SYSRESET
|
|
imply SYSRESET_CMD_POWEROFF
|
|
imply SYSRESET_SYSCON
|
|
imply VIRTIO_MMIO
|
|
imply VIRTIO_PCI
|
|
imply VIRTIO_NET
|
|
imply VIRTIO_BLK
|
|
imply MTD_NOR_FLASH
|
|
imply CFI_FLASH
|
|
imply OF_HAS_PRIOR_STAGE
|
|
|
|
endif
|