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/64-bit hypercall interface - padding


On 4 Oct 2005, at 17:07, Hollis Blanchard wrote:

We could macro up pointer fields I suppose:
#define XENIF_PTR(type, name) type name
So that macro can be overridden to get 64-bit sized and aligned pointer
fields?

So you would use the above macro above for x86, and so continue with the
existing unstable interface, but this would allow PPC to define its own
macro, and thus have a 32/64-bit clean interface? Like this?
        #define XENIF_PTR(type, name) u64 name
And then casts would still be needed to work with those values, right?

You can add pack/unpack macros if you like. On x86:
define xenif_pack_ptr(field, var,) field = var
define xenif_unpack_ptr(var, field) var = field

I don;t want to lose pointer type checks. The manual (u64)(unsigned long) casting is gross and loses type checking.

And ureg_t is a name that's bound to clash with something down the
road. Maybe xenreg_t, or even just be explicit about what it is and
call it xenif_ulong_t?

I don't like calling it a "ulong," because it isn't, and neither is it a
"register" size...

Then what will you call it? xenppchack_t? :-)

 -- Keir


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