lkml.org 
[lkml]   [1999]   [Nov]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [Patch] shm bug introduced with pagecache in 2.3.11

On 21-Nov-99 Linus Torvalds wrote:
> - if a writer is waiting for readers (contention_wr), then the writer
> will have already set the high bit, and a reader will know to wake it
> up because the rw-semaphore value will be negative when it does
> read_up().

I assume this also means that if a writer is blocked waiting for readers to
exit, subsequent readers entering the semaphore are also blocked. If you don't
do this, the writer can be starved forever by a continious stream of readers.

J

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

\
 
 \ /
  Last update: 2005-03-22 13:55    [W:0.053 / U:0.892 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site