diff mbox

[12/30] Minor fixes for priority handling

Message ID 1373958801-103613-13-git-send-email-hare@suse.de (mailing list archive)
State Not Applicable, archived
Headers show

Commit Message

Hannes Reinecke July 16, 2013, 7:13 a.m. UTC
When no prio handler was selected we should be setting the
priority to 'PRIO_UNDEF'.
Also fixup a typo in the logging message when selecting
the default prioritizer.

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

Patch

diff --git a/libmultipath/discovery.c b/libmultipath/discovery.c
index fcb8e4f..a482c53 100644
--- a/libmultipath/discovery.c
+++ b/libmultipath/discovery.c
@@ -957,6 +957,7 @@  get_prio (struct path * pp)
 		select_prio(pp);
 		if (!prio_selected(p)) {
 			condlog(3, "%s: no prio selected", pp->dev);
+			pp->priority = PRIO_UNDEF;
 			return 1;
 		}
 	}
diff --git a/libmultipath/propsel.c b/libmultipath/propsel.c
index 65c2c7f..cea8c1c 100644
--- a/libmultipath/propsel.c
+++ b/libmultipath/propsel.c
@@ -447,7 +447,7 @@  select_prio (struct path * pp)
 	prio_get(p, DEFAULT_PRIO, DEFAULT_PRIO_ARGS);
 	condlog(3, "%s: prio = %s (internal default)",
 		pp->dev, DEFAULT_PRIO);
-	condlog(3, "%s: prio = %s (internal default)",
+	condlog(3, "%s: prio args = %s (internal default)",
 		pp->dev, DEFAULT_PRIO_ARGS);
 	return 0;
 }