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-ppc-devel

[XenPPC] Document boot argument processing

To: xen-ppc-devel@xxxxxxxxxxxxxxxxxxx
Subject: [XenPPC] Document boot argument processing
From: Amos Waterland <apw@xxxxxxxxxx>
Date: Sun, 1 Oct 2006 00:37:56 -0400
Delivery-date: Sat, 30 Sep 2006 21:38:04 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-ppc-devel-request@lists.xensource.com?subject=help>
List-id: Xen PPC development <xen-ppc-devel.lists.xensource.com>
List-post: <mailto:xen-ppc-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ppc-devel>, <mailto:xen-ppc-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ppc-devel>, <mailto:xen-ppc-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-ppc-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.12-2006-07-14
Hollis requested that boot argument processing be documented.  I have
placed the following text on this wiki:

 http://wiki.xensource.com/xenwiki/XenPPC/BootArguments

---

The boot argument processing for powerpc Xen is much less complex than
it may appear.  Assuming that the 'Simplify bootargs processing' patch
is accepted in some form, the following rules apply:

  1. Arguments from 32-bit wrapper override all else
  2. Builtin arguments in 64-bit image override firmware
  3. Firmware is used if neither of the above exist

It is true that dom0 Linux has its own boot argument processing, but
there is a simple transitive relation between Xen's bootargs and Linux's
bootargs.  That is, Xen first applies the above three rules to decide
what to feed Linux.  Linux then applies its three rules (it orders their
precedence slightly differently) to decide what to feed the kernel proper.

The format of the builtin command line buffer is essentially just a
seperate ELF section, which makes it easy for post-processing tools to
locate it and edit it.  If you have a 2.6.17 or later zImage kernel
available, the following is illustrative:

 $ objdump -h arch/powerpc/boot/zImage | grep cmdline
 2 __builtin_cmdline 00000200  00406274  00406274  00016274  2**2

The format of the builtin command line buffer is simple, so many tools
may one day understand it, but at present the most commonly-used 
tool is `bicl', which is shipped under the LGPL as part of the K42 source:

 http://www.cs.unm.edu/~k42/tools/bicl

The usage of the tool is simple:

 $ bicl
 `builtin-cmdline' manipulates builtin command line arguments
 
  Usage: builtin-cmdline FILE [ARGS]
   -?, --help     Show this help statement.
       --version  Show version statement.
 
  Examples: builtin-cmdline zImage
            builtin-cmdline zImage 'console=ttyS0'

The tool is used every day to edit the builtin command lines of Linux and
Xen binaries as part of an internal IBM project.


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

<Prev in Thread] Current Thread [Next in Thread>
  • [XenPPC] Document boot argument processing, Amos Waterland <=