WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] [3.0.4 PATCH] fix kernel cmdline compatibility

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [3.0.4 PATCH] fix kernel cmdline compatibility
From: John Levon <levon@xxxxxxxxxxxxxxxxx>
Date: Thu, 4 Jan 2007 19:18:19 +0000
Delivery-date: Thu, 04 Jan 2007 11:16:38 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.9i
# HG changeset patch
# User john.levon@xxxxxxx
# Date 1167936545 28800
# Node ID acda3f65d9797126035cc8cae65d8804415c6036
# Parent  97a82d6d6cf4fa55a9c6a14a50a786dbff6134c0
Xen 3.0.3 pre-pended all configuration prior to the user-specified
args in the boot cmdline. Restore this behaviour to fix incompatabilities with
fragile parsers in some domU kernels.

Signed-off-by: John Levon <john.levon@xxxxxxx>

diff --git a/tools/python/xen/xend/XendConfig.py 
b/tools/python/xen/xend/XendConfig.py
--- a/tools/python/xen/xend/XendConfig.py
+++ b/tools/python/xen/xend/XendConfig.py
@@ -1104,15 +1104,20 @@ class XendConfig(dict):
 
         self['PV_kernel'] = sxp.child_value(image_sxp, 'kernel','')
         self['PV_ramdisk'] = sxp.child_value(image_sxp, 'ramdisk','')
-        kernel_args = sxp.child_value(image_sxp, 'args', '')
+        kernel_args = ""
         
         # attempt to extract extra arguments from SXP config
         arg_ip = sxp.child_value(image_sxp, 'ip')
         if arg_ip and not re.search(r'ip=[^ ]+', kernel_args):
-            kernel_args += ' ip=%s' % arg_ip
+            kernel_args += 'ip=%s' % arg_ip
         arg_root = sxp.child_value(image_sxp, 'root')
         if arg_root and not re.search(r'root=', kernel_args):
             kernel_args += ' root=%s' % arg_root
+
+        # user-specified args must come last: previous releases did this and
+        # some domU kernels rely upon the ordering.
+        kernel_args += " %s" % sxp.child_value(image_sxp, 'args', '')
+
         self['PV_args'] = kernel_args
 
         # Store image SXP in python dictionary format

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] [3.0.4 PATCH] fix kernel cmdline compatibility, John Levon <=