lkml.org 
[lkml]   [2013]   [Dec]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH V10 05/14] xen/pvh: balloon and grant changes.
On 13/12/13 02:10, Konrad Rzeszutek Wilk wrote:
> From: Mukesh Rathor <mukesh.rathor@oracle.com>
>
> For balloon changes we skip setting of local P2M as it's updated
> in Xen. For grant, the shared grant frame is the PFN and not MFN,
> hence its mapped via the same code path as HVM.

It's difficult to see how these are related. Please split.

I also think Stefano recently submitted an equivalent fix for the
balloon driver.

> --- a/drivers/xen/grant-table.c
> +++ b/drivers/xen/grant-table.c
> @@ -1056,14 +1056,20 @@ static void gnttab_unmap_frames_v2(void)
> static int gnttab_map(unsigned int start_idx, unsigned int end_idx)
> {
> struct gnttab_setup_table setup;
> + unsigned long start_gpfn;
> xen_pfn_t *frames;
> unsigned int nr_gframes = end_idx + 1;
> int rc;
>
> - if (xen_hvm_domain()) {
> + if (xen_hvm_domain() || xen_feature(XENFEAT_auto_translated_physmap)) {
> struct xen_add_to_physmap xatp;
> unsigned int i = end_idx;
> rc = 0;
> +
> + if (xen_hvm_domain())
> + start_gpfn = xen_hvm_resume_frames >> PAGE_SHIFT;
> + else
> + start_gpfn = virt_to_pfn(gnttab_shared.addr);

Not really clear why PVH diverges from HVM here.

> @@ -1135,7 +1141,7 @@ static void gnttab_request_version(void)
> int rc;
> struct gnttab_set_version gsv;
>
> - if (xen_hvm_domain())
> + if (xen_hvm_domain() || xen_feature(XENFEAT_auto_translated_physmap))
> gsv.version = 1;
> else
> gsv.version = 2;

Why is PVH limited to version 1?

David


\
 
 \ /
  Last update: 2013-12-13 12:21    [W:0.226 / U:9.904 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site