[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <27092660926e4d3f80394697cc0dc858@SN2PR03MB061.namprd03.prod.outlook.com>
Date: Thu, 24 Jan 2013 16:07:40 +0000
From: KY Srinivasan <kys@...rosoft.com>
To: Jan Beulich <JBeulich@...e.com>
CC: "olaf@...fle.de" <olaf@...fle.de>, "bp@...en8.de" <bp@...en8.de>,
"apw@...onical.com" <apw@...onical.com>,
"x86@...nel.org" <x86@...nel.org>,
"tglx@...utronix.de" <tglx@...utronix.de>,
"devel@...uxdriverproject.org" <devel@...uxdriverproject.org>,
"gregkh@...uxfoundation.org" <gregkh@...uxfoundation.org>,
"jasowang@...hat.com" <jasowang@...hat.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"hpa@...or.com" <hpa@...or.com>
Subject: RE: [PATCH RESEND 1/1] X86: Handle Hyper-V vmbus interrupts as
special hypervisor interrupts
> -----Original Message-----
> From: Jan Beulich [mailto:JBeulich@...e.com]
> Sent: Thursday, January 24, 2013 3:48 AM
> To: KY Srinivasan
> Cc: olaf@...fle.de; bp@...en8.de; apw@...onical.com; x86@...nel.org;
> tglx@...utronix.de; devel@...uxdriverproject.org; gregkh@...uxfoundation.org;
> jasowang@...hat.com; linux-kernel@...r.kernel.org; hpa@...or.com
> Subject: Re: [PATCH RESEND 1/1] X86: Handle Hyper-V vmbus interrupts as
> special hypervisor interrupts
>
> >>> On 24.01.13 at 02:17, "K. Y. Srinivasan" <kys@...rosoft.com> wrote:
> > @@ -69,6 +74,11 @@ static void __init ms_hyperv_init_platform(void)
> > ms_hyperv.features, ms_hyperv.hints);
> >
> > clocksource_register_hz(&hyperv_cs, NSEC_PER_SEC/100);
> > +
> > + /*
> > + * Setup the IDT for hypervisor callback.
> > + */
> > + alloc_intr_gate(HYPERVISOR_CALLBACK_VECTOR,
> hyperv_callback_vector);
>
> Isn't doing this unconditionally here as problematic as the call to
> clocksource_register_hz() turned out to be when Xen's Hyper-V
> shim reacts to the CPUID inquiry above?
I was not sure what to make this conditional on at run-time. To the extent
that Xen emulation of Hyper-V is complete, this will be a problem. Does Xen
return all the "feature bits" of Hyper-V. I could discriminate on a feature that
Xen does not plan to emulate.
>
> > @@ -77,3 +87,32 @@ const __refconst struct hypervisor_x86
> x86_hyper_ms_hyperv = {
> > .init_platform = ms_hyperv_init_platform,
> > };
> > EXPORT_SYMBOL(x86_hyper_ms_hyperv);
> > +
> > +static int vmbus_irq = -1;
> > +static irq_handler_t vmbus_isr;
> > +
> > +void hv_register_vmbus_handler(int irq, irq_handler_t handler)
> > +{
> > + vmbus_irq = irq;
> > + vmbus_isr = handler;
> > +}
> > +EXPORT_SYMBOL_GPL(hv_register_vmbus_handler);
> > +
> > +void hyperv_vector_handler(struct pt_regs *regs)
> > +{
> > + struct pt_regs *old_regs = set_irq_regs(regs);
> > + struct irq_desc *desc;
> > +
> > + irq_enter();
> > +#ifdef CONFIG_X86
> > + exit_idle();
> > +#endif
>
> This being in a file underneath arch/x86 - why the conditional?
Good point, I will fix that.
>
> Jan
>
>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists