Skip to content

Commit

Permalink
General updates.
Browse files Browse the repository at this point in the history
  • Loading branch information
cnlohr committed Nov 23, 2022
1 parent eef31f6 commit 7c30dc1
Show file tree
Hide file tree
Showing 7 changed files with 1,547 additions and 578 deletions.
17 changes: 14 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,22 @@ toolchain : buildroot
#cp buildroot-2022.02.6-config buildroot-2022.02.6/.config
#cp -a custom_kernel_config buildroot-2022.02.6/kernel_config
#cp riscv_Kconfig buildroot-2022.02.6/output/build/linux-5.15.67/arch/riscv/
#cp -a custom_kernel_config buildroot/kernel_config
#cp -a buildroot_config buildroot/.config
cp -a custom_kernel_config buildroot/kernel_config
cp -a buildroot_config buildroot/.config
#mkdir -p buildroot/board/riscv/nommu/patches
make -C buildroot qemu_riscv32_nommu_virt_minimal_defconfig
#make -C buildroot qemu_riscv32_nommu_virt_minimal_defconfig
make -C buildroot

dtbextract :
# Need sudo apt install device-tree-compiler
cd buildroot && output/host/bin/qemu-system-riscv32 -cpu rv32,mmu=false -m 128M -machine virt -nographic -kernel output/images/Image -bios none -drive file=output/images/rootfs.ext2,format=raw,id=hd0 -device virtio-blk-device,drive=hd0 -machine dumpdtb=../dtb.dtb && cd ..
dtc -I dtb -O dts -o dtb.dts dtb.dtb

gendtb :
dtc -I dts -O dtb -o minimal.dtb minimal.dts -S 8192

test_minimaldtb :
cd buildroot && output/host/bin/qemu-system-riscv32 -cpu rv32,mmu=false -m 128M -machine virt -machine dtb=../minimal.dtb -nographic -kernel output/images/Image -bios none

tests :
git clone https://github.com/riscv-software-src/riscv-tests
Expand Down
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,9 @@ output/host/bin/qemu-system-riscv32 -cpu rv32,mmu=false -m 128M -machine virt -n
output/host/bin/qemu-system-riscv32 -cpu rv32,mmu=false -m 128M -machine virt -nographic -kernel output/images/Image -bios none -drive file=output/images/rootfs.ext2,format=raw,id=hd0 -device virtio-blk-device,drive=hd0 -machine dumpdtb=../dtb.dtb
```


## Running from INITRD instead of DISK
* In buildroot: Filesystem Images, check cpio, no compression.
* In kernel:

## Building Tests

Expand Down
Loading

0 comments on commit 7c30dc1

Please sign in to comment.