[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [MINI-OS PATCH 1/6] suspend: drop crazy pfn handling for PVH
Suspend for PVH is doing some crazy stuff with the Xenstore and console PFNs: - In arch_pre_suspend() the PFNs are "translated" to MFNs, even if that translation is a nop. - The result is stored via start_info_ptr, which points to a struct start_info only in case of PV mode. - After resuming or a cancelled suspend, the PFNs are retrieved again and "translated". - The "MFNs" are stored again via start_info_ptr, which is still not pointing at a struct start_info, and from where the data is never read again after that. Drop all of that completely. Signed-off-by: Juergen Gross <jgross@xxxxxxxx> --- arch/x86/setup.c | 22 ---------------------- 1 file changed, 22 deletions(-) diff --git a/arch/x86/setup.c b/arch/x86/setup.c index b613083b..e30eb065 100644 --- a/arch/x86/setup.c +++ b/arch/x86/setup.c @@ -227,17 +227,6 @@ void arch_pre_suspend(void) virt_to_pfn(mfn_to_virt(start_info_ptr->store_mfn)); start_info_ptr->console.domU.mfn = virt_to_pfn(mfn_to_virt(start_info_ptr->console.domU.mfn)); -#else - uint64_t store_v; - uint64_t console_v; - - if( hvm_get_parameter(HVM_PARAM_STORE_PFN, &store_v) ) - BUG(); - start_info_ptr->store_mfn = store_v; - - if( hvm_get_parameter(HVM_PARAM_CONSOLE_PFN, &console_v) ) - BUG(); - start_info_ptr->console.domU.mfn = console_v; #endif unmap_shared_info(); @@ -262,17 +251,6 @@ void arch_post_suspend(int canceled) } else { memcpy(&start_info, start_info_ptr, sizeof(start_info_t)); } -#else - uint64_t store_v; - uint64_t console_v; - - if (hvm_get_parameter(HVM_PARAM_STORE_PFN, &store_v)) - BUG(); - start_info_ptr->store_mfn = pfn_to_mfn(store_v); - - if (hvm_get_parameter(HVM_PARAM_CONSOLE_PFN, &console_v)) - BUG(); - start_info_ptr->console.domU.mfn = pfn_to_mfn(console_v); #endif HYPERVISOR_shared_info = map_shared_info((void*) start_info_ptr); -- 2.43.0
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |