On Wed, May 28, 2008 at 11:39:16AM +0100, Keir Fraser wrote:
> On 28/5/08 11:28, "Isaku Yamahata" <yamahata@xxxxxxxxxxxxx> wrote:
>
> > Although I know that grant table page transfer is obsoleted,
> > what is the expected exact semantics of GNTTABOP_transfer with
> > the p2m/m2p table?
> >
> > I suppose the right fix would be
> > - revert this patch and
> > - put the iommu opration of pv domain into MMU_MACHPHYS_UPDATE.
>
> After the grant transfer operation completes the page no longer belongs to
> the backend domain. Thus, for absolute safety and isolation, the page must
> be removed from the backend domain's IOMMU mappings before completion of the
> grant transfer operation. Actually we should be flushing host CPU TLBs too.
Thank you for explanation.
The patch breaks ia64 granttab xfer breakage so that it have to be fixed.
However the operation is now obsoleted one, so I don't want to make
big effort to fix.
What do you think about the following patch?
Signed-off-by: Isaku Yamahata <yamahata@xxxxxxxxxxxxx>
--- ./grant_table.c 2008-05-28 18:47:40.000000000 +0900
+++ ./grant_table.c-if 2008-05-29 18:27:05.000000000 +0900
@@ -1112,7 +1112,8 @@ gnttab_transfer(
goto copyback;
}
- guest_physmap_remove_page(d, gop.mfn, mfn, 0);
+ if (!paging_mode_translate(d))
+ guest_physmap_remove_page(d, gop.mfn, mfn, 0);
/* Find the target domain. */
if ( unlikely((e = rcu_lock_domain_by_id(gop.domid)) == NULL)
)
or #ifndef __ia64__
--
yamahata
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|