mirror of
https://github.com/xen-project/xen.git
synced 2026-10-29 18:50:05 +01:00
[HVM] Save/restore: catch more error cases in the tools
Signed-off-by: Tim Deegan <Tim.Deegan@xensource.com>
This commit is contained in:
1 parent
68c5ac07e0
commit
1db798cdbe
1 file changed
+15
-6
@@ -688,12 +688,21 @@ int xc_domain_restore(int xc_handle, int io_fd, uint32_t dom,
|
||||
ERROR("error zeroing magic pages");
|
||||
goto out;
|
||||
}
|
||||
|
||||
xc_set_hvm_param(xc_handle, dom, HVM_PARAM_IOREQ_PFN, magic_pfns[0]);
|
||||
xc_set_hvm_param(xc_handle, dom, HVM_PARAM_BUFIOREQ_PFN, magic_pfns[1]);
|
||||
xc_set_hvm_param(xc_handle, dom, HVM_PARAM_STORE_PFN, magic_pfns[2]);
|
||||
xc_set_hvm_param(xc_handle, dom, HVM_PARAM_PAE_ENABLED, pae);
|
||||
xc_set_hvm_param(xc_handle, dom, HVM_PARAM_STORE_EVTCHN, store_evtchn);
|
||||
|
||||
if ( (rc = xc_set_hvm_param(xc_handle, dom,
|
||||
HVM_PARAM_IOREQ_PFN, magic_pfns[0]))
|
||||
|| (rc = xc_set_hvm_param(xc_handle, dom,
|
||||
HVM_PARAM_BUFIOREQ_PFN, magic_pfns[1]))
|
||||
|| (rc = xc_set_hvm_param(xc_handle, dom,
|
||||
HVM_PARAM_STORE_PFN, magic_pfns[2]))
|
||||
|| (rc = xc_set_hvm_param(xc_handle, dom,
|
||||
HVM_PARAM_PAE_ENABLED, pae))
|
||||
|| (rc = xc_set_hvm_param(xc_handle, dom,
|
||||
HVM_PARAM_STORE_EVTCHN, store_evtchn)) )
|
||||
{
|
||||
ERROR("error setting HVM params: %i", rc);
|
||||
goto out;
|
||||
}
|
||||
*store_mfn = magic_pfns[2];
|
||||
|
||||
/* Read HVM context */
|
||||
|
||||