[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH 09/10] xen: remove XEN_GUEST_HANDLE(ulong)
On Mon, 15 Oct 2012, Ian Campbell wrote: > Having both this handle (always unsigned long) and > XEN_GUEST_HANDLE(xen_ulong_t) (unsigned long on x86 and explicit size > of ARM) is confusing and error prone. > > Replace the two remaining uses of the ulong handle, in grant set and > x86 set_gdt hypercalls, with xen_ulong_t. > > This correctly sizes the grant frame entry as 64 bit on ARM but > leaves it as unsigned long on x86 (therefore no intended change on > x86). Likewise in set_gdt there is no actual change. > > Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx> > Cc: keir@xxxxxxx > Cc: JBeulich@xxxxxxxx Acked-by: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx> > xen/arch/x86/mm.c | 3 ++- > xen/common/grant_table.c | 2 +- > xen/include/asm-x86/hypercall.h | 2 +- > xen/include/public/grant_table.h | 2 +- > xen/include/public/xen.h | 2 -- > 5 files changed, 5 insertions(+), 6 deletions(-) > > diff --git a/xen/arch/x86/mm.c b/xen/arch/x86/mm.c > index 191f5ea..fad3d33 100644 > --- a/xen/arch/x86/mm.c > +++ b/xen/arch/x86/mm.c > @@ -4100,7 +4100,8 @@ long set_gdt(struct vcpu *v, > } > > > -long do_set_gdt(XEN_GUEST_HANDLE_PARAM(ulong) frame_list, unsigned int > entries) > +long do_set_gdt(XEN_GUEST_HANDLE_PARAM(xen_ulong_t) frame_list, > + unsigned int entries) > { > int nr_pages = (entries + 511) / 512; > unsigned long frames[16]; > diff --git a/xen/common/grant_table.c b/xen/common/grant_table.c > index f4ae9ee..7912769 100644 > --- a/xen/common/grant_table.c > +++ b/xen/common/grant_table.c > @@ -1322,7 +1322,7 @@ gnttab_setup_table( > struct domain *d; > struct grant_table *gt; > int i; > - unsigned long gmfn; > + xen_pfn_t gmfn; > > if ( count != 1 ) > return -EINVAL; > diff --git a/xen/include/asm-x86/hypercall.h b/xen/include/asm-x86/hypercall.h > index bd14220..afa8ba9 100644 > --- a/xen/include/asm-x86/hypercall.h > +++ b/xen/include/asm-x86/hypercall.h > @@ -33,7 +33,7 @@ do_mmu_update( > > extern long > do_set_gdt( > - XEN_GUEST_HANDLE_PARAM(ulong) frame_list, > + XEN_GUEST_HANDLE_PARAM(xen_ulong_t) frame_list, > unsigned int entries); > > extern long > diff --git a/xen/include/public/grant_table.h > b/xen/include/public/grant_table.h > index 28d9476..13cc559 100644 > --- a/xen/include/public/grant_table.h > +++ b/xen/include/public/grant_table.h > @@ -385,7 +385,7 @@ struct gnttab_setup_table { > uint32_t nr_frames; > /* OUT parameters. */ > int16_t status; /* => enum grant_status */ > - XEN_GUEST_HANDLE(ulong) frame_list; > + XEN_GUEST_HANDLE(xen_pfn_t) frame_list; > }; > typedef struct gnttab_setup_table gnttab_setup_table_t; > DEFINE_XEN_GUEST_HANDLE(gnttab_setup_table_t); > diff --git a/xen/include/public/xen.h b/xen/include/public/xen.h > index e42d01f..9a5b394 100644 > --- a/xen/include/public/xen.h > +++ b/xen/include/public/xen.h > @@ -43,8 +43,6 @@ DEFINE_XEN_GUEST_HANDLE(char); > __DEFINE_XEN_GUEST_HANDLE(uchar, unsigned char); > DEFINE_XEN_GUEST_HANDLE(int); > __DEFINE_XEN_GUEST_HANDLE(uint, unsigned int); > -DEFINE_XEN_GUEST_HANDLE(long); > -__DEFINE_XEN_GUEST_HANDLE(ulong, unsigned long); > DEFINE_XEN_GUEST_HANDLE(void); > > DEFINE_XEN_GUEST_HANDLE(uint64_t); > -- > 1.7.9.1 > _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |