lkml.org 
[lkml]   [1999]   [May]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH][2.3.0] Read-write locks instead semaphores on UTS structures
Jakub Jelinek wrote
>
> Huh? His patch uses read-write locks and not normal spin-locks, so I don't
> understand what you find wrong on it.

read-write locks are a variant of spin locks. you can deadlock
the system if you go to sleep holding holding any spin lock.
the only exception is the kernel lock which has special code
to deal with it in schedule().

ideally the spinlock code (spin_lock and read_lock et al)
would have debug versions that counted how many locks were
held (in some per-cpu data structure), and have schedule()
check that this number was zero before putting the process
to sleep.

jan-simon.

-
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:51    [W:0.059 / U:3.640 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site