harness: fix confusion about whether no kernel/boot driver args is None or an empty list
@@ -33,9 +33,12 @@ class BootModules(object):
self.kernel = None
else:
self.kernel = os.path.join(self.prefix, kernel)
+ if args is None:
+ args = []
self.kernelArgs = args
def add_kernel_args(self, args):
+ if args:
self.kernelArgs.extend(args)
def set_cpu_driver(self, cpu_driver, args=[]):
@@ -44,6 +47,8 @@ class BootModules(object):
self.kernelArgs = []
else :
self.cpu_driver = os.path.join(self.prefix, cpu_driver)
+ if args is None:
+ args = []
self.kernelArgs = args
def set_boot_driver(self, boot_driver, args=[]):
@@ -52,6 +57,8 @@ class BootModules(object):
self.boot_driver_args = []
else :
self.boot_driver = os.path.join(self.prefix, boot_driver);
+ if args is None:
+ args = []
self.boot_driver_args = args
def set_boot_driver_args(self, args):
