diff mbox

[1/5] KVM test: support kernel -append command line options

Message ID 1277422386-13516-1-git-send-email-lmr@redhat.com (mailing list archive)
State New, archived
Headers show

Commit Message

Lucas Meneghel Rodrigues June 24, 2010, 11:33 p.m. UTC
None
diff mbox

Patch

diff --git a/client/tests/kvm/kvm_vm.py b/client/tests/kvm/kvm_vm.py
index 966fb3c..87b037f 100755
--- a/client/tests/kvm/kvm_vm.py
+++ b/client/tests/kvm/kvm_vm.py
@@ -287,6 +287,9 @@  class VM:
         def add_initrd(help, filename):
             return " -initrd '%s'" % filename
 
+        def add_kernel_cmdline(help, cmdline):
+            return " -append %s" % cmdline
+
         # End of command line option wrappers
 
         if name is None: name = self.name
@@ -394,6 +397,10 @@  class VM:
             kernel = kvm_utils.get_path(root_dir, kernel)
             qemu_cmd += add_kernel(help, kernel)
 
+        kernel_cmdline = params.get("kernel_cmdline")
+        if kernel_cmdline:
+            qemu_cmd += add_kernel_cmdline(help, kernel_cmdline)
+
         initrd = params.get("initrd")
         if initrd:
             initrd = kvm_utils.get_path(root_dir, initrd)