[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH 08 of 16] amd iommu: Add a hypercall for hvmloader
>>> On 23.12.11 at 12:29, Wei Wang <wei.wang2@xxxxxxx> wrote: > # HG changeset patch > # User Wei Wang <wei.wang2@xxxxxxx> > # Date 1324569395 -3600 > # Node ID 2329dad2786f6f20ea69c9609ab60208cad6fca9 > # Parent 40d61d0390ec930cf53ce5cbf91faada8c7192bd > amd iommu: Add a hypercall for hvmloader. > IOMMU MMIO base address is dynamically allocated by firmware. > This patch allows hvmloader to notify hypervisor where the > iommu mmio pages are. > > Signed-off-by: Wei Wang <wei.wang2@xxxxxxx> > > diff -r 40d61d0390ec -r 2329dad2786f xen/arch/x86/hvm/hvm.c > --- a/xen/arch/x86/hvm/hvm.c Thu Dec 22 16:56:32 2011 +0100 > +++ b/xen/arch/x86/hvm/hvm.c Thu Dec 22 16:56:35 2011 +0100 > @@ -65,6 +65,7 @@ > #include <public/memory.h> > #include <asm/mem_event.h> > #include <public/mem_event.h> > +#include <asm/hvm/svm/amd-iommu-proto.h> > > bool_t __read_mostly hvm_enabled; > > @@ -3677,6 +3678,9 @@ long do_hvm_op(unsigned long op, XEN_GUE > case HVM_PARAM_BUFIOREQ_EVTCHN: > rc = -EINVAL; > break; > + case HVM_PARAM_IOMMU_BASE: > + rc = guest_iommu_set_base(d, a.value); > + break; > } > > if ( rc == 0 ) > diff -r 40d61d0390ec -r 2329dad2786f xen/include/public/hvm/params.h > --- a/xen/include/public/hvm/params.h Thu Dec 22 16:56:32 2011 +0100 > +++ b/xen/include/public/hvm/params.h Thu Dec 22 16:56:35 2011 +0100 > @@ -142,6 +142,10 @@ > /* Boolean: Enable nestedhvm (hvm only) */ > #define HVM_PARAM_NESTEDHVM 24 > > -#define HVM_NR_PARAMS 27 > +#ifndef __ia64__ As with the domctl definitions, I fail to see why this should be excluded for IA64 - the general concept, even if not currently implemented, is valid for any architecture that could potentially have IOMMUs. Jan > +#define HVM_PARAM_IOMMU_BASE 27 > +#endif > + > +#define HVM_NR_PARAMS 28 > > #endif /* __XEN_PUBLIC_HVM_PARAMS_H__ */ _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |