To simplify the workflow for slicing device tree and relocating kernel, we removed U-boot from the booting workflow.
If you are interested in Hart Software Service, please refer to Hart Software Service for more information.
- RISCV GCC toolkit
- Latest qemu with microchip-polarfire support; Our tested version is here
- [Optional] If you want to run our examples, please build or download a RISCV
kernel image and name it as
$(TOP)/linux/arch/riscv/boot/Image
. Our tested kernel version is 5.13 from https://github.com/torvalds/linux.git. The latest version should also work with our device trees.
Before burning HSS to NVMe or write your image to MMC or SD card of your board,
you can also use Qemu to test them. However, the microchip-icicle-kit
model
in qemu is slightly different from the latest board design. Thus, we added an
option ENV=QEMU
in Makefile to set CONFIG_QEMU=1
in code to bypass some
unsupported operations.
make BOARD=slice defconfig
make BOARD=slice ENV=QEMU
cd bypass-uboot
make format DEVKIT=<EXAMPLE>
EXAMPLE |
Example description |
---|---|
EXAMPLE=single |
booting a single kernel in a 4-core machine |
EXAMPLE=slice |
booting one kernel at 0x80000000 using core 1-2 and slice mem 0x80000000- 0x9fffffff and another kernel at 0x1000000000 using core 3-4 and slice mem 0x1000000000- 0x1020000000 |
BOARD |
description |
---|---|
BOARD=slice |
Same board design with mpfs-icicle-kit-es with slicing software support (binding uart0 to E core and uart1 to other 4 U cores before enter kernel; PMP setup for security; etc.) |
BOARD=mpfs-icicle-kit-es |
Original HSS for Polarfire Soc Icicle kit |
Build with ENV=QEMU
.
make BOARD=slice defconfig
make BOARD=slice ENV=QEMU
cd bypass-uboot
make qemu EXAMPLE=${EXAMPLE}
Upon a successful build, you should have a binary file
build/${EXAMPLE}-payload.bin
and a 4G qemu raw image
build/${EXAMPLE}-qemu-sd.img
.
Launch qemu
./bypass-uboot/qemu.sh ./bypass-uboot/build/${EXAMPLE}-qemu-sd.img
The stdio in this terminal connects to serial 0. Now you can connect to serial
1,2,3 via telnet
from other 3 terminals:
telnet localhost 5431
telnet localhost 5432
telnet localhost 5433
If you do not see any output from qemu, it is possible that your qemu's model
is different from the one we tested or you do not set ENV=QEMU when building
hss. The current QEMU model is different from the board, which is why we need
to comment out some boot procedures not supported by qemu
.
make BOARD=slice defconfig
make BOARD=slice
Install
SoftConsole
and open this directory in a project. Select Run non-secure boot mode 1
to
write the HSS to your board.
make format-payload EXAMPLE=${EXAMPLE} DISK=/dev/sdX
In your WSL, run
make qemu EXAMPLE=${EXAMPLE}
Open Win32 Disk Manager
, write this SD image into the first disk for SD card.