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

Re: [Xen-devel] architecture-specific stuff in xend

To: Ewan Mellor <ewan@xxxxxxxxxxxxx>
Subject: Re: [Xen-devel] architecture-specific stuff in xend
From: Hollis Blanchard <hollisb@xxxxxxxxxx>
Date: Wed, 09 Aug 2006 10:07:12 -0500
Cc: xen-ppc-devel <xen-ppc-devel@xxxxxxxxxxxxxxxxxxx>, xen-ia64-devel <xen-ia64-devel@xxxxxxxxxxxxxxxxxxx>, xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>, John Levon <levon@xxxxxxxxxxxxxxxxx>
Delivery-date: Wed, 09 Aug 2006 08:08:09 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <20060809092810.GC19705@xxxxxxxxxxxxxxxxxxxxxx>
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>
Organization: IBM Linux Technology Center
References: <1155051266.30116.152.camel@xxxxxxxxxxxxxxxxxxxxx> <20060808155953.GA20410@xxxxxxxxxxxxxxxxxxxx> <20060809092810.GC19705@xxxxxxxxxxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
On Wed, 2006-08-09 at 10:28 +0100, Ewan Mellor wrote:
> On Tue, Aug 08, 2006 at 04:59:53PM +0100, John Levon wrote:
> 
> > On Tue, Aug 08, 2006 at 10:34:25AM -0500, Hollis Blanchard wrote:
> > 
> > > I'm not sure how/where to instantiate the arch object though.
> > 
> > Presumably you could do the instance() singleton trick?
> 
> This being Python, you don't actually need singletons -- the containing module
> is a singleton in its own right.  You can just write
> 
> Platform.py:
> 
> import os
> 
> if os.uname()[4] in ('ia64', 'ppc64'):
>     def init_reservation(mem_kb):
>         return something_else(mem_kb)
> 
> else:
>     def init_reservation(mem_kb):
>         return mem_kb
> 
> and then
> 
> import Platform
> Platform.init_reservation(100)
> 
> will do the right thing.

Ewan, does this mean you think the proposal is going in the right
direction and you're waiting for a patch?

-- 
Hollis Blanchard
IBM Linux Technology Center


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