Whamcloud - gitweb
Branch HEAD
authorjohann <johann>
Wed, 30 Jul 2008 16:07:27 +0000 (16:07 +0000)
committerjohann <johann>
Wed, 30 Jul 2008 16:07:27 +0000 (16:07 +0000)
b=16496
i=bzzz
i=vitaly

fix a race between class_handle_unhash() and class_handle2object()
introduced in lustre 1.6.5 by bug 13622. check for h_in instead of
h_cookie in class_handle2object().

lustre/ChangeLog
lustre/obdclass/lustre_handles.c

index e95ef82..fa1b2ae 100644 (file)
@@ -1225,6 +1225,12 @@ Details    : looking up an inode via iopen with the wrong generation number can
             assertion failure in iopen since the inode's dentry list contains
             both a connected and disconnected dentry.
 
+Severity   : normal
+Bugzilla   : 16496
+Description: assertion failure in ldlm_handle2lock()
+Details    : fix a race between class_handle_unhash() and class_handle2object()
+            introduced in lustre 1.6.5 by bug 13622.
+
 --------------------------------------------------------------------------------
 
 2007-08-10         Cluster File Systems, Inc. <info@clusterfs.com>
index 7128f24..23d25dc 100644 (file)
@@ -195,7 +195,7 @@ void *class_handle2object(__u64 cookie)
                         continue;
 
                 spin_lock(&h->h_lock);
-                if (likely(h->h_cookie != 0)) {
+                if (likely(h->h_in != 0)) {
                         h->h_addref(h);
                         retval = h;
                 }