Re: [PATCH 3/3] eventfd: add internal reference counting to fix notifier race conditions

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

 



Davide Libenzi wrote:
> On Mon, 22 Jun 2009, Michael S. Tsirkin wrote:
>
>   
>> On Mon, Jun 22, 2009 at 11:03:22AM -0700, Davide Libenzi wrote:
>>     
>>> In your case of kernel-to-kernel scenario, why would you need eventfd at 
>>> all, if userspace role in that model is simply to create it?
>>>       
>> That's not 100% true. We have a mode where userspace is the producer
>> and/or consumer (migration mode) and we switch between that and
>> direct kernel-to-kernel communication.
>>     
>
> Then you'd need to ask yourself how to handle your complex case inside the 
> KVM code, so that other eventfd users are not affected by the extra fat 
> needed to handle your scenarios. Thing that seem to be continuosly tried.
> A file* based kernel-to-kernel interface is rather wrong IMO.
>   

Well, I will point out that the interface in question is
eventfd_signal(struct file *), and you were the one that invented it
afaict.  Can't help it if we like it :)

BTW: The termination point of that call is incidental.  Afterall, it
works the same for kernel-kernel or kernel-userspace.  The only relevant
discussion point here is that your proposal breaks POLLHUP for
eventfd_signal() users, and we have a real use case that cares.

Let me ask the question a different way: Lets say we all agree that
eventfd_signal() cannot be file* based to be correct.  Is there a way
you can think of that satisfies both the need to get rid of file* AND
still deliver producer-release notification to consumers.  Ultimately
that is all I care about.

-Greg


Attachment: signature.asc
Description: OpenPGP digital signature


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux