lkml.org 
[lkml]   [2005]   [Nov]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH RFC] big reader semaphore take#2
Tejun Heo wrote:
> Tejun Heo wrote:
>
>> Hello guys,
>>
>> This is the second take of brsem (big reader semaphore).
>>
>> Nick, unfortunately, simple array of rwsem's does not work as lock
>> holders are not pinned down to cpus and may release locks on other
>> cpus.
>>

[...]

>
> (Nick, what do you think about the new implementation?)
>

As I said, I think I'd prefer to see an implementation that returns
a token from down_read to be used in up_read (ie. the slot # of the
counter which has been downed).

This obviously no longer makes it a drop in replacement for an rwsem.
But could such a beast ever be considered so? Would that make your
VFS patches really ugly?

The upshot of that would be that you could build the whole thing
from rwsem infrastructure and have basically zero other locking
mechanisms or complexity that you don't want in a synchronisation
primitive.

Nick

--
SUSE Labs, Novell Inc.

Send instant messages to your online friends http://au.messenger.yahoo.com

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-11-05 01:15    [W:0.095 / U:0.072 seconds]
©2003-2011 Jasper Spaans. Advertise on this site