@@ -42,6 +42,7 @@ def __init__(self, machine):
4242 self .user = 'root'
4343 self .password = None
4444 self .expected_release = None
45+ self .vmlinux = None
4546
4647 def machine_is (self , needle ):
4748 return self .machine .startswith (needle )
@@ -72,6 +73,7 @@ def configure_from_args(self, orig_args):
7273 parser .add_argument ('--mount-cmd' , dest = 'mount_command' , type = str , help = "Command to run in mount point (default 'run')" )
7374 parser .add_argument ('--cmdline' , type = str , help = 'Kernel command line arguments' )
7475 parser .add_argument ('--release-path' , type = str , help = 'Path to kernel.release' )
76+ parser .add_argument ('--kernel-path' , type = str , help = 'Path to kernel (vmlinux)' )
7577 args = parser .parse_args (orig_args )
7678
7779 if args .gdb :
@@ -114,6 +116,9 @@ def configure_from_args(self, orig_args):
114116 if args .release_path :
115117 self .expected_release = read_expected_release (args .release_path )
116118
119+ if args .kernel_path :
120+ self .vmlinux = args .kernel_path
121+
117122 self .compat_rootfs = args .compat_rootfs
118123 self .use_vof = args .use_vof
119124 self .quiet = args .quiet
@@ -125,6 +130,10 @@ def apply_defaults(self):
125130 logging .error ("Couldn't find kernel.release" )
126131 return
127132
133+ if not self .vmlinux :
134+ logging .error ("Can't find kernel vmlinux" )
135+ return
136+
128137 if self .machine_is ('pseries' ):
129138 if self .accel == 'tcg' :
130139 self .machine_caps += ['cap-htm=off' ]
0 commit comments