[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <MW2PR2101MB10522D2935F49CB9AF138E02D7F40@MW2PR2101MB1052.namprd21.prod.outlook.com>
Date: Thu, 19 Mar 2020 15:06:35 +0000
From: Michael Kelley <mikelley@...rosoft.com>
To: vkuznets <vkuznets@...hat.com>,
"ltykernel@...il.com" <ltykernel@...il.com>
CC: Tianyu Lan <Tianyu.Lan@...rosoft.com>,
"linux-hyperv@...r.kernel.org" <linux-hyperv@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
KY Srinivasan <kys@...rosoft.com>,
Haiyang Zhang <haiyangz@...rosoft.com>,
Stephen Hemminger <sthemmin@...rosoft.com>,
Wei Liu <liuwe@...rosoft.com>,
"tglx@...utronix.de" <tglx@...utronix.de>,
"mingo@...hat.com" <mingo@...hat.com>,
"bp@...en8.de" <bp@...en8.de>, "hpa@...or.com" <hpa@...or.com>,
"x86@...nel.org" <x86@...nel.org>
Subject: RE: [PATCH 0/4] x86/Hyper-V: Unload vmbus channel in hv panic
callback
From: Vitaly Kuznetsov <vkuznets@...hat.com> Sent: Thursday, March 19, 2020 1:04 AM
>
> Michael Kelley <mikelley@...rosoft.com> writes:
>
> >> > --- a/drivers/hv/vmbus_drv.c
> >> > +++ b/drivers/hv/vmbus_drv.c
> >> > @@ -53,9 +53,12 @@ static int hyperv_panic_event(struct notifier_block *nb,
> unsigned
> >> long val,
> >> > {
> >> > struct pt_regs *regs;
> >> >
> >> > - regs = current_pt_regs();
> >> > + vmbus_initiate_unload(true);
> >> >
> >> > - hyperv_report_panic(regs, val);
> >> > + if (ms_hyperv.misc_features & HV_FEATURE_GUEST_CRASH_MSR_AVAILABLE) {
> >>
> >> With Michael's effors to make code in drivers/hv arch agnostic, I think
> >> we need a better, arch-neutral way.
> >
> > Vitaly -- could you elaborate on what part is not arch-neutral? I don't see
> > a problem. ms_hyperv and the misc_features field exist for both the x86
> > and ARM64 code branches. It turns out the particular bit for
> > GUEST_CRASH_MSR_AVAILABLE is different on the two architectures, but
> > the compiler will do the right thing.
> >
>
> Ah, apologies, missed the fact that we also call it
> 'HV_FEATURE_GUEST_CRASH_MSR_AVAILABLE' - I have to admit I was confused
> by the 'MSR' part. We can probably rename this to something like
> HV_FEATURE_GUEST_CRASH_REGS_AVAILABLE - but not as part of the series.
>
Good point. Agreed.
Michael
Powered by blists - more mailing lists