Skip to contentSkip to conversation

multipath-tools: enable retain_hw_handler and detect_prio by default

PATCH New Xose Vazquez Perez 1 participant 2 messages Jul 9, 2016 Device mapper

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 multipath-tools: enable retain_hw_handler and detect_prio by default

Based on previous Hannes's work.

He wrote:
"And for several versions (years, even) the linux kernel has the ability to correctly detect the device handler, so we should be making 'retain_hw_handler' the default.
And if we do this we also want to enable 'detect_prio', to ensure we pick the correct prioritizer."

Cc Hannes Reinecke <[email protected]>
Cc Christophe Varoqui <[email protected]>
Cc device-mapper development <[email protected]>
---
 libmultipath/defaults.h    | 4 ++--
 multipath/multipath.conf.5 | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)
libmultipath/defaults.h +2 -2
index dc70a74..dd6a24b 100644
@@ -16,8 +16,8 @@
 #define DEFAULT_FIND_MULTIPATHS	0
 #define DEFAULT_FAST_IO_FAIL	5
 #define DEFAULT_DEV_LOSS_TMO	600
-#define DEFAULT_RETAIN_HWHANDLER RETAIN_HWHANDLER_OFF
-#define DEFAULT_DETECT_PRIO	DETECT_PRIO_OFF
+#define DEFAULT_RETAIN_HWHANDLER RETAIN_HWHANDLER_ON
+#define DEFAULT_DETECT_PRIO	DETECT_PRIO_ON
 #define DEFAULT_DEFERRED_REMOVE	DEFERRED_REMOVE_OFF
 #define DEFAULT_DELAY_CHECKS	DELAY_CHECKS_OFF
 #define DEFAULT_UEVENT_STACKSIZE 256
multipath/multipath.conf.5 +2 -2
index 709ab3c..1da2de1 100644
@@ -561,7 +561,7 @@ mutipath.conf. If the SCSI layer has not attached a hardware handler,
 multipath will continue to use its configured hardware handler.
 .RS
 .TP
-Default value is: \fBno\fR
+Default value is: \fByes\fR
 .RE
 .TP
 .B detect_prio
@@ -573,7 +573,7 @@ device will automatically use the
 prioritizer. If not, the prioritizer will be selected as usual.
 .RS
 .TP
-Default value is: \fBno\fR
+Default value is: \fByes\fR
 .RE
 .TP
 .B force_sync
Signature · 1 line
2.7.4
#1 lore raw

PATCH 2/2 multipath-tools: delete retain_hwhandler and detect_prio attributes when they are equal to default values

3 .retain_hwhandler = RETAIN_HWHANDLER_ON,
3 .detect_prio = DETECT_PRIO_ON,

Cc Hannes Reinecke <[email protected]>
Cc Christophe Varoqui <[email protected]>
Cc device-mapper development <[email protected]>
---
 libmultipath/hwtable.c | 6 ------
 1 file changed, 6 deletions(-)
libmultipath/hwtable.c +0 -6
index e5c3fef..b4656c7 100644
@@ -212,8 +212,6 @@ static struct hwentry default_hw[] = {
 		.no_path_retry = (300 / DEFAULT_CHECKINT),
 		.checker_name  = EMC_CLARIION,
 		.prio_name     = PRIO_EMC,
-		.retain_hwhandler = RETAIN_HWHANDLER_ON,
-		.detect_prio   = DETECT_PRIO_ON,
 	},
 	{
 		.vendor        = "EMC",
@@ -611,8 +609,6 @@ static struct hwentry default_hw[] = {
 		.minio         = 128,
 		.dev_loss      = MAX_DEV_LOSS_TMO,
 		.prio_name     = PRIO_ONTAP,
-		.retain_hwhandler = RETAIN_HWHANDLER_ON,
-		.detect_prio   = DETECT_PRIO_ON,
 	},
 	{
 		/* IBM NSeries */
@@ -815,8 +811,6 @@ static struct hwentry default_hw[] = {
 		.no_path_retry = 30,
 		.checker_name  = RDAC,
 		.prio_name     = PRIO_RDAC,
-		.detect_prio   = DETECT_PRIO_ON,
-		.retain_hwhandler = RETAIN_HWHANDLER_ON,
 	},
 	{
 		.vendor        = "STK",
Signature · 1 line
2.7.4