I’m try add allwinner f1c100s support into qemu.
hardware | status | test result |
---|---|---|
SRAM A1 | OK | uboot ok |
SDRAM | OK | uboot ok |
INTC | TODO | need test |
CCU | OK | uboot ok |
TIMER | OK | uboot ok |
MEMC | TODO | |
UART | OK | uboot ok |
AWUART | TODO | failed on xboot |
LCD | TODO | |
TWI | TODO | need test |
MMC | TODO | need test |
AUDIO | TODO | |
SPI MASTER | OK | uboot ok |
EHCI | TODO | |
GPIO | TODO | |
BOOTROM | OK | spiboot ok |
because qemu can’t emulate DRAM test, uboot is always report 64MiB DRAM.
You can boot from spi nor flash.
I’m write a opensource bootrom for qemu, now it only support boot from spi flash
- use buildroot build firmware: https://github.com/newluhux/licheepi_buildroot
- get qemu source tree and apply patch
git clone https://gitlab.com/qemu-project/qemu /path/to/qemu
cd /path/to/qemu/
git am < xxxx.patch
- build qemu
cd /path/to/qemu/
./configure --cc=gcc --cxx=g++ \
--target-list=arm-softmmu \
--enable-debug --enable-debug-tcg --enable-debug-info
make -j$(nproc)
make check
- run qemu:
cd /path/to/qemu/
./qemu-system-arm -M allwinner-f1c100s -m 32 \
-nographic \
-bios ./bootrom.bin \
-drive if=mtd,file=./flash_8M.bin,format=raw
same with qemu
2023/02/28: start project, try impl allwinner sun6i spi controller.
2023/03/01: try impl bootrom.
2023/03/03: allwinner sun6i spi controller is ok, bootrom is ok.
2023/03/06: upload missing code, fix doc
2023/03/14: fix interrupt controller by zhaosx <shaoxi2010@qq.com> thank.