On Feb 27, 2014, at 6:06 PM, Mindaugas Rasiukevicius <rm...@netbsd.org> wrote:

> "Juergen Hannken-Illjes" <hann...@netbsd.org> wrote:
>> Module Name: src
>> Committed By:        hannken
>> Date:                Thu Feb 27 16:51:39 UTC 2014
>> 
>> <...>
>> 
>> Log Message:
>> The current implementation of vn_lock() is racy.  Modification of
>> the vnode operations vector for active vnodes is unsafe because it
>> is not known whether deadfs or the original file system will be
>> called.
>> 
>> <...>
>> 
> 
> I have not had time to follow your VFS changes, but can you explain why did
> you remove VOP_LOCK/VOP_UNLOCK in tmpfs_reclaim()?  It was added to prevent
> from the racy access of tn_links.

Hopefully a vnode lock is needed to access tn_links -- otherwise the
VOP_LOCK/UNLOCK in tmpfs_reclaim() didn't protect it ...

As this commit prevents other threads from obtaining a lock while
VOP_RECLAIM() is running the protection should be the same as before.

--
J. Hannken-Illjes - hann...@eis.cs.tu-bs.de - TU Braunschweig (Germany)

Reply via email to