2024-05-22 06:04:36 +00:00
|
|
|
# The OSDK manifest at the Asterinas root virtual workspace
|
|
|
|
|
# provides default OSDK settings for all packages.
|
|
|
|
|
|
|
|
|
|
# The common options for build, run and test
|
2024-04-12 17:08:36 +00:00
|
|
|
[boot]
|
|
|
|
|
method = "grub-rescue-iso"
|
2024-03-22 05:50:45 +00:00
|
|
|
|
2024-05-22 06:04:36 +00:00
|
|
|
[grub]
|
2025-11-30 02:12:44 +00:00
|
|
|
boot_protocol = "multiboot2"
|
2024-05-22 06:04:36 +00:00
|
|
|
|
|
|
|
|
[qemu]
|
2024-11-04 04:03:18 +00:00
|
|
|
args = "$(./tools/qemu_args.sh normal)"
|
2024-05-22 06:04:36 +00:00
|
|
|
|
|
|
|
|
# Special options for running
|
2024-04-12 17:08:36 +00:00
|
|
|
[run.boot]
|
2024-02-21 08:58:40 +00:00
|
|
|
kcmd_args = [
|
|
|
|
|
"SHELL=/bin/sh",
|
|
|
|
|
"LOGNAME=root",
|
|
|
|
|
"HOME=/",
|
|
|
|
|
"USER=root",
|
|
|
|
|
"PATH=/bin:/benchmark",
|
|
|
|
|
"init=/usr/bin/busybox",
|
|
|
|
|
]
|
2026-02-10 17:32:24 +00:00
|
|
|
init_args = ["/init"]
|
2026-01-12 02:02:10 +00:00
|
|
|
initramfs = "test/initramfs/build/initramfs.cpio.gz"
|
2024-02-21 08:58:40 +00:00
|
|
|
|
2024-05-22 06:04:36 +00:00
|
|
|
# Special options for testing
|
2024-04-24 16:47:52 +00:00
|
|
|
[test.qemu]
|
|
|
|
|
args = "$(./tools/qemu_args.sh test)"
|
2024-02-21 08:58:40 +00:00
|
|
|
|
2024-05-22 06:04:36 +00:00
|
|
|
# Other Schemes
|
|
|
|
|
|
2024-04-12 17:08:36 +00:00
|
|
|
[scheme."microvm"]
|
|
|
|
|
boot.method = "qemu-direct"
|
2024-05-17 15:26:14 +00:00
|
|
|
build.strip_elf = true
|
2024-04-24 16:47:52 +00:00
|
|
|
qemu.args = "$(./tools/qemu_args.sh microvm)"
|
2024-04-12 17:08:36 +00:00
|
|
|
|
|
|
|
|
[scheme."iommu"]
|
|
|
|
|
supported_archs = ["x86_64"]
|
2024-04-24 16:47:52 +00:00
|
|
|
qemu.args = "$(./tools/qemu_args.sh iommu)"
|
2024-04-22 14:23:24 +00:00
|
|
|
|
2024-04-12 17:08:36 +00:00
|
|
|
[scheme."tdx"]
|
|
|
|
|
supported_archs = ["x86_64"]
|
2024-08-09 05:21:52 +00:00
|
|
|
build.features = ["cvm_guest"]
|
2024-04-12 17:08:36 +00:00
|
|
|
boot.method = "grub-qcow2"
|
2024-07-10 08:49:32 +00:00
|
|
|
grub.boot_protocol = "linux"
|
2025-04-11 03:45:36 +00:00
|
|
|
qemu.args = "$(./tools/qemu_args.sh tdx)"
|
2024-09-24 14:14:30 +00:00
|
|
|
|
|
|
|
|
[scheme."riscv"]
|
2025-10-30 03:59:16 +00:00
|
|
|
supported_archs = ["riscv64"]
|
2024-09-24 14:14:30 +00:00
|
|
|
boot.method = "qemu-direct"
|
|
|
|
|
build.strip_elf = false
|
|
|
|
|
|
|
|
|
|
qemu.args = """\
|
2025-10-30 03:59:16 +00:00
|
|
|
-cpu rv64,svpbmt=true \
|
2024-09-24 14:14:30 +00:00
|
|
|
-machine virt \
|
2025-08-25 11:58:32 +00:00
|
|
|
-m ${MEM-:8G} \
|
|
|
|
|
-smp ${SMP-:1} \
|
2024-09-24 14:14:30 +00:00
|
|
|
--no-reboot \
|
|
|
|
|
-nographic \
|
|
|
|
|
-display none \
|
|
|
|
|
-serial chardev:mux \
|
|
|
|
|
-monitor chardev:mux \
|
|
|
|
|
-chardev stdio,id=mux,mux=on,signal=off,logfile=qemu.log \
|
2026-01-12 02:02:10 +00:00
|
|
|
-drive if=none,format=raw,id=x0,file=./test/initramfs/build/ext2.img \
|
|
|
|
|
-drive if=none,format=raw,id=x1,file=./test/initramfs/build/exfat.img \
|
2025-11-17 11:15:55 +00:00
|
|
|
# NOTE: The `/etc/profile.d/init.sh` assumes that `ext2.img` appears as the first block device (`/dev/vda`).
|
|
|
|
|
# The ordering below ensures `x1` (ext2.img) is discovered before `x0`, maintaining this assumption.
|
|
|
|
|
# TODO: Once UUID-based mounting is implemented, this strict ordering will no longer be required.
|
|
|
|
|
-device virtio-blk-device,drive=x1 \
|
2024-09-24 14:14:30 +00:00
|
|
|
-device virtio-blk-device,drive=x0 \
|
|
|
|
|
-device virtio-keyboard-device \
|
|
|
|
|
-device virtio-serial-device \
|
|
|
|
|
-device virtconsole,chardev=mux \
|
|
|
|
|
"""
|
2025-07-08 06:57:23 +00:00
|
|
|
|
2025-10-29 03:37:22 +00:00
|
|
|
[scheme."sifive_u"]
|
|
|
|
|
supported_archs = ["riscv64"]
|
|
|
|
|
build.features = ["riscv_sv39_mode"]
|
|
|
|
|
boot.method = "qemu-direct"
|
|
|
|
|
build.strip_elf = false
|
2025-11-18 03:53:25 +00:00
|
|
|
qemu.with_monitor = true
|
2025-10-29 03:37:22 +00:00
|
|
|
|
|
|
|
|
qemu.args = """\
|
|
|
|
|
-machine sifive_u \
|
|
|
|
|
-m 8G \
|
2025-11-15 10:24:49 +00:00
|
|
|
-smp 5 \
|
2025-10-29 03:37:22 +00:00
|
|
|
-no-reboot \
|
|
|
|
|
-nographic \
|
|
|
|
|
-display none \
|
|
|
|
|
-serial chardev:mux \
|
|
|
|
|
-monitor chardev:mux \
|
|
|
|
|
-chardev stdio,id=mux,mux=on,signal=off,logfile=qemu.log
|
|
|
|
|
"""
|
|
|
|
|
|
2025-07-08 06:57:23 +00:00
|
|
|
[scheme."loongarch"]
|
|
|
|
|
boot.method = "qemu-direct"
|
|
|
|
|
build.strip_elf = false
|
|
|
|
|
|
|
|
|
|
qemu.args = """\
|
|
|
|
|
-machine virt \
|
|
|
|
|
-m 8G \
|
|
|
|
|
-smp 1 \
|
|
|
|
|
--no-reboot \
|
|
|
|
|
-nographic \
|
|
|
|
|
-display none \
|
|
|
|
|
-serial chardev:mux \
|
|
|
|
|
-monitor chardev:mux \
|
|
|
|
|
-chardev stdio,id=mux,mux=on,signal=off,logfile=qemu.log \
|
|
|
|
|
-device virtio-keyboard-pci \
|
|
|
|
|
-device virtio-serial \
|
|
|
|
|
-device virtconsole,chardev=mux \
|
|
|
|
|
-rtc base=utc
|
|
|
|
|
"""
|