diff mbox

[22/42] libmultipath: prio keyword ignored for multipath config

Message ID 1357653259-62650-23-git-send-email-hare@suse.de (mailing list archive)
State Deferred, archived
Headers show

Commit Message

Hannes Reinecke Jan. 8, 2013, 1:54 p.m. UTC
When specifying the 'prio' keyword in the multipath section
of the configuration file the value is ignored.
Problem is that the 'wwid' value is set only after the call
to select_prio(), so the correct definition couldn't been
found in the config file.

Signed-off-by: Hannes Reinecke <hare@suse.de>
---
 libmultipath/discovery.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)
diff mbox

Patch

diff --git a/libmultipath/discovery.c b/libmultipath/discovery.c
index b5df8e3..6848b70 100644
--- a/libmultipath/discovery.c
+++ b/libmultipath/discovery.c
@@ -891,6 +891,9 @@  pathinfo (struct path *pp, vector hwtable, int mask)
 		}
 	}
 
+	if (path_state == PATH_UP && (mask & DI_WWID) && !strlen(pp->wwid))
+		get_uid(pp);
+
 	 /*
 	  * Retrieve path priority, even for PATH_DOWN paths if it has never
 	  * been successfully obtained before.
@@ -905,9 +908,6 @@  pathinfo (struct path *pp, vector hwtable, int mask)
 		}
 	}
 
-	if (path_state == PATH_UP && (mask & DI_WWID) && !strlen(pp->wwid))
-		get_uid(pp);
-
 	return 0;
 
 blank: