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] Location to hook setting ppc_md.enable_pmcs for xen

To: xen-ppc-devel@xxxxxxxxxxxxxxxxxxx
Subject: [XenPPC] Location to hook setting ppc_md.enable_pmcs for xen
From: Christian Ehrhardt <ehrhardt@xxxxxxxxxxxxxxxxxx>
Date: Tue, 27 Mar 2007 12:57:37 +0200
Delivery-date: Tue, 27 Mar 2007 03:56:21 -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: Thunderbird 1.5.0.10 (X11/20070301)
How does the inclusion of the code in the subdir platform/xen work in xenppc-linux - Does it replace the bare metal code in platform/pseries or does it "extend" it in any way? Xen has has at least a completely own define_machine section there so I assume "replace".
The issue is that I ask myself if I should add something like:
a) in function "pSeries_setup_arch" of "arch/powerpc/platforms/pseries/setup.c"
    ...
+   if (?XEN?)
+       ppc_md.enable_pmcs = pseries_xen_enable_pmcs;
m   else if (firmware_has_feature(FW_FEATURE_LPAR))
        ppc_md.enable_pmcs = pseries_lpar_enable_pmcs;
    else
        ppc_md.enable_pmcs = power4_enable_pmcs;
    ...

or

b) go to the xen path and do this in function "xen_setup_arch" of "arch/powerpc/platforms/xen/setup.c"
with something like this:
    ...
        xen_setup_smp();
    #endif

+        ppc_md.enable_pmcs = pseries_xen_enable_pmcs;

        printk(KERN_INFO "Using Xen idle loop\n");
    ...

According to the Makefile of "arch/powerpc/plattforms" both are build anyway. As far as I read it in the code the platform is detected at boot time and the appropriate ppc_md structure gets selected which should be the only xen structure in our case. This would argue for variant b) to implement it in "arch/powerpc/platforms/xen/*" Can someone with more experience in that area please send an ack for b) or correct me?

--

Grüsse / regards, Christian Ehrhardt

IBM Linux Technology Center, Open Virtualization
+49 7031/16-3385
Ehrhardt@xxxxxxxxxxxxxxxxxxx
Ehrhardt@xxxxxxxxxx

IBM Deutschland Entwicklung GmbH
Vorsitzender des Aufsichtsrats: Johann Weihen Geschäftsführung: Herbert Kircher Sitz der Gesellschaft: Böblingen
Registergericht: Amtsgericht Stuttgart, HRB 243294


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

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