[PATCH] hyperv: Fix build failure with HYPERVISOR_GUEST=y && KEXEC_CORE=n
Ben Hutchings
ben at decadent.org.uk
Tue Sep 29 11:16:32 UTC 2015
On Tue, 2015-09-29 at 10:47 +0200, Vitaly Kuznetsov wrote:
> Ben Hutchings <ben at decadent.org.uk> writes:
>
> > Currently with this configuration I get:
> >
> > arch/x86/built-in.o: In function `hv_machine_crash_shutdown':
> > mshyperv.c:(.text+0x29656): undefined reference to
> > `native_machine_crash_shutdown'
>
> https://lkml.org/lkml/2015/9/23/183
> ...
> https://lkml.org/lkml/2015/9/7/440
> ...
That's unhelpful, given the instability of lkml.org.
Ben.
> >
> > Fixes: b4370df2b1f5 ("Drivers: hv: vmbus: add special crash
> > handler")
> > Signed-off-by: Ben Hutchings <ben at decadent.org.uk>
> > Cc: Vitaly Kuznetsov <vkuznets at redhat.com>
> > ---
> > arch/x86/kernel/cpu/mshyperv.c | 6 +++++-
> > 1 file changed, 5 insertions(+), 1 deletion(-)
> >
> > diff --git a/arch/x86/kernel/cpu/mshyperv.c
> > b/arch/x86/kernel/cpu/mshyperv.c
> > index 381c8b9..0c94600 100644
> > --- a/arch/x86/kernel/cpu/mshyperv.c
> > +++ b/arch/x86/kernel/cpu/mshyperv.c
> > @@ -35,7 +35,7 @@ struct ms_hyperv_info ms_hyperv;
> > EXPORT_SYMBOL_GPL(ms_hyperv);
> >
> > static void (*hv_kexec_handler)(void);
> > -static void (*hv_crash_handler)(struct pt_regs *regs);
> > +static void (*hv_crash_handler)(struct pt_regs *regs)
> > __maybe_unused;
> >
> > #if IS_ENABLED(CONFIG_HYPERV)
> > static void (*vmbus_handler)(void);
> > @@ -105,12 +105,14 @@ static void hv_machine_shutdown(void)
> > native_machine_shutdown();
> > }
> >
> > +#ifdef CONFIG_KEXEC_CORE
> > static void hv_machine_crash_shutdown(struct pt_regs *regs)
> > {
> > if (hv_crash_handler)
> > hv_crash_handler(regs);
> > native_machine_crash_shutdown(regs);
> > }
> > +#endif
> >
> > static uint32_t __init ms_hyperv_platform(void)
> > @@ -187,7 +189,9 @@ static void __init
> > ms_hyperv_init_platform(void)
> > #endif
> >
> > machine_ops.shutdown = hv_machine_shutdown;
> > +#ifdef CONFIG_KEXEC_CORE
> > machine_ops.crash_shutdown = hv_machine_crash_shutdown;
> > +#endif
> > mark_tsc_unstable("running on Hyper-V");
> > }
>
--
Ben Hutchings
The obvious mathematical breakthrough [to break modern encryption] would be
development of an easy way to factor large prime numbers. - Bill Gates
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 811 bytes
Desc: This is a digitally signed message part
URL: <http://driverdev.linuxdriverproject.org/pipermail/driverdev-devel/attachments/20150929/97d5f886/attachment.asc>
More information about the devel
mailing list