[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH ARM v5 13/20] mini-os: moved __pte to x86
Thomas Leonard, le Thu 26 Jun 2014 12:28:30 +0100, a écrit : > We don't need to define this on ARM. Suggested by Julien Grall. > > Signed-off-by: Thomas Leonard <talex5@xxxxxxxxx> Acked-by: Samuel Thibault <samuel.thibault@xxxxxxxxxxxx> > --- > extras/mini-os/include/types.h | 12 ------------ > extras/mini-os/include/x86/x86_32/hypercall-x86_32.h | 5 +++++ > extras/mini-os/include/x86/x86_64/hypercall-x86_64.h | 4 ++++ > 3 files changed, 9 insertions(+), 12 deletions(-) > > diff --git a/extras/mini-os/include/types.h b/extras/mini-os/include/types.h > index de356e8..93356fe 100644 > --- a/extras/mini-os/include/types.h > +++ b/extras/mini-os/include/types.h > @@ -30,23 +30,11 @@ typedef unsigned long u_long; > #ifdef __i386__ > typedef long long quad_t; > typedef unsigned long long u_quad_t; > - > -typedef struct { unsigned long pte_low, pte_high; } pte_t; > - > #elif defined(__x86_64__) > typedef long quad_t; > typedef unsigned long u_quad_t; > - > -typedef struct { unsigned long pte; } pte_t; > #endif /* __i386__ || __x86_64__ */ > > -#ifdef __x86_64__ > -#define __pte(x) ((pte_t) { (x) } ) > -#else > -#define __pte(x) ({ unsigned long long _x = (x); \ > - ((pte_t) {(unsigned long)(_x), (unsigned long)(_x>>32)}); }) > -#endif > - > #ifdef HAVE_LIBC > #include <limits.h> > #include <stdint.h> > diff --git a/extras/mini-os/include/x86/x86_32/hypercall-x86_32.h > b/extras/mini-os/include/x86/x86_32/hypercall-x86_32.h > index dcfbe41..99a4ee3 100644 > --- a/extras/mini-os/include/x86/x86_32/hypercall-x86_32.h > +++ b/extras/mini-os/include/x86/x86_32/hypercall-x86_32.h > @@ -35,6 +35,11 @@ > #include <xen/nmi.h> > #include <mini-os/mm.h> > > +typedef struct { unsigned long pte_low, pte_high; } pte_t; > + > +#define __pte(x) ({ unsigned long long _x = (x); \ > + ((pte_t) {(unsigned long)(_x), (unsigned long)(_x>>32)}); }) > + > #define __STR(x) #x > #define STR(x) __STR(x) > > diff --git a/extras/mini-os/include/x86/x86_64/hypercall-x86_64.h > b/extras/mini-os/include/x86/x86_64/hypercall-x86_64.h > index 7083763..e00b3bd 100644 > --- a/extras/mini-os/include/x86/x86_64/hypercall-x86_64.h > +++ b/extras/mini-os/include/x86/x86_64/hypercall-x86_64.h > @@ -38,6 +38,10 @@ > #include <xen/sched.h> > #include <mini-os/mm.h> > > +typedef struct { unsigned long pte; } pte_t; > + > +#define __pte(x) ((pte_t) { (x) } ) > + > #define __STR(x) #x > #define STR(x) __STR(x) > > -- > 2.0.0 > -- Samuel Actually, typing random strings in the Finder does the equivalent of filename completion. (Discussion in comp.os.linux.misc on the intuitiveness of commands: file completion vs. the Mac Finder.) _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |