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

Re: [Xen-devel] 32-on-64: pvfb issue

To: Keir Fraser <keir@xxxxxxxxxxxxx>
Subject: Re: [Xen-devel] 32-on-64: pvfb issue
From: Gerd Hoffmann <kraxel@xxxxxxx>
Date: Fri, 19 Jan 2007 16:08:47 +0100
Cc: Xen devel list <xen-devel@xxxxxxxxxxxxxxxxxxx>, Markus Armbruster <armbru@xxxxxxxxxx>
Delivery-date: Fri, 19 Jan 2007 07:08:27 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <C1D67BEF.7E38%keir@xxxxxxxxxxxxx>
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>
References: <C1D67BEF.7E38%keir@xxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Thunderbird 1.5.0.9 (X11/20060911)
Keir Fraser wrote:

> Then we would make the protocol name structural: '<arch>-v2' rather than the
> extending an enumeration to 3 and 4 (in your scheme). Or take advantage of
> the stringness and call it '<arch>-grant'.

Hmm, well, I think we never ever should need "<arch>-v2".  It would suck
big time if we manage to layout the structs for some future protocol
version in a way which is abi-dependent *again*.

> Personally I'm of the opinion
> that the architectural ABI is a fundamental component of our protocol (in
> fact, the very component that is tripping us up here!).

Yep.

> And magic numbers
> suck compared with intelligible strings for this kind of thing imo.

We'll need both then.  Strings are certainly nice for human-visible
stuff, but you don't want to strcmp() all the time in the backend.
Wouldn't be a problem for pvfb, but for blkfront/back where the ring
protocol is abi-dependent and thus the backend has to check often.

> I'm not quite as stuck on
> it as I am regarding use of xenbus for this field: it just occurred to me as
> a seemingly neat extensible technique. :-)

How about the patch below?  It adds both names and enums for the
protocols, the enums to be used internally in the backend, the names for
xenbus, plus conversion helpers (not used yet, want to collect feedback
on the idea first).

Location most likely isn't final, not sure where to place that best so
all parties involved can see it, probably xen/include/public/io/

comments?

  Gerd

-- 
Gerd Hoffmann <kraxel@xxxxxxx>

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