Whamcloud - gitweb
Drop the spinlock before returning if the export already has a connection.
authoradilger <adilger>
Sun, 8 Sep 2002 22:28:43 +0000 (22:28 +0000)
committeradilger <adilger>
Sun, 8 Sep 2002 22:28:43 +0000 (22:28 +0000)
I'm still not sure I agree that this is an error, but be that as it may,
I leave it for Mike & Peter to work out.

lustre/mds/handler.c

index fa285e6..d8ea1e7 100644 (file)
@@ -281,8 +281,9 @@ static int mds_connect(struct lustre_handle *conn, struct obd_device *obd,
                 if (!memcmp(cluuid, mcd->mcd_uuid, sizeof(mcd->mcd_uuid))) {
                         LASSERT(exp->exp_obd == obd);
 
-                        if (!list_empty(&exp->exp_conn_chain)) { 
+                        if (!list_empty(&exp->exp_conn_chain)) {
                                 CERROR("existing uuid/export, list not empty!\n");
+                                spin_unlock(&obd->obd_dev_lock);
                                 RETURN(-EALREADY);
                         }
                         conn->addr = (__u64) (unsigned long)exp;