Re: [RFC][PATCH RT] rwsem_rt: Another (more sane) approach to mulit reader rt locks

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

 



On Tue, 2012-05-15 at 11:42 -0400, Steven Rostedt wrote:
> On Tue, 2012-05-15 at 17:06 +0200, Peter Zijlstra wrote:
> > On Tue, 2012-05-15 at 10:03 -0400, Steven Rostedt wrote:
> > > 
> > > where readers may nest (the same task may grab the same rwsem for
> > > read multiple times), but only one task may hold the rwsem at any
> > > given
> > > time (for read or write).
> > 
> > Humm, that sounds iffy, rwsem isn't a recursive read lock only rwlock_t
> > is.
> 
> In that case, current -rt is broken. As it has it being a recursive lock
> (without my patch).
> 

Why wouldn't it be recursive. If two different tasks are allowed to grab
a read lock at the same time, why can't the same task grab a read lock
twice? As long as it releases it the same amount of times.

Now you can't grab a read lock if you have the write lock.

-- Steve


--
To unsubscribe from this list: send the line "unsubscribe linux-rt-users" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [RT Stable]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux