Re: [PATCH 15/17] KVM: PPC: Support irq routing and irqfd for in-kernel MPIC

Scott Wood
2013-04-25T16:53:36Z

On 04/25/2013 04:58:51 AM, Alexander Graf wrote:
>
> On 19.04.2013, at 20:02, Scott Wood wrote:
>
> > On 04/19/2013 09:06:26 AM, Alexander Graf wrote:
> >> + if (notify_eoi != -1) {
> >> + spin_unlock_irq(&opp->lock);
> >> + kvm_notify_acked_irq(opp->kvm, 0, notify_eoi);
> >> + spin_lock_irq(&opp->lock);
> >> + }
> >
> > I'd rather not have the "_irq" here, which could break if we enter
> this patch via an "_irqsave" (I realize there currently is no such
> path that reaches EOI emulation).
> >
> > Will we ever set notify_eoi when addr != EOI? I'm wondering why it
> was moved out of the switch statement, instead of being put at the
> end of the case EOI: code.
>
> I doubt it, but that's for the compiler to optimize away. I found it
> cleaner for some reason to put it down there. I don't think it really
> matters.

Cleanliness is my concern as well. It doesn't seem clean to
arbitrarily split up the EOI implementation.

-Scott