kernelRootParams: define agnostic commonkernelRootParams

Let's define agnostic commonkernelRootParams for all hypervisors,
including qemu, firecracker, etc. for now, it has two scenarios,
one for NVDIMM, one for virtio-blk.

Fixes: #1642

Signed-off-by: Penny Zheng <penny.zheng@arm.com>
This commit is contained in:
Penny Zheng
2019-05-10 10:27:24 +08:00
parent 919615fef7
commit 7e6fcddefa
5 changed files with 22 additions and 14 deletions

View File

@@ -54,11 +54,8 @@ const (
fcDiskPoolSize = 8
)
var fcKernelParams = []Param{
var fcKernelParams = append(commonVirtioblkKernelRootParams, []Param{
// The boot source is the first partition of the first block device added
{"root", "/dev/vda1"},
{"rootflags", "data=ordered,errors=remount-ro ro"},
{"rootfstype", "ext4"},
{"pci", "off"},
{"reboot", "k"},
{"panic", "1"},
@@ -70,7 +67,7 @@ var fcKernelParams = []Param{
// Firecracker doesn't support ACPI
// Fix kernel error "ACPI BIOS Error (bug)"
{"acpi", "off"},
}
}...)
func (s vmmState) String() string {
switch s {