From d73f5d18e6a9dd1b925265ed60a749e1a6287555 Mon Sep 17 00:00:00 2001 From: yangsheng Date: Wed, 23 May 2012 15:42:20 +0800 Subject: [PATCH] LU-1291 mds: Test failure on test suite replay-single 44c The obd_notify needs protect by mds_notify_lock. Else LOV maybe gone while __mds_lov_synchronize be called. Signed-off-by: yang sheng Change-Id: Icb856b2a2b135711fd5681b0b4ebef0a1d78b988 Reviewed-on: http://review.whamcloud.com/2708 Reviewed-by: Niu Yawei Reviewed-by: Johann Lombardi Tested-by: Hudson Tested-by: Maloo Reviewed-by: Andreas Dilger --- lustre/mds/mds_lov.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lustre/mds/mds_lov.c b/lustre/mds/mds_lov.c index cdadb79..79d137f 100644 --- a/lustre/mds/mds_lov.c +++ b/lustre/mds/mds_lov.c @@ -897,7 +897,6 @@ static int __mds_lov_synchronize(void *data) #endif EXIT; out: - cfs_up_read(&mds->mds_notify_lock); if (rc) { /* Deactivate it for safety */ CERROR("%s sync failed %d, deactivating\n", obd_uuid2str(uuid), @@ -907,6 +906,7 @@ out: obd_notify(mds->mds_lov_obd, watched, OBD_NOTIFY_INACTIVE, NULL); } + cfs_up_read(&mds->mds_notify_lock); class_decref(obd, "mds_lov_synchronize", obd); return rc; -- 1.8.3.1