qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] Re: [RFC PATCH 4/5] APIC/IOAPIC EOI callback


From: Avi Kivity
Subject: [Qemu-devel] Re: [RFC PATCH 4/5] APIC/IOAPIC EOI callback
Date: Mon, 12 Jul 2010 12:13:37 +0300
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.10) Gecko/20100621 Fedora/3.0.5-1.fc13 Thunderbird/3.0.5

On 07/12/2010 12:05 PM, Gleb Natapov wrote:
On Mon, Jul 12, 2010 at 09:33:12AM +0300, Avi Kivity wrote:
On 07/11/2010 09:30 PM, Avi Kivity wrote:
Registering an eventfd for the eoi seems like a reasonable alternative.
I'm worried about that racing (with what?)
I don't think there's a problem.

First, the EOI message is itself asynchronous.  While the write to
the local APIC is synchronous, effects on the rest of the system are
effected using an APIC message, which travels asynchronously.

Second, a component that needs timely information doesn't have to
wait; it can read the eventfd and be sure it has seen all EOIs up to
now.

I remember we already discussed the use of eventfd for reporting EOI and
decided against it, but I don't remember why. :( Was it because if we
are going to export EOI to userspace anyway we want to be able to use it
for RTC timedrift fixing and for that we need to know what CPU called
EOI and eventfd can't provide that?

IIRC it was the synchronity argument. But it's bogus: if the RTC wants to know whether an ack occured before it makes some decision, all it has to do is read() the eventfd and find out.

Another issue is which cpu issued the ack. I suppose we can have per-vcpu eventfds, though that's ugly.

--
error compiling committee.c: too many arguments to function




reply via email to

[Prev in Thread] Current Thread [Next in Thread]