All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Fixup hwtable regexp
@ 2006-09-01  7:18 Hannes Reinecke
  0 siblings, 0 replies; only message in thread
From: Hannes Reinecke @ 2006-09-01  7:18 UTC (permalink / raw)
  To: christophe varoqui; +Cc: device-mapper development

[-- Attachment #1: Type: text/plain, Size: 550 bytes --]

Hi Christophe,

appearently no-one noticed that we've switched to regular expressions 
instead of shell-style fnmatch for the hwtable.
Quite surprisingly, really, that no-one complained; the change has been 
done in October 2005.

Anyway, this patch cleans it up. And also splits off the IBM DS6000 and 
IBM SVC, as they are separate machines.

Please apply.

Cheers,

Hannes
-- 
Dr. Hannes Reinecke			hare@suse.de
SuSE Linux Products GmbH		S390 & zSeries
Maxfeldstraße 5				+49 911 74053 688
90409 Nürnberg				http://www.suse.de

[-- Attachment #2: multipath-tools-fixup-hwtable-regexp --]
[-- Type: text/plain, Size: 3810 bytes --]

diff --git a/libmultipath/hwtable.c b/libmultipath/hwtable.c
index deb99e5..c395bf1 100644
--- a/libmultipath/hwtable.c
+++ b/libmultipath/hwtable.c
@@ -75,14 +75,14 @@ static struct hwentry default_hw[] = {
 		.checker_name  = HP_SW,
 	},
 	{
-		.vendor        = "{COMPAQ,HP}",
-		.product       = "{MSA,HSV}1*",
+		.vendor        = "(COMPAQ|HP)",
+		.product       = "(MSA|HSV)1.*",
 		.getuid        = DEFAULT_GETUID,
 		.getprio       = NULL,
 		.features      = DEFAULT_FEATURES,
 		.hwhandler     = "1 hp_sw",
 		.selector      = DEFAULT_SELECTOR,
-		.pgpolicy      = GROUP_BY_SERIAL,
+		.pgpolicy      = MULTIBUS,
 		.pgfailback    = FAILBACK_UNDEF,
 		.rr_weight     = RR_WEIGHT_NONE,
 		.no_path_retry = NO_PATH_RETRY_UNDEF,
@@ -91,7 +91,7 @@ static struct hwentry default_hw[] = {
 	},
 	{
 		.vendor        = "HP",
-		.product       = "{HSV2*,A6189A}",
+		.product       = "(HSV2.*|A6189A)",
 		.getuid        = DEFAULT_GETUID,
 		.getprio       = NULL,
 		.features      = DEFAULT_FEATURES,
@@ -148,7 +148,7 @@ static struct hwentry default_hw[] = {
 	},
 	{
 		.vendor        = "DGC",
-		.product       = "*",
+		.product       = ".*",
 		.bl_product    = "LUNZ",
 		.getuid        = DEFAULT_GETUID,
 		.getprio       = "mpath_prio_emc /dev/%n",
@@ -190,8 +190,8 @@ static struct hwentry default_hw[] = {
 	 * Mail : matthias.rudolph@hds.com
 	 */
 	{
-		.vendor        = "{HITACHI,HP}",
-		.product       = "OPEN-*",
+		.vendor        = "(HITACHI|HP)",
+		.product       = "OPEN-.*",
 		.getuid        = DEFAULT_GETUID,
 		.getprio       = NULL,
 		.features      = DEFAULT_FEATURES,
@@ -206,9 +206,9 @@ static struct hwentry default_hw[] = {
 	},
 	{
 		.vendor        = "HITACHI",
-		.product       = "DF*",
+		.product       = "DF.*",
 		.getuid        = DEFAULT_GETUID,
-		.getprio       = "/sbin/mpath_prio_hds_modular %d",
+		.getprio       = "mpath_prio_hds_modular %d",
 		.features      = DEFAULT_FEATURES,
 		.hwhandler     = DEFAULT_HWHANDLER,
 		.selector      = DEFAULT_SELECTOR,
@@ -275,7 +291,7 @@ static struct hwentry default_hw[] = {
 	{
 		/* IBM ESS F20 aka Shark */
 		.vendor        = "IBM",
-		.product       = "2105{800,F20}",
+		.product       = "2105(800|F20)",
 		.getuid        = DEFAULT_GETUID,
 		.getprio       = NULL,
 		.features      = "1 queue_if_no_path",
@@ -289,9 +305,9 @@ static struct hwentry default_hw[] = {
 		.checker_name  = TUR,
 	},
 	{
-		/* IBM DS6000 / SAN Volume Controller */
+		/* IBM DS6000 */
 		.vendor        = "IBM",
-		.product       = "{1750500,2145}",
+		.product       = "1750500",
 		.getuid        = DEFAULT_GETUID,
 		.getprio       = "mpath_prio_alua /dev/%n",
 		.features      = "1 queue_if_no_path",
@@ -321,9 +337,26 @@ static struct hwentry default_hw[] = {
 		.checker_name  = TUR,
 	},
 	{
+		/* IBM SAN Volume Controller */
+		.vendor        = "IBM",
+		.product       = "2145",
+		.getuid        = DEFAULT_GETUID,
+		.getprio       = "mpath_prio_alua /dev/%n",
+		.features      = "1 queue_if_no_path",
+		.hwhandler     = DEFAULT_HWHANDLER,
+		.selector      = DEFAULT_SELECTOR,
+		.pgpolicy      = GROUP_BY_PRIO,
+		.pgfailback    = -FAILBACK_IMMEDIATE,
+		.rr_weight     = RR_WEIGHT_NONE,
+		.no_path_retry = NO_PATH_RETRY_UNDEF,
+		.minio         = DEFAULT_MINIO,
+		.checker_name  = TUR,
+	},
+	{
 		/* IBM S/390 ECKD DASD */
 		.vendor        = "IBM",
 		.product       = "S/390 DASD ECKD",
+		.bl_product       = "S/390.*",
 		.getuid        = "/sbin/dasd_id /dev/%n",
 		.getprio       = NULL,
 		.features      = DEFAULT_FEATURES,
@@ -464,7 +497,7 @@ static struct hwentry default_hw[] = {
 	 */
 	{
 		.vendor        = "SUN",
-		.product       = "{StorEdge 3510,T4}",
+		.product       = "(StorEdge 3510|T4)",
 		.getuid        = DEFAULT_GETUID,
 		.getprio       = NULL,
 		.features      = DEFAULT_FEATURES,

[-- Attachment #3: Type: text/plain, Size: 0 bytes --]



^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2006-09-01  7:18 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-09-01  7:18 [PATCH] Fixup hwtable regexp Hannes Reinecke

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.