5 messages in com.xensource.lists.xen-devel[Xen-devel] [patch] Only skip the ima...
FromSent OnAttachments
Simon Horman28 Aug 2007 02:33 
Keir Fraser28 Aug 2007 03:04 
Horms28 Aug 2007 17:42 
Keir Fraser29 Aug 2007 07:19 
Horms29 Aug 2007 18:37 
Subject:[Xen-devel] [patch] Only skip the image name if it is the image name
From:Simon Horman (hor@verge.net.au)
Date:08/28/2007 02:33:38 AM
List:com.xensource.lists.xen-devel

When kexecing the BOOT_IMAGE isn't provided on the second kernel's command line and thus cmdline_parse() was just skipping over the first parameter.

Observed on ia64

Signed-off-by: Simon Horman <hor@verge.net.au>

Index: xen-unstable.hg/xen/common/kernel.c =================================================================== --- xen-unstable.hg.orig/xen/common/kernel.c 2007-08-28 18:24:54.000000000 +0900 +++ xen-unstable.hg/xen/common/kernel.c 2007-08-28 18:25:01.000000000 +0900 @@ -37,8 +37,9 @@ void cmdline_parse(char *cmdline) /* Skip whitespace and the image name. */ while ( *p == ' ' ) p++; - if ( (p = strchr(p, ' ')) == NULL ) - return; + if (! strncmp(p, "BOOT_IMAGE=", strlen("BOOT_IMAGE=")) ) + if ( (p = strchr(p, ' ')) == NULL ) + return;

for ( ; ; ) {