Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 554f0724 authored by Andriy Skulysh's avatar Andriy Skulysh Committed by Greg Kroah-Hartman
Browse files

staging: lustre: lov: Don't wait for active target with OBD_STATFS_NODELAY



Patch for LU-631 which was landed before the upstream merge broke
OBD_STATFS_NODELAY behaviour. It adds unnecessary delay while
running df command with inactive OSTs. We shouldn't try to recover
connection to OST in this case.

Signed-off-by: default avatarAndriy Skulysh <Andriy_Skulysh@xyratex.com>
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4010
Reviewed-on: http://review.whamcloud.com/7762


Reviewed-by: default avatarAndreas Dilger <andreas.dilger@intel.com>
Reviewed-by: default avatarOleg Drokin <oleg.drokin@intel.com>
Signed-off-by: default avatarJames Simmons <jsimmons@infradead.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent ad1daf47
Loading
Loading
Loading
Loading
+5 −2
Original line number Diff line number Diff line
@@ -715,12 +715,15 @@ int lov_prep_statfs_set(struct obd_device *obd, struct obd_info *oinfo,
		struct lov_request *req;

		if (!lov->lov_tgts[i] ||
		    (!lov_check_and_wait_active(lov, i) &&
		     (oinfo->oi_flags & OBD_STATFS_NODELAY))) {
		    (oinfo->oi_flags & OBD_STATFS_NODELAY &&
		     !lov->lov_tgts[i]->ltd_active)) {
			CDEBUG(D_HA, "lov idx %d inactive\n", i);
			continue;
		}

		if (!lov->lov_tgts[i]->ltd_active)
			lov_check_and_wait_active(lov, i);

		/* skip targets that have been explicitly disabled by the
		 * administrator
		 */