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] Booting Dom0 with SLES10 on JS20

To: xen-ppc-devel@xxxxxxxxxxxxxxxxxxx
Subject: [XenPPC] Booting Dom0 with SLES10 on JS20
From: Tony Breeds <tony@xxxxxxxxxxxxxxxxxx>
Date: Mon, 17 Jul 2006 15:42:35 +1000
Delivery-date: Sun, 16 Jul 2006 22:42:54 -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.9i
Hi All,
        I thought I'd jot down a few notes about getting Xen and dom0 up and
running on a JS20 blade.

This assumes that you have a working OS on the blade.  I used SLES10-rc3
but debian of other distribution with a kernel 2.6.10+ should be fine.

 1) Install SLOF as per the instructions at:
        http://www-128.ibm.com/developerworks/power/pa-slof/
    After installing SLOF the machine will auto-netboot.  I found that SLOF
    is rather picky about what it will and will not boot.  In fact the /only/
    success I had was net-booting Xen as built in the next step.
    If you have need to switch back to the non-SLOF firmware:
    * When to see "SLOF" appears in the SOL console press any key to be dropped
      into a Firmware prompt
    * O > other-firmware
      will reset the blade and make it boot with the firmware in the "P" side
      The only way I found to get back to SLOF was to pull the blade.

 2) Build Xen and dom0.
    I did this on separate PPC machine but can be done on the JS20 before you
    install SLOF.  (or from a boot the JS20 native firmware)

These are the checkouts from the various mercurial trees I used:
tony@Fandango2:~/Xen/linux-ppc-2.6.hg.working$ hg ident
72c8bc5d88f4+ tip
tony@Fandango2:~/Xen/xenppc-unstable.hg.working/xen$ hg ident
b11a2c7b2989+ tip
    The .config I crafted for the dom0 image is attached.  It's based on the
    xen_maple_defconfig in the linux-ppc-2.6.hg repo.
    * To build linux I did:
      cd path/to/linux-ppc-2.6.hg.working
      cp ~/JS20.config .config
      apply the Makefile_fix.patch (below)
      # There are better ways but I wanted a quick fix.
      make silentoldconfig
      make zImage
    * Now build Xen
      cd path/to/xenppc-unstable.hg.working/xen
      apply the default_bootargs.patch (below)
      # Again there are better ways but I wanted a quick fix.
      make debug=y optimize=0 \
        DOM0_IMAGE=path/to/linux-ppc-2.6.hg.working/arch/powerpc/boot/zImage

      move/copy the "xen" binary to the tftp server with the appropriate name
  3) Reboot and enjoy Xen/Dom0 goodness

Clearly this process doesn't build the tools, or kernel modules but they're
not needed at this point.

If people care to see a boot log or other information I can post it
here.

This setup, auto-netbooting with no way to pass args to xen or dom0
(other than to compiler them in) seems cumbersome are there better
options?

----------------
Ref: makefile_fix.patch

arch/powerpc/platforms/xen deosn't seem to contain a xen_guest.[csS] file
so don't try and build a .o.  The xen_guest section will come from
arch/powerpc/boot/xen_guest.S anyway.

diff -r 72c8bc5d88f4 arch/powerpc/platforms/xen/Makefile
--- a/arch/powerpc/platforms/xen/Makefile       Thu Jun 29 13:04:30 2006 -0400
+++ b/arch/powerpc/platforms/xen/Makefile       Mon Jul 17 15:14:39 2006 +1000
@@ -1,4 +1,4 @@ obj-y   += setup.o evtchn.o hcall.o udbg_x
-obj-y  += setup.o evtchn.o hcall.o udbg_xen.o xen_guest.o
+obj-y  += setup.o evtchn.o hcall.o udbg_xen.o
 
 ifndef CONFIG_XEN_BALLOON
 obj-y += balloon.o
----------------



----------------
Ref: default_bootargs.patch 

As the dom0 image is built into xen, I need to tell dom0 where it's root fs.

diff -r b11a2c7b2989 xen/arch/powerpc/ofd_fixup.c
--- a/xen/arch/powerpc/ofd_fixup.c      Fri Jul 07 13:57:26 2006 -0500
+++ b/xen/arch/powerpc/ofd_fixup.c      Mon Jul 17 15:13:35 2006 +1000
@@ -247,7 +247,7 @@ static ofdn_t ofd_xics_props(void *m)
  * Good things you can stick here:
  *   init=/bin/bash ip=dhcp root=/dev/hda2 ide=nodma 
  */
-static char default_bootargs[] = ""; 
+static char default_bootargs[] = "root=/dev/hda3 ro"; 
 
 static ofdn_t ofd_chosen_props(void *m, const char *cmdline)
 {
----------------

Yours Tony

   linux.conf.au       http://linux.conf.au/ || http://lca2007.linux.org.au/
   Jan 15-20 2007      The Australian Linux Technical Conference!


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

<Prev in Thread] Current Thread [Next in Thread>