[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] Re: paged granttable entries
Hi Olaf, Thanks for all this info. The basic idea for grant table stuff is that if it's already been granted, then it shouldn't be paged out (this case should be covered by reference counting). In the case where a guest wants to grant a page that is currently paged out, then that page should be brought back in before the grant is made. I think the idea here would maybe be to pause the VCPU running the grant code, page in the page, then resume the VCPU. The ip wouldn't be advanced at all, so it should re-execute the instruction to grant causing it to trap back into Xen and grant the (now paged in) page. The grant interface has changed a lot since I originally worked on it, so it's not surprising to me that there's issues here. An alternative approach is to return an error to the guest which results in it retrying the mapping itself (without needing to pause/unpause the VCPU). I haven't looked at the PV driver code to know if there's already a retry mechanism built in or not. If there is, then that could be leveraged. If not, then either we pause the VCPU as mentioned above or code in a new path. I'm generally in favour of approaches that don't break old systems unless absolutely necessary (for performance reasons, say). When I get some time I'll read over the grant mapping stuff again to see if I can make more sense of it. Patrick On 26 August 2010 07:50, Olaf Hering <olaf@xxxxxxxxx> wrote: > > Patrick, > > while looking for other usage of p2m_mem_paging_populate(), I found two > calls in __gnttab_copy(). They set the error gnttab_copy_t->status to > -ENOENT. > Should this better be something from the GNTST_* namespace? I did not > see a check for -ENOENT "on the other side". > > At least the kernel drivers in SLES11 do only check for GNTST_okay and > GNTST_eagain and GNTST_bad_page. > > > And a quick search for op->status usage shows a mix of GNTST_* and > status != 0. While it may not make much difference, perhaps there should > be some translation between the granttable error namespace and other > namespaces. > > > Olaf > > _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |