[AF_UNIX]: Use spinlock for unix_table_lock
[linux-2.6.git] / net / unix / garbage.c
index 6ffc64e1712d291f40723109db1a774e507c738c..411802bd4d37e604fe7a337bff2c7becaf84fccb 100644 (file)
@@ -182,7 +182,7 @@ void unix_gc(void)
        if (down_trylock(&unix_gc_sem))
                return;
 
-       read_lock(&unix_table_lock);
+       spin_lock(&unix_table_lock);
 
        forall_unix_sockets(i, s)
        {
@@ -301,7 +301,7 @@ void unix_gc(void)
                }
                u->gc_tree = GC_ORPHAN;
        }
-       read_unlock(&unix_table_lock);
+       spin_unlock(&unix_table_lock);
 
        /*
         *      Here we are. Hitlist is filled. Die.