xen/grant-table: fix suspend for non-PV guests

Commit aa8532c322 (xen: refactor suspend
pre/post hooks) broke resuming PVHVM (auto-translated physmap) guests.

The gnttab_suspend() would clear the mapping for the grant table
frames, but the ->unmap_frames() call is only applicable to PV guests.

Signed-off-by: David Vrabel <david.vrabel@citrix.com>
Reported-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Tested-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
This commit is contained in:
David Vrabel 2014-06-16 11:12:03 +01:00
parent ea9f9274bf
commit 13cd36a37a
1 changed files with 2 additions and 1 deletions

View File

@ -1168,6 +1168,7 @@ int gnttab_resume(void)
int gnttab_suspend(void)
{
if (!xen_feature(XENFEAT_auto_translated_physmap))
gnttab_interface->unmap_frames();
return 0;
}