lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Sun, 21 Jun 2009 14:39:31 -0400
From:	Gregory Haskins <ghaskins@...ell.com>
To:	Davide Libenzi <davidel@...ilserver.org>
CC:	mst@...hat.com, kvm@...r.kernel.org,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	avi@...hat.com, paulmck@...ux.vnet.ibm.com,
	Ingo Molnar <mingo@...e.hu>
Subject: Re: [PATCH 3/3] eventfd: add internal reference counting to fix notifier
 race conditions

Davide Libenzi wrote:
> On Sat, 20 Jun 2009, Gregory Haskins wrote:
>
>   
>> Davide Libenzi wrote:
>>     
>>> On Sat, 20 Jun 2009, Davide Libenzi wrote:
>>>
>>>   
>>>       
>>>> On Sat, 20 Jun 2009, Davide Libenzi wrote:
>>>>
>>>>     
>>>>         
>>>>> How about the one below?
>>>>>       
>>>>>           
>>>> Maybe with an interface that can be undone w/out a file* :)
>>>>     
>>>>         
>>> This is another alternative, based on a low-carb diet of your notifier 
>>> patch.
>>>   
>>>       
>> Ah, I should always check if I have more mail before responding to a now
>> stale patch ;)
>>     
>
> Here. I changed the eventfd_pollcb_register() prototype to return the full 
> registeration time event mask, instead of the POLLIN explicit check.
> Let's give this one some more thought before I push it to Andrew.
>   

This looks great, Davide.  I am fairly certain I can now solve the races
and even implement Michael's DEASSIGN feature with this patch in place. 
I will actually fire it up tomorrow when I am back in the office and
give it a spin, but I do not spy any more races via visual inspection.

Kind Regards,
-Greg

PS: I was wrong with my previous statement about requiring an embeddable
object (eventfd_notifier for me, eventfd_pollcb for you).  I think you
can technically solve this issue minimally by merely locking the POLLHUP
and exposing the kref.  However, I think that leads to an more awkward
interface (e.g. we already have eventfd_fget() plus we add a new one
like eventfd_refget(), which might confuse users), so I prefer what you
did here.  Just thought I would throw that out there in case you would
prefer to change even fewer lines.



Download attachment "signature.asc" of type "application/pgp-signature" (267 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ