On 09/14/2012 05:19 PM, Li, Jiongxi wrote:
> Sorry for the late response
> 
>> -----Original Message-----
>> From: Avi Kivity [mailto:a...@redhat.com]
>> Sent: Friday, September 07, 2012 12:38 AM
>> To: Li, Jiongxi
>> Cc: kvm@vger.kernel.org
>> Subject: Re: [PATCH 4/5]KVM:x86, apicv: add interface for poking EOI exit
>> bitmap
>> 
>> On 09/05/2012 08:41 AM, Li, Jiongxi wrote:
>> > With APICv virtual interrupt delivery feature, EOI write from non root
>> > mode doesn't cause VM-Exit unless set in EOI exit bitmap VMCS field.
>> > Basically there're two methods to manipulate EOI exit bitmap:
>> 
>> Should be folded into the previous patch, otherwise the previous patch breaks
>> level interrupts.
> OK
>> 
>> >
>> > [Option 1]
>> > Ideally only level triggered irq requires a hook in vLAPIC EOI write,
>> > so that vIOAPIC EOI is triggered and emulated. So the simplest
>> > approach is to manipulate EOI exit bitmap when vLAPIC acks a new
>> > interrupt, based on value of TMR. There're several corner cases worthy
>> > of note though:
>> >
>> >   - KVM has specific notifier hooks on vIOAPIC EOI path. So far two
>> >     sources use it: INT-based device passthrough and PIT pending
>> >     timers. For the former, it's virtually wired to vIOAPIC and
>> >     thus TMR already covers it. PIT is special here, which is an
>> >     edge triggered source. But since other timer sources like
>> >     vLAPIC timer don't require this notifier hook, possibly PIT
>> >     can be relaxed in the future too.
>> 
>> I would like to switch to changing the timer frequency when we need to catch
>> up.  But that can be done later.
>> 
>> >
>> >   - posted interrupt will update TMR directly, w/o chance for KVM
>> >     to update EOI exit bitmap accordingly. This becomes a gap
>> 
>> Why not? we know what vector the PIT is wired to.
> What PIT case are you talking about? Can you elaborate it?
>> 

The PIT output is wired to the IOAPIC, and has an ack notifier set so we
are notified on EOI (and can reinject missing ticks).

All other interrupts for which we need EOI notification are always level
triggered, and we have ack notifiers for them too.




-- 
error compiling committee.c: too many arguments to function
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to