From: zhanghc Date: Tue, 11 Nov 2008 03:33:29 +0000 (+0000) Subject: branch b1_8_gate X-Git-Tag: v1_7_140~1^143 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=5e6b98aa08a86e236256b4b9f7c4c7b2ce475d8f;p=fs%2Flustre-release.git branch b1_8_gate b=17495 move the check of recovering state of the OST in osc_precreate out of "if (oscc->oscc_last_id < oscc->oscc_next_id)" condition so create operation don't use recovering OST i=adilger i=nathan.rutman --- diff --git a/lustre/osc/osc_create.c b/lustre/osc/osc_create.c index 94fc294..4f0a3ad 100644 --- a/lustre/osc/osc_create.c +++ b/lustre/osc/osc_create.c @@ -280,6 +280,9 @@ int osc_precreate(struct obd_export *exp) if (imp != NULL && imp->imp_deactive) RETURN(1000); + if (oscc_recovering(oscc)) + RETURN(2); + if (oscc->oscc_last_id < oscc->oscc_next_id) { spin_lock(&oscc->oscc_lock); if (oscc->oscc_flags & OSCC_FLAG_NOSPC) { @@ -290,11 +293,6 @@ int osc_precreate(struct obd_export *exp) spin_unlock(&oscc->oscc_lock); RETURN(1); } - if (oscc->oscc_flags & OSCC_FLAG_RECOVERING) { - spin_unlock(&oscc->oscc_lock); - RETURN(2); - } - if (oscc->oscc_flags & OSCC_FLAG_CREATING) { spin_unlock(&oscc->oscc_lock); RETURN(1);