* Praveen K Paladugu <[email protected]> wrote: > Configure sleep state information in mshv hypervisor. This sleep state > information from ACPI will be used by hypervisor to poweroff the host. > > Signed-off-by: Praveen K Paladugu <[email protected]> > Co-developed-by: Anatol Belski <[email protected]> > Signed-off-by: Anatol Belski <[email protected]> > Reviewed-by: Easwar Hariharan <[email protected]> > --- > arch/x86/hyperv/hv_init.c | 1 + > arch/x86/include/asm/mshyperv.h | 2 + > drivers/hv/mshv_common.c | 80 +++++++++++++++++++++++++++++++++ > 3 files changed, 83 insertions(+) > > diff --git a/arch/x86/hyperv/hv_init.c b/arch/x86/hyperv/hv_init.c > index e28737ec7054..daf97a984b78 100644 > --- a/arch/x86/hyperv/hv_init.c > +++ b/arch/x86/hyperv/hv_init.c > @@ -555,6 +555,7 @@ void __init hyperv_init(void) > > hv_remap_tsc_clocksource(); > hv_root_crash_init(); > + hv_sleep_notifiers_register(); > } else { > hypercall_msr.guest_physical_address = > vmalloc_to_pfn(hv_hypercall_pg); > wrmsrq(HV_X64_MSR_HYPERCALL, hypercall_msr.as_uint64); > diff --git a/arch/x86/include/asm/mshyperv.h b/arch/x86/include/asm/mshyperv.h > index 10037125099a..166053df0484 100644 > --- a/arch/x86/include/asm/mshyperv.h > +++ b/arch/x86/include/asm/mshyperv.h > @@ -182,8 +182,10 @@ int hyperv_fill_flush_guest_mapping_list( > void hv_apic_init(void); > void __init hv_init_spinlocks(void); > bool hv_vcpu_is_preempted(int vcpu); > +void hv_sleep_notifiers_register(void); > #else > static inline void hv_apic_init(void) {} > +static inline void hv_sleep_notifiers_register(void) {}; > #endif > > struct irq_domain *hv_create_pci_msi_domain(void);
Acked-by: Ingo Molnar <[email protected]> Thanks, Ingo
