1# $NetBSD: MICROVM,v 1.5 2025/12/05 17:58:11 khorben Exp $ 2# 3# MICROVM kernel configuration, for use with Qemu microvm machine type 4# or Firecracker. 5# Stripped-down configuration with no PCI, use VirtIO over MMIO virtual 6# bus instead. ACPI is disabled as Firecracker doesn't support it, 7# use legacy MP tables instead. 8# 9# Exemple qemu usage on a Linux host to boot a NetBSD guest: 10# 11# qemu-system-x86_64 \ 12# -M microvm,x-option-roms=off,rtc=on,acpi=off,pic=off,accel=kvm \ 13# -m 256 -cpu host,+invtsc -kernel ${KERNEL} \ 14# -append "root=ld0a console=com rw -z" \ 15# -display none -device virtio-blk-device,drive=hd0 \ 16# -drive file=${IMG},format=raw,id=hd0 \ 17# -device virtio-net-device,netdev=net0 \ 18# -netdev user,id=net0,ipv6=off,hostfwd=::2200-:22 \ 19# -global virtio-mmio.force-legacy=false -serial stdio 20 21machine amd64 x86 xen 22 23include "arch/x86/conf/MICROVM.common" 24 25options EXEC_ELF64 # exec ELF binaries 26options MODULAR # new style module(7) framework 27 28options MEMORY_DISK_HOOKS # enable md specific hooks 29options MEMORY_DISK_DYNAMIC # enable dynamic resizing 30