[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH 05/12 v3] xen/arm: vpl011: Add new domctl APIs to initialize/de-initialize vpl011
On Wed, May 10, 2017 at 08:01:18PM +0530, Bhupinder Thakur wrote: > Add two new domctl APIs to initialize and de-initialize vpl011. It takes the > GFN and console > backend domid as input and returns an event channel to be used for > sending and receiving events from Xen. > > Xen will communicate with xenconsole using GFN as the ring buffer and > the event channel to transmit and receive pl011 data on guest domain's behalf. > > Signed-off-by: Bhupinder Thakur <bhupinder.thakur@xxxxxxxxxx> [...] > diff --git a/tools/libxl/libxl_dom.c b/tools/libxl/libxl_dom.c > index 5d914a5..e7489d9 100644 > --- a/tools/libxl/libxl_dom.c > +++ b/tools/libxl/libxl_dom.c > @@ -688,6 +688,15 @@ static int libxl__build_dom(libxl__gc *gc, uint32_t > domid, > goto out; > } > > + if ( info->vuart && > + (ret = xc_dom_vpl011_init(CTX->xch, > + domid, > + state->console_domid, > + dom->vuart_gfn, > + &state->vuart_port)) != 0 ) { > + LOGE(ERROR, "xc_dom_vpl011_init failed"); > + goto out; > + } Please push this to arch-specific function. > out: > return ret != 0 ? ERROR_FAIL : 0; > } > @@ -788,6 +797,7 @@ int libxl__build_pv(libxl__gc *gc, uint32_t domid, > if (xc_dom_translated(dom)) { > state->console_mfn = dom->console_pfn; > state->store_mfn = dom->xenstore_pfn; > + state->vuart_gfn = dom->vuart_gfn; > } else { > state->console_mfn = xc_dom_p2m(dom, dom->console_pfn); > state->store_mfn = xc_dom_p2m(dom, dom->xenstore_pfn); > diff --git a/tools/libxl/libxl_domain.c b/tools/libxl/libxl_domain.c > index 08eccd0..1d2c65a 100644 > --- a/tools/libxl/libxl_domain.c > +++ b/tools/libxl/libxl_domain.c > @@ -1028,6 +1028,8 @@ void libxl__destroy_domid(libxl__egc *egc, > libxl__destroy_domid_state *dis) > goto out; > } > > + xc_dom_vpl011_deinit(ctx->xch, domid); > + Again, arch-specific function please. > if (libxl__device_pci_destroy_all(gc, domid) < 0) > LOGD(ERROR, domid, "Pci shutdown failed"); > rc = xc_domain_pause(ctx->xch, domid); > diff --git a/xen/arch/arm/domctl.c b/xen/arch/arm/domctl.c > index 971caec..11707db 100644 > --- a/xen/arch/arm/domctl.c > +++ b/xen/arch/arm/domctl.c > @@ -10,6 +10,7 @@ > #include <xen/sched.h> > #include <xen/hypercall.h> > #include <xen/iocap.h> > +#include <xen/guest_access.h> Please order the header files alphabetically. _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx https://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |