lkml.org 
[lkml]   [1999]   [Jun]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subjectsuperblock lock SMP safe ?

extern inline void lock_super(struct super_block * sb)
{
if (sb->s_lock)
__wait_on_super(sb);
sb->s_lock = 1;
}

isn't there a race here ? shouldn't it be more like lock_buffer ?
while (!test_and_set_bit(0, &sb->s_lock))
__wait_on_super(sb);

or is it that all paths using lock_super already have the kernel lock ?

ganesh

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