>>> On 04.10.18 at 17:43, <wei.l...@citrix.com> wrote: > --- a/xen/include/xen/sched.h > +++ b/xen/include/xen/sched.h > @@ -877,8 +877,25 @@ void watchdog_domain_destroy(struct domain *d); > > #define VM_ASSIST(d, t) (test_bit(VMASST_TYPE_ ## t, &(d)->vm_assist)) > > -#define is_pv_domain(d) ((d)->guest_type == guest_type_pv) > -#define is_pv_vcpu(v) (is_pv_domain((v)->domain)) > +static inline bool is_pv_domain(const struct domain *d) > +{ > + return IS_ENABLED(CONFIG_PV) ? d->guest_type == guest_type_pv : false; > +} > + > +static inline bool is_pv_vcpu(const struct vcpu *v) > +{ > + return is_pv_domain(v->domain); > +} > + > +static inline bool is_pv_32bit_domain(const struct domain *d) > +{ > + return is_pv_domain(d) && d->arch.is_32bit_pv; > +} > + > +static inline bool is_pv_32bit_vcpu(const struct vcpu *v) > +{ > + return is_pv_32bit_domain(v->domain); > +}
Afaict this breaks the Arm build, i.e. I think you need e.g. #ifdef CONFIG_COMPAT around the last two. (I can see why, being inline functions now, they can't remain in the arch-specific header.) With this Reviewed-by: Jan Beulich <jbeul...@suse.com> Jan _______________________________________________ Xen-devel mailing list Xen-devel@lists.xenproject.org https://lists.xenproject.org/mailman/listinfo/xen-devel