multipath-tools: add directio path_checker for DASD devices
[multipath-tools/.git] / libmultipath / hwtable.c
1 #include <stdio.h>
2
3 #include "checkers.h"
4 #include "vector.h"
5 #include "defaults.h"
6 #include "structs.h"
7 #include "config.h"
8 #include "pgpolicies.h"
9 #include "prio.h"
10 #include "hwtable.h"
11
12 /*
13  * Tuning suggestions on these parameters should go to
14  * dm-devel@redhat.com (subscribers-only, see README)
15  *
16  * You are welcome to claim maintainership over a controller
17  * family. Please mail the currently enlisted maintainer and
18  * the upstream package maintainer.
19  *
20  * Please, use the TEMPLATE below to add new hardware.
21  *
22  * WARNING:
23  *
24  * Devices with a proprietary handler must also be included in
25  * the kernel side. Currently at drivers/scsi/scsi_dh.c
26  *
27  * Moreover, if a device needs a special treatment by the SCSI
28  * subsystem it should be included in drivers/scsi/scsi_devinfo.c
29  */
30
31 #if 0
32         /*
33          * Copy this TEMPLATE to add new hardware.
34          *
35          * Keep only mandatory(.vendor and .product) and modified attributes.
36          * Attributes with default values must be removed.
37          * .vendor, .product, .revision and .bl_product are POSIX Extended regex.
38          *
39          * COMPANY_NAME
40          *
41          * Maintainer : XXX
42          * Mail : XXX
43          */
44         {
45                 /* Product Name */
46                 .vendor        = "VENDOR",
47                 .product       = "PRODUCT",
48                 .revision      = "REVISION",
49                 .bl_product    = "BL_PRODUCT",
50                 .pgpolicy      = FAILOVER,
51                 .uid_attribute = "ID_SERIAL",
52                 .selector      = "service-time 0",
53                 .checker_name  = TUR,
54                 .alias_prefix  = "mpath",
55                 .features      = "0",
56                 .hwhandler     = "0",
57                 .prio_name     = PRIO_CONST,
58                 .prio_args     = "",
59                 .pgfailback    = -FAILBACK_MANUAL,
60                 .rr_weight     = RR_WEIGHT_NONE,
61                 .no_path_retry = NO_PATH_RETRY_UNDEF,
62                 .minio         = 1000,
63                 .minio_rq      = 1,
64                 .flush_on_last_del = FLUSH_DISABLED,
65                 .user_friendly_names = USER_FRIENDLY_NAMES_OFF,
66                 .fast_io_fail  = 5,
67                 .dev_loss      = 600,
68                 .retain_hwhandler = RETAIN_HWHANDLER_ON,
69                 .detect_prio   = DETECT_PRIO_ON,
70                 .detect_checker = DETECT_CHECKER_ON,
71                 .deferred_remove = DEFERRED_REMOVE_OFF,
72                 .delay_watch_checks = DELAY_CHECKS_OFF,
73                 .delay_wait_checks = DELAY_CHECKS_OFF,
74                 .skip_kpartx   = SKIP_KPARTX_OFF,
75                 .max_sectors_kb = MAX_SECTORS_KB_UNDEF,
76                 .ghost_delay   = GHOST_DELAY_OFF,
77         },
78 #endif
79
80 static struct hwentry default_hw[] = {
81         /*
82          * Generic NVMe devices
83          *
84          * Due to the parsing logic in find_hwe(), generic entries
85          * have to be put on top of this list, and more specific ones
86          * below.
87          */
88         {
89                 /* Generic NVMe */
90                 .vendor        = "NVME",
91                 .product       = ".*",
92                 .uid_attribute = "ID_WWN",
93                 .checker_name  = NONE,
94                 .retain_hwhandler = RETAIN_HWHANDLER_OFF,
95         },
96         /*
97          * Apple
98          *
99          * Maintainer : Shyam Sundar
100          * Mail : g.shyamsundar@yahoo.co.in
101          */
102         {
103                 /* Xserve RAID */
104                 .vendor        = "APPLE",
105                 .product       = "Xserve RAID",
106                 .pgpolicy      = MULTIBUS,
107         },
108         /*
109          * HPE
110          */
111         {
112                 /* 3PAR */
113                 .vendor        = "3PARdata",
114                 .product       = "VV",
115                 .pgpolicy      = GROUP_BY_PRIO,
116                 .pgfailback    = -FAILBACK_IMMEDIATE,
117                 .hwhandler     = "1 alua",
118                 .prio_name     = PRIO_ALUA,
119                 .no_path_retry = 18,
120                 .fast_io_fail  = 10,
121                 .dev_loss      = MAX_DEV_LOSS_TMO,
122         },
123         {
124                 /* RA8000 / ESA12000 */
125                 .vendor        = "DEC",
126                 .product       = "HSG80",
127                 .no_path_retry = NO_PATH_RETRY_QUEUE,
128                 .hwhandler     = "1 hp_sw",
129                 .pgpolicy      = GROUP_BY_PRIO,
130                 .checker_name  = HP_SW,
131                 .prio_name     = PRIO_HP_SW,
132         },
133         {
134                 /* VIRTUAL ARRAY 7400 */
135                 .vendor        = "HP",
136                 .product       = "A6189A",
137                 .pgpolicy      = MULTIBUS,
138                 .no_path_retry = 12,
139         },
140         {
141                 /* MSA 1000/1500 and EVA 3000/5000, with old firmware */
142                 .vendor        = "(COMPAQ|HP)",
143                 .product       = "(MSA|HSV)1[01]0",
144                 .hwhandler     = "1 hp_sw",
145                 .pgpolicy      = GROUP_BY_PRIO,
146                 .no_path_retry = 12,
147                 .checker_name  = HP_SW,
148                 .prio_name     = PRIO_HP_SW,
149         },
150         {
151                 /* MSA 1000/1500 with new firmware */
152                 .vendor        = "(COMPAQ|HP)",
153                 .product       = "MSA VOLUME",
154                 .pgpolicy      = GROUP_BY_PRIO,
155                 .pgfailback    = -FAILBACK_IMMEDIATE,
156                 .no_path_retry = 12,
157                 .prio_name     = PRIO_ALUA,
158         },
159         {
160                 /* EVA 3000/5000 with new firmware, EVA 4000/6000/8000 */
161                 .vendor        = "(COMPAQ|HP)",
162                 .product       = "(HSV1[01]1|HSV2[01]0|HSV3[046]0|HSV4[05]0)",
163                 .pgpolicy      = GROUP_BY_PRIO,
164                 .pgfailback    = -FAILBACK_IMMEDIATE,
165                 .no_path_retry = 12,
166                 .prio_name     = PRIO_ALUA,
167         },
168         {
169                 /* MSA2000 family with old firmware */
170                 .vendor        = "HP",
171                 .product       = "(MSA2[02]12fc|MSA2012i)",
172                 .pgpolicy      = MULTIBUS,
173                 .no_path_retry = 18,
174         },
175         {
176                 /* MSA2000 family with new firmware */
177                 .vendor        = "HP",
178                 .product       = "(MSA2012sa|MSA23(12|24)(fc|i|sa)|MSA2000s VOLUME)",
179                 .pgpolicy      = GROUP_BY_PRIO,
180                 .pgfailback    = -FAILBACK_IMMEDIATE,
181                 .no_path_retry = 18,
182                 .prio_name     = PRIO_ALUA,
183         },
184         {
185                 /* MSA 1040, 1050, 2040 and 2050 families */
186                 .vendor        = "HP",
187                 .product       = "MSA [12]0[45]0 SA[NS]",
188                 .pgpolicy      = GROUP_BY_PRIO,
189                 .pgfailback    = -FAILBACK_IMMEDIATE,
190                 .no_path_retry = 18,
191                 .prio_name     = PRIO_ALUA,
192         },
193         {
194                 /* SAN Virtualization Services Platform */
195                 .vendor        = "HP",
196                 .product       = "HSVX700",
197                 .hwhandler     = "1 alua",
198                 .pgpolicy      = GROUP_BY_PRIO,
199                 .pgfailback    = -FAILBACK_IMMEDIATE,
200                 .no_path_retry = 12,
201                 .prio_name     = PRIO_ALUA,
202         },
203         {
204                 /* Smart Array */
205                 .vendor        = "HP",
206                 .product       = "LOGICAL VOLUME",
207                 .pgpolicy      = MULTIBUS,
208                 .no_path_retry = 12,
209         },
210         {
211                 /* P2000 family */
212                 .vendor        = "HP",
213                 .product       = "(P2000 G3 FC|P2000G3 FC/iSCSI|P2000 G3 SAS|P2000 G3 iSCSI)",
214                 .pgpolicy      = GROUP_BY_PRIO,
215                 .pgfailback    = -FAILBACK_IMMEDIATE,
216                 .no_path_retry = 18,
217                 .prio_name     = PRIO_ALUA,
218         },
219         {
220                 /* StoreVirtual 4000 and 3200 families */
221                 .vendor        = "LEFTHAND",
222                 .product       = "(P4000|iSCSIDisk|FCDISK)",
223                 .pgpolicy      = GROUP_BY_PRIO,
224                 .pgfailback    = -FAILBACK_IMMEDIATE,
225                 .no_path_retry = 18,
226                 .prio_name     = PRIO_ALUA,
227         },
228         {
229                 /* Nimble Storage */
230                 .vendor        = "Nimble",
231                 .product       = "Server",
232                 .hwhandler     = "1 alua",
233                 .pgpolicy      = GROUP_BY_PRIO,
234                 .pgfailback    = -FAILBACK_IMMEDIATE,
235                 .prio_name     = PRIO_ALUA,
236                 .no_path_retry = NO_PATH_RETRY_QUEUE,
237         },
238                 /* SGI */
239         {
240                 /* Total Performance 9100 */
241                 .vendor        = "SGI",
242                 .product       = "TP9100",
243                 .pgpolicy      = MULTIBUS,
244         },
245         {
246                 /* Total Performance family */
247                 .vendor        = "SGI",
248                 .product       = "TP9[3457]00",
249                 .bl_product    = "Universal Xport",
250                 .pgpolicy      = GROUP_BY_PRIO,
251                 .checker_name  = RDAC,
252                 .features      = "2 pg_init_retries 50",
253                 .hwhandler     = "1 rdac",
254                 .prio_name     = PRIO_RDAC,
255                 .pgfailback    = -FAILBACK_IMMEDIATE,
256                 .no_path_retry = 30,
257         },
258         {
259                 /* (RDAC) InfiniteStorage */
260                 .vendor        = "SGI",
261                 .product       = "IS",
262                 .bl_product    = "Universal Xport",
263                 .pgpolicy      = GROUP_BY_PRIO,
264                 .checker_name  = RDAC,
265                 .features      = "2 pg_init_retries 50",
266                 .hwhandler     = "1 rdac",
267                 .prio_name     = PRIO_RDAC,
268                 .pgfailback    = -FAILBACK_IMMEDIATE,
269                 .no_path_retry = 30,
270         },
271         {
272                 /* (DDN) InfiniteStorage */
273                 .vendor        = "SGI",
274                 .product       = "^DD[46]A-",
275                 .pgpolicy      = GROUP_BY_PRIO,
276                 .pgfailback    = -FAILBACK_IMMEDIATE,
277                 .prio_name     = PRIO_ALUA,
278                 .no_path_retry = 30,
279         },
280         /*
281          * DataDirect Networks
282          */
283         {
284                 /* SAN DataDirector */
285                 .vendor        = "DDN",
286                 .product       = "SAN DataDirector",
287                 .pgpolicy      = MULTIBUS,
288         },
289         {
290                 /* EF3010 */
291                 .vendor        = "DDN",
292                 .product       = "^EF3010",
293                 .pgpolicy      = MULTIBUS,
294                 .no_path_retry = 30,
295         },
296         {
297                 /* EF3015 / S2A and SFA families */
298                 .vendor        = "DDN",
299                 .product       = "^(EF3015|S2A|SFA)",
300                 .pgpolicy      = GROUP_BY_PRIO,
301                 .pgfailback    = -FAILBACK_IMMEDIATE,
302                 .prio_name     = PRIO_ALUA,
303                 .no_path_retry = 30,
304         },
305         /*
306          * Dell EMC
307          */
308         {
309                 /* Symmetrix / DMX / VMAX / PowerMax */
310                 .vendor        = "EMC",
311                 .product       = "SYMMETRIX",
312                 .pgpolicy      = MULTIBUS,
313                 .no_path_retry = 6,
314         },
315         {
316                 /* DGC CLARiiON CX/AX / VNX and Unity */
317                 .vendor        = "^DGC",
318                 .product       = "^(RAID|DISK|VRAID)",
319                 .bl_product    = "LUNZ",
320                 .hwhandler     = "1 emc",
321                 .pgpolicy      = GROUP_BY_PRIO,
322                 .pgfailback    = -FAILBACK_IMMEDIATE,
323                 .no_path_retry = (300 / DEFAULT_CHECKINT),
324                 .checker_name  = EMC_CLARIION,
325                 .prio_name     = PRIO_EMC,
326         },
327         {
328                 /* Invista / VPLEX */
329                 .vendor        = "EMC",
330                 .product       = "Invista",
331                 .bl_product    = "LUNZ",
332                 .pgpolicy      = MULTIBUS,
333                 .no_path_retry = 5,
334         },
335         {
336                 /* XtremIO */
337                 .vendor        = "XtremIO",
338                 .product       = "XtremApp",
339                 .pgpolicy      = MULTIBUS,
340         },
341         {
342                 /*
343                  * SC Series, formerly Compellent
344                  *
345                  * Maintainer : Sean McGinnis
346                  * Mail : sean_mcginnis@dell.com
347                  */
348                 .vendor        = "COMPELNT",
349                 .product       = "Compellent Vol",
350                 .pgpolicy      = MULTIBUS,
351                 .no_path_retry = NO_PATH_RETRY_QUEUE,
352         },
353         {
354                 /* MD Series */
355                 .vendor        = "DELL",
356                 .product       = "^MD3",
357                 .bl_product    = "Universal Xport",
358                 .pgpolicy      = GROUP_BY_PRIO,
359                 .checker_name  = RDAC,
360                 .features      = "2 pg_init_retries 50",
361                 .hwhandler     = "1 rdac",
362                 .prio_name     = PRIO_RDAC,
363                 .pgfailback    = -FAILBACK_IMMEDIATE,
364                 .no_path_retry = 30,
365         },
366         /*
367          * Fujitsu
368          */
369         {
370                 /* CentricStor Virtual Tape */
371                 .vendor        = "FSC",
372                 .product       = "CentricStor",
373                 .pgpolicy      = GROUP_BY_SERIAL,
374         },
375         {
376                 /* ETERNUS family */
377                 .vendor        = "FUJITSU",
378                 .product       = "ETERNUS_DX(H|L|M|400|8000)",
379                 .pgpolicy      = GROUP_BY_PRIO,
380                 .pgfailback    = -FAILBACK_IMMEDIATE,
381                 .no_path_retry = 10,
382                 .prio_name     = PRIO_ALUA,
383         },
384         {
385                 /* FibreCAT S80 */
386                 .vendor        = "(EUROLOGC|EuroLogc)",
387                 .product       = "FC2502",
388                 .pgpolicy      = MULTIBUS,
389         },
390         {
391                 /* ETERNUS 2000, 3000 and 4000 */
392                 .vendor        = "FUJITSU",
393                 .product       = "E[234]000",
394                 .pgpolicy      = GROUP_BY_PRIO,
395                 .pgfailback    = -FAILBACK_IMMEDIATE,
396                 .no_path_retry = 10,
397                 .prio_name     = PRIO_ALUA,
398         },
399         {
400                 /* ETERNUS 6000 and 8000 */
401                 .vendor        = "FUJITSU",
402                 .product       = "E[68]000",
403                 .pgpolicy      = MULTIBUS,
404                 .no_path_retry = 10,
405         },
406         /*
407          * Hitachi
408          *
409          * Maintainer : Matthias Rudolph
410          * Mail : matthias.rudolph@hds.com
411          */
412         {
413                 /* USP-V, HUS VM, VSP, VSP G1X00 and VSP GX00 families / HP XP */
414                 .vendor        = "(HITACHI|HP)",
415                 .product       = "^OPEN-",
416                 .pgpolicy      = MULTIBUS,
417         },
418         {
419                 /* AMS other than AMS 2000 */
420                 .vendor        = "HITACHI",
421                 .product       = "^DF",
422                 .no_path_retry = NO_PATH_RETRY_QUEUE,
423                 .pgpolicy      = GROUP_BY_PRIO,
424                 .pgfailback    = -FAILBACK_IMMEDIATE,
425                 .prio_name     = PRIO_HDS,
426         },
427         {
428                 /* AMS 2000 and HUS 100 families */
429                 .vendor        = "HITACHI",
430                 .product       = "^DF600F",
431                 .pgpolicy      = MULTIBUS,
432         },
433         /*
434          * IBM
435          *
436          * Maintainer : Hannes Reinecke
437          * Mail : hare@suse.de
438          */
439         {
440                 /* ProFibre 4000R */
441                 .vendor        = "IBM",
442                 .product       = "ProFibre 4000R",
443                 .pgpolicy      = MULTIBUS,
444         },
445         {
446                 /* DS4300 / FAStT600 */
447                 .vendor        = "IBM",
448                 .product       = "^1722-600",
449                 .bl_product    = "Universal Xport",
450                 .pgpolicy      = GROUP_BY_PRIO,
451                 .checker_name  = RDAC,
452                 .features      = "2 pg_init_retries 50",
453                 .hwhandler     = "1 rdac",
454                 .prio_name     = PRIO_RDAC,
455                 .pgfailback    = -FAILBACK_IMMEDIATE,
456                 .no_path_retry = 30,
457         },
458         {
459                 /* DS4100 / FAStT100 */
460                 .vendor        = "IBM",
461                 .product       = "^1724",
462                 .bl_product    = "Universal Xport",
463                 .pgpolicy      = GROUP_BY_PRIO,
464                 .checker_name  = RDAC,
465                 .features      = "2 pg_init_retries 50",
466                 .hwhandler     = "1 rdac",
467                 .prio_name     = PRIO_RDAC,
468                 .pgfailback    = -FAILBACK_IMMEDIATE,
469                 .no_path_retry = 30,
470         },
471         {
472                 /* DS3000 / DS3200 / DS3300 / DS3400 / Boot DS */
473                 .vendor        = "IBM",
474                 .product       = "^1726",
475                 .bl_product    = "Universal Xport",
476                 .pgpolicy      = GROUP_BY_PRIO,
477                 .checker_name  = RDAC,
478                 .features      = "2 pg_init_retries 50",
479                 .hwhandler     = "1 rdac",
480                 .prio_name     = PRIO_RDAC,
481                 .pgfailback    = -FAILBACK_IMMEDIATE,
482                 .no_path_retry = 30,
483         },
484         {
485                 /* DS4400 / DS4500 / FAStT700 / FAStT900 */
486                 .vendor        = "IBM",
487                 .product       = "^1742",
488                 .bl_product    = "Universal Xport",
489                 .pgpolicy      = GROUP_BY_PRIO,
490                 .checker_name  = RDAC,
491                 .features      = "2 pg_init_retries 50",
492                 .hwhandler     = "1 rdac",
493                 .prio_name     = PRIO_RDAC,
494                 .pgfailback    = -FAILBACK_IMMEDIATE,
495                 .no_path_retry = 30,
496         },
497         {
498                 /* DS3500 / DS3512 / DS3524 */
499                 .vendor        = "IBM",
500                 .product       = "^1746",
501                 .bl_product    = "Universal Xport",
502                 .pgpolicy      = GROUP_BY_PRIO,
503                 .checker_name  = RDAC,
504                 .features      = "2 pg_init_retries 50",
505                 .hwhandler     = "1 rdac",
506                 .prio_name     = PRIO_RDAC,
507                 .pgfailback    = -FAILBACK_IMMEDIATE,
508                 .no_path_retry = 30,
509         },
510         {
511                 /* DCS3860 */
512                 .vendor        = "IBM",
513                 .product       = "^1813",
514                 .bl_product    = "Universal Xport",
515                 .pgpolicy      = GROUP_BY_PRIO,
516                 .checker_name  = RDAC,
517                 .features      = "2 pg_init_retries 50",
518                 .hwhandler     = "1 rdac",
519                 .prio_name     = PRIO_RDAC,
520                 .pgfailback    = -FAILBACK_IMMEDIATE,
521                 .no_path_retry = 30,
522         },
523         {
524                 /* DS3950 / DS4200 / DS4700 / DS5020 */
525                 .vendor        = "IBM",
526                 .product       = "^1814",
527                 .bl_product    = "Universal Xport",
528                 .pgpolicy      = GROUP_BY_PRIO,
529                 .checker_name  = RDAC,
530                 .features      = "2 pg_init_retries 50",
531                 .hwhandler     = "1 rdac",
532                 .prio_name     = PRIO_RDAC,
533                 .pgfailback    = -FAILBACK_IMMEDIATE,
534                 .no_path_retry = 30,
535         },
536         {
537                 /* DS4800 */
538                 .vendor        = "IBM",
539                 .product       = "^1815",
540                 .bl_product    = "Universal Xport",
541                 .pgpolicy      = GROUP_BY_PRIO,
542                 .checker_name  = RDAC,
543                 .features      = "2 pg_init_retries 50",
544                 .hwhandler     = "1 rdac",
545                 .prio_name     = PRIO_RDAC,
546                 .pgfailback    = -FAILBACK_IMMEDIATE,
547                 .no_path_retry = 30,
548         },
549         {
550                 /* DS5000 / DS5100 / DS5300 / DCS3700 */
551                 .vendor        = "IBM",
552                 .product       = "^1818",
553                 .bl_product    = "Universal Xport",
554                 .pgpolicy      = GROUP_BY_PRIO,
555                 .checker_name  = RDAC,
556                 .features      = "2 pg_init_retries 50",
557                 .hwhandler     = "1 rdac",
558                 .prio_name     = PRIO_RDAC,
559                 .pgfailback    = -FAILBACK_IMMEDIATE,
560                 .no_path_retry = 30,
561         },
562         {
563                 /* Netfinity Fibre Channel RAID Controller Unit */
564                 .vendor        = "IBM",
565                 .product       = "^3526",
566                 .bl_product    = "Universal Xport",
567                 .pgpolicy      = GROUP_BY_PRIO,
568                 .checker_name  = RDAC,
569                 .features      = "2 pg_init_retries 50",
570                 .hwhandler     = "1 rdac",
571                 .prio_name     = PRIO_RDAC,
572                 .pgfailback    = -FAILBACK_IMMEDIATE,
573                 .no_path_retry = 30,
574         },
575         {
576                 /* FAStT200 and FAStT500 */
577                 .vendor        = "IBM",
578                 .product       = "^(3542|3552)",
579                 .bl_product    = "Universal Xport",
580                 .pgpolicy      = GROUP_BY_PRIO,
581                 .checker_name  = RDAC,
582                 .features      = "2 pg_init_retries 50",
583                 .hwhandler     = "1 rdac",
584                 .prio_name     = PRIO_RDAC,
585                 .pgfailback    = -FAILBACK_IMMEDIATE,
586                 .no_path_retry = 30,
587         },
588         {
589                 /* Enterprise Storage Server / Shark family */
590                 .vendor        = "IBM",
591                 .product       = "^2105",
592                 .no_path_retry = NO_PATH_RETRY_QUEUE,
593                 .pgpolicy      = MULTIBUS,
594         },
595         {
596                 /* DS6000 / DS6800 */
597                 .vendor        = "IBM",
598                 .product       = "^1750500",
599                 .no_path_retry = NO_PATH_RETRY_QUEUE,
600                 .pgpolicy      = GROUP_BY_PRIO,
601                 .pgfailback    = -FAILBACK_IMMEDIATE,
602                 .prio_name     = PRIO_ALUA,
603         },
604         {
605                 /* DS8000 family */
606                 .vendor        = "IBM",
607                 .product       = "^2107900",
608                 .no_path_retry = NO_PATH_RETRY_QUEUE,
609                 .pgpolicy      = MULTIBUS,
610         },
611         {
612                 /* Storwize family / SAN Volume Controller / Flex System V7000 / FlashSystem V840/V9000 */
613                 .vendor        = "IBM",
614                 .product       = "^2145",
615                 .no_path_retry = NO_PATH_RETRY_QUEUE,
616                 .pgpolicy      = GROUP_BY_PRIO,
617                 .pgfailback    = -FAILBACK_IMMEDIATE,
618                 .prio_name     = PRIO_ALUA,
619         },
620         {
621                 /* DS6000/DS8000 DASD ECKD */
622                 .vendor        = "IBM",
623                 .product       = "S/390 DASD ECKD",
624                 .bl_product    = "S/390",
625                 .uid_attribute = "ID_UID",
626                 .no_path_retry = NO_PATH_RETRY_QUEUE,
627                 .pgpolicy      = MULTIBUS,
628                 .checker_name  = DIRECTIO,
629         },
630         {
631                 /* DS6000/DS8000 DASD FBA */
632                 .vendor        = "IBM",
633                 .product       = "S/390 DASD FBA",
634                 .bl_product    = "S/390",
635                 .uid_attribute = "ID_UID",
636                 .no_path_retry = NO_PATH_RETRY_QUEUE,
637                 .pgpolicy      = MULTIBUS,
638                 .checker_name  = DIRECTIO,
639         },
640         {
641                 /* Power RAID */
642                 .vendor        = "IBM",
643                 .product       = "^IPR",
644                 .no_path_retry = NO_PATH_RETRY_QUEUE,
645                 .hwhandler     = "1 alua",
646                 .pgpolicy      = GROUP_BY_PRIO,
647                 .pgfailback    = -FAILBACK_IMMEDIATE,
648                 .prio_name     = PRIO_ALUA,
649         },
650         {
651                 /* SAS RAID Controller Module (RSSM) */
652                 .vendor        = "IBM",
653                 .product       = "1820N00",
654                 .pgpolicy      = GROUP_BY_PRIO,
655                 .pgfailback    = -FAILBACK_IMMEDIATE,
656                 .no_path_retry = NO_PATH_RETRY_QUEUE,
657                 .prio_name     = PRIO_ALUA,
658         },
659         {
660                 /* XIV Storage System / FlashSystem A9000/A9000R */
661                 .vendor        = "(XIV|IBM)",
662                 .product       = "(NEXTRA|2810XIV)",
663                 .no_path_retry = NO_PATH_RETRY_QUEUE,
664                 .pgpolicy      = MULTIBUS,
665         },
666         {
667                 /* TMS RamSan / FlashSystem 710/720/810/820/840/900 */
668                 .vendor        = "(TMS|IBM)",
669                 .product       = "(RamSan|FlashSystem)",
670                 .pgpolicy      = MULTIBUS,
671         },
672         {
673                 /* (DDN) DCS9900, SONAS 2851-DR1 */
674                 .vendor        = "IBM",
675                 .product       = "^(DCS9900|2851)",
676                 .pgpolicy      = GROUP_BY_PRIO,
677                 .pgfailback    = -FAILBACK_IMMEDIATE,
678                 .prio_name     = PRIO_ALUA,
679                 .no_path_retry = 30,
680         },
681                 /*
682                  * IBM Power Virtual SCSI Devices
683                  *
684                  * Maintainer : Brian King
685                  * Mail : brking@linux.vnet.ibm.com
686                  */
687         {
688                 /* AIX VDASD */
689                 .vendor        = "AIX",
690                 .product       = "VDASD",
691                 .pgpolicy      = MULTIBUS,
692                 .no_path_retry = (300 / DEFAULT_CHECKINT),
693         },
694         {
695                 /* 3303 NVDISK */
696                 .vendor        = "IBM",
697                 .product       = "3303[ ]+NVDISK",
698                 .no_path_retry = (300 / DEFAULT_CHECKINT),
699         },
700         {
701                 /* AIX NVDISK */
702                 .vendor        = "AIX",
703                 .product       = "NVDISK",
704                 .hwhandler     = "1 alua",
705                 .pgpolicy      = GROUP_BY_PRIO,
706                 .pgfailback    = -FAILBACK_IMMEDIATE,
707                 .no_path_retry = (300 / DEFAULT_CHECKINT),
708                 .prio_name     = PRIO_ALUA,
709         },
710         /*
711          * NetApp
712          */
713         {
714                 /*
715                  * ONTAP family
716                  *
717                  * Maintainer : Martin George
718                  * Mail : marting@netapp.com
719                  */
720                 .vendor        = "NETAPP",
721                 .product       = "LUN",
722                 .features      = "2 pg_init_retries 50",
723                 .no_path_retry = NO_PATH_RETRY_QUEUE,
724                 .pgpolicy      = GROUP_BY_PRIO,
725                 .pgfailback    = -FAILBACK_IMMEDIATE,
726                 .flush_on_last_del = FLUSH_ENABLED,
727                 .dev_loss      = MAX_DEV_LOSS_TMO,
728                 .prio_name     = PRIO_ONTAP,
729         },
730         {
731                 /*
732                  * SANtricity(RDAC) family
733                  *
734                  * Maintainer : NetApp RDAC team
735                  * Mail : ng-eseries-upstream-maintainers@netapp.com
736                  */
737                 .vendor        = "(NETAPP|LSI|ENGENIO)",
738                 .product       = "INF-01-00",
739                 .bl_product    = "Universal Xport",
740                 .pgpolicy      = GROUP_BY_PRIO,
741                 .checker_name  = RDAC,
742                 .features      = "2 pg_init_retries 50",
743                 .hwhandler     = "1 rdac",
744                 .prio_name     = PRIO_RDAC,
745                 .pgfailback    = -FAILBACK_IMMEDIATE,
746                 .no_path_retry = 30,
747         },
748         {
749                 /*
750                  * SolidFir family
751                  *
752                  * Maintainer : PJ Waskiewicz
753                  * Mail : pj.waskiewicz@netapp.com
754                  */
755                 .vendor        = "SolidFir",
756                 .product       = "SSD SAN",
757                 .pgpolicy      = MULTIBUS,
758                 .no_path_retry = 24,
759         },
760         {
761                 /*
762                  * NVMe-FC namespace devices: MULTIBUS, queueing preferred
763                  *
764                  * The hwtable is searched backwards, so place this after "Generic NVMe"
765                  */
766                 .vendor        = "NVME",
767                 .product       = "^NetApp ONTAP Controller",
768                 .pgpolicy      = MULTIBUS,
769                 .no_path_retry = NO_PATH_RETRY_QUEUE,
770         },
771         /*
772          * Nexenta
773          *
774          * Maintainer : Yacine Kheddache
775          * Mail : yacine@alyseo.com
776          */
777         {
778                 /* COMSTAR */
779                 .vendor        = "NEXENTA",
780                 .product       = "COMSTAR",
781                 .pgpolicy      = GROUP_BY_SERIAL,
782                 .no_path_retry = 30,
783         },
784         /*
785          * NEC
786          */
787         {
788                 /* M-Series */
789                 .vendor        = "NEC",
790                 .product       = "DISK ARRAY",
791                 .hwhandler     = "1 alua",
792                 .pgpolicy      = GROUP_BY_PRIO,
793                 .pgfailback    = -FAILBACK_IMMEDIATE,
794                 .prio_name     = PRIO_ALUA,
795         },
796         /*
797          * Oracle
798          */
799                 /*
800                  * Pillar Data / Oracle FS
801                  *
802                  * Maintainer : Srinivasan Ramani
803                  * Mail : srinivas.ramani@oracle.com
804                  */
805         {
806                 /* Axiom */
807                 .vendor        = "^Pillar",
808                 .product       = "^Axiom",
809                 .pgpolicy      = GROUP_BY_PRIO,
810                 .pgfailback    = -FAILBACK_IMMEDIATE,
811                 .prio_name     = PRIO_ALUA,
812         },
813         {
814                 /* FS */
815                 .vendor        = "^Oracle",
816                 .product       = "^Oracle FS",
817                 .pgpolicy      = GROUP_BY_PRIO,
818                 .pgfailback    = -FAILBACK_IMMEDIATE,
819                 .prio_name     = PRIO_ALUA,
820         },
821                 /* Sun - StorageTek */
822         {
823                 /* B210, B220, B240 and B280 */
824                 .vendor        = "STK",
825                 .product       = "BladeCtlr",
826                 .bl_product    = "Universal Xport",
827                 .pgpolicy      = GROUP_BY_PRIO,
828                 .checker_name  = RDAC,
829                 .features      = "2 pg_init_retries 50",
830                 .hwhandler     = "1 rdac",
831                 .prio_name     = PRIO_RDAC,
832                 .pgfailback    = -FAILBACK_IMMEDIATE,
833                 .no_path_retry = 30,
834         },
835         {
836                 /* 9176, D173, D178, D210, D220, D240 and D280 */
837                 .vendor        = "STK",
838                 .product       = "OPENstorage",
839                 .bl_product    = "Universal Xport",
840                 .pgpolicy      = GROUP_BY_PRIO,
841                 .checker_name  = RDAC,
842                 .features      = "2 pg_init_retries 50",
843                 .hwhandler     = "1 rdac",
844                 .prio_name     = PRIO_RDAC,
845                 .pgfailback    = -FAILBACK_IMMEDIATE,
846                 .no_path_retry = 30,
847         },
848         {
849                 /* 6540 */
850                 .vendor        = "STK",
851                 .product       = "FLEXLINE 380",
852                 .bl_product    = "Universal Xport",
853                 .pgpolicy      = GROUP_BY_PRIO,
854                 .checker_name  = RDAC,
855                 .features      = "2 pg_init_retries 50",
856                 .hwhandler     = "1 rdac",
857                 .prio_name     = PRIO_RDAC,
858                 .pgfailback    = -FAILBACK_IMMEDIATE,
859                 .no_path_retry = 30,
860         },
861         {
862                 /* (Dot Hill) 3120, 3310, 3320, 3510 and 3511 */
863                 .vendor        = "SUN",
864                 .product       = "StorEdge 3",
865                 .pgpolicy      = MULTIBUS,
866         },
867         {
868                 /* 6580 and 6780 */
869                 .vendor        = "SUN",
870                 .product       = "STK6580_6780",
871                 .bl_product    = "Universal Xport",
872                 .pgpolicy      = GROUP_BY_PRIO,
873                 .checker_name  = RDAC,
874                 .features      = "2 pg_init_retries 50",
875                 .hwhandler     = "1 rdac",
876                 .prio_name     = PRIO_RDAC,
877                 .pgfailback    = -FAILBACK_IMMEDIATE,
878                 .no_path_retry = 30,
879         },
880         {
881                 /* 6130 / 6140 */
882                 .vendor        = "SUN",
883                 .product       = "CSM[12]00_R",
884                 .bl_product    = "Universal Xport",
885                 .pgpolicy      = GROUP_BY_PRIO,
886                 .checker_name  = RDAC,
887                 .features      = "2 pg_init_retries 50",
888                 .hwhandler     = "1 rdac",
889                 .prio_name     = PRIO_RDAC,
890                 .pgfailback    = -FAILBACK_IMMEDIATE,
891                 .no_path_retry = 30,
892         },
893         {
894                 /* 2500 / 2510 / 2530 / 2540 */
895                 .vendor        = "SUN",
896                 .product       = "LCSM100_[IEFS]",
897                 .bl_product    = "Universal Xport",
898                 .pgpolicy      = GROUP_BY_PRIO,
899                 .checker_name  = RDAC,
900                 .features      = "2 pg_init_retries 50",
901                 .hwhandler     = "1 rdac",
902                 .prio_name     = PRIO_RDAC,
903                 .pgfailback    = -FAILBACK_IMMEDIATE,
904                 .no_path_retry = 30,
905         },
906         {
907                 /* 6180 */
908                 .vendor        = "SUN",
909                 .product       = "SUN_6180",
910                 .bl_product    = "Universal Xport",
911                 .pgpolicy      = GROUP_BY_PRIO,
912                 .checker_name  = RDAC,
913                 .features      = "2 pg_init_retries 50",
914                 .hwhandler     = "1 rdac",
915                 .prio_name     = PRIO_RDAC,
916                 .pgfailback    = -FAILBACK_IMMEDIATE,
917                 .no_path_retry = 30,
918         },
919         {
920                 /* ArrayStorage */
921                 .vendor        = "SUN",
922                 .product       = "ArrayStorage",
923                 .bl_product    = "Universal Xport",
924                 .pgpolicy      = GROUP_BY_PRIO,
925                 .checker_name  = RDAC,
926                 .features      = "2 pg_init_retries 50",
927                 .hwhandler     = "1 rdac",
928                 .prio_name     = PRIO_RDAC,
929                 .pgfailback    = -FAILBACK_IMMEDIATE,
930                 .no_path_retry = 30,
931         },
932         {
933                 /* ZFS Storage Appliances */
934                 .vendor        = "SUN",
935                 .product       = "(Sun Storage|ZFS Storage|COMSTAR)",
936                 .pgpolicy      = GROUP_BY_PRIO,
937                 .pgfailback    = -FAILBACK_IMMEDIATE,
938                 .prio_name     = PRIO_ALUA,
939                 .no_path_retry = 30,
940         },
941         /*
942          * Pivot3
943          *
944          * Maintainer : Bart Brooks
945          * Mail : bartb@pivot3.com
946          */
947         {
948                 /* Raige */
949                 .vendor        = "PIVOT3",
950                 .product       = "RAIGE VOLUME",
951                 .no_path_retry = NO_PATH_RETRY_QUEUE,
952                 .pgpolicy      = MULTIBUS,
953         },
954         {
955                 /* NexGen / vSTAC */
956                 .vendor        = "(NexGen|Pivot3)",
957                 .product       = "(TierStore|vSTAC)",
958                 .pgpolicy      = GROUP_BY_PRIO,
959                 .pgfailback    = -FAILBACK_IMMEDIATE,
960                 .prio_name     = PRIO_ALUA,
961                 .no_path_retry = NO_PATH_RETRY_QUEUE,
962         },
963         /*
964          * Intel
965          */
966         {
967                 /* Multi-Flex */
968                 .vendor        = "(Intel|INTEL)",
969                 .product       = "Multi-Flex",
970                 .bl_product    = "VTrak V-LUN",
971                 .hwhandler     = "1 alua",
972                 .pgpolicy      = GROUP_BY_PRIO,
973                 .pgfailback    = -FAILBACK_IMMEDIATE,
974                 .no_path_retry = NO_PATH_RETRY_QUEUE,
975                 .prio_name     = PRIO_ALUA,
976         },
977         /*
978          * Linux-IO Target
979          */
980         {
981                 /* Linux-IO Target */
982                 .vendor        = "(LIO-ORG|SUSE)",
983                 .product       = "RBD",
984                 .hwhandler     = "1 alua",
985                 .pgpolicy      = GROUP_BY_PRIO,
986                 .pgfailback    = -FAILBACK_IMMEDIATE,
987                 .no_path_retry = 12,
988                 .prio_name     = PRIO_ALUA,
989         },
990         /*
991          * DataCore
992          */
993         {
994                 /* SANmelody */
995                 .vendor        = "DataCore",
996                 .product       = "SANmelody",
997                 .pgpolicy      = GROUP_BY_PRIO,
998                 .pgfailback    = -FAILBACK_IMMEDIATE,
999                 .no_path_retry = NO_PATH_RETRY_QUEUE,
1000                 .prio_name     = PRIO_ALUA,
1001         },
1002         {
1003                 /* SANsymphony */
1004                 .vendor        = "DataCore",
1005                 .product       = "Virtual Disk",
1006                 .pgpolicy      = GROUP_BY_PRIO,
1007                 .pgfailback    = -FAILBACK_IMMEDIATE,
1008                 .no_path_retry = NO_PATH_RETRY_QUEUE,
1009                 .prio_name     = PRIO_ALUA,
1010         },
1011         /*
1012          * Pure Storage
1013          */
1014         {
1015                 /* FlashArray */
1016                 .vendor        = "PURE",
1017                 .product       = "FlashArray",
1018                 .pgpolicy      = MULTIBUS,
1019         },
1020         /*
1021          * Huawei
1022          */
1023         {
1024                 /* OceanStor V3 */
1025                 .vendor        = "HUAWEI",
1026                 .product       = "XSG1",
1027                 .pgpolicy      = GROUP_BY_PRIO,
1028                 .prio_name     = PRIO_ALUA,
1029         },
1030         /*
1031          * Kove
1032          */
1033         {
1034                 /* XPD */
1035                 .vendor        = "KOVE",
1036                 .product       = "XPD",
1037                 .pgpolicy      = MULTIBUS,
1038         },
1039         /*
1040          * Infinidat
1041          *
1042          * Maintainer: Arnon Yaari
1043          * Mail: arnony@infinidat.com
1044          */
1045         {
1046                 /* InfiniBox */
1047                 .vendor        = "NFINIDAT",
1048                 .product       = "InfiniBox",
1049                 .pgpolicy      = GROUP_BY_PRIO,
1050                 .pgfailback    = 30,
1051                 .prio_name     = PRIO_ALUA,
1052                 .selector      = "round-robin 0",
1053                 .rr_weight     = RR_WEIGHT_PRIO,
1054                 .no_path_retry = NO_PATH_RETRY_FAIL,
1055                 .minio         = 1,
1056                 .minio_rq      = 1,
1057                 .flush_on_last_del = FLUSH_ENABLED,
1058                 .fast_io_fail  = 15,
1059                 .dev_loss      = 15,
1060         },
1061         /*
1062          * Kaminario
1063          */
1064         {
1065                 /* K2 */
1066                 .vendor        = "KMNRIO",
1067                 .product       = "K2",
1068                 .pgpolicy      = MULTIBUS,
1069         },
1070         /*
1071          * Western Digital (Tegile Systems)
1072          */
1073         {
1074                 /* IntelliFlash */
1075                 .vendor        = "TEGILE",
1076                 .product       = "(ZEBI-(FC|ISCSI)|INTELLIFLASH)",
1077                 .hwhandler     = "1 alua",
1078                 .pgpolicy      = GROUP_BY_PRIO,
1079                 .pgfailback    = -FAILBACK_IMMEDIATE,
1080                 .prio_name     = PRIO_ALUA,
1081                 .no_path_retry = 10,
1082         },
1083         /*
1084          * Imation/Nexsan
1085          */
1086         {
1087                 /* E-Series */
1088                 .vendor        = "NEXSAN",
1089                 .product       = "NXS-B0",
1090                 .pgpolicy      = GROUP_BY_PRIO,
1091                 .pgfailback    = -FAILBACK_IMMEDIATE,
1092                 .prio_name     = PRIO_ALUA,
1093                 .no_path_retry = 15,
1094         },
1095         {
1096                 /* SATABeast / SATABoy */
1097                 .vendor        = "NEXSAN",
1098                 .product       = "SATAB",
1099                 .pgpolicy      = GROUP_BY_PRIO,
1100                 .pgfailback    = -FAILBACK_IMMEDIATE,
1101                 .prio_name     = PRIO_ALUA,
1102                 .no_path_retry = 15,
1103         },
1104         {
1105                 /* NST / UNITY */
1106                 .vendor        = "Nexsan",
1107                 .product       = "(NestOS|NST5000)",
1108                 .hwhandler     = "1 alua",
1109                 .pgpolicy      = GROUP_BY_PRIO,
1110                 .pgfailback    = -FAILBACK_IMMEDIATE,
1111                 .prio_name     = PRIO_ALUA,
1112                 .no_path_retry = 30,
1113         },
1114         /*
1115          * Xiotech
1116          */
1117         {
1118                 /* Intelligent Storage Elements family */
1119                 .vendor        = "(XIOTECH|XIOtech)",
1120                 .product       = "ISE",
1121                 .pgpolicy      = MULTIBUS,
1122                 .no_path_retry = 12,
1123         },
1124         {
1125                 /* iglu blaze family */
1126                 .vendor        = "(XIOTECH|XIOtech)",
1127                 .product       = "IGLU DISK",
1128                 .pgpolicy      = MULTIBUS,
1129                 .no_path_retry = 30,
1130         },
1131         {
1132                 /* Magnitude family */
1133                 .vendor        = "(XIOTECH|XIOtech)",
1134                 .product       = "Magnitude",
1135                 .pgpolicy      = MULTIBUS,
1136                 .no_path_retry = 30,
1137         },
1138         /*
1139          * Violin Memory
1140          */
1141         {
1142                 /* 3000 / 6000 Series */
1143                 .vendor        = "VIOLIN",
1144                 .product       = "SAN ARRAY$",
1145                 .pgpolicy      = GROUP_BY_SERIAL,
1146                 .no_path_retry = 30,
1147         },
1148         {
1149                 /* 3000 / 6000 Series - ALUA mode */
1150                 .vendor        = "VIOLIN",
1151                 .product       = "SAN ARRAY ALUA",
1152                 .hwhandler     = "1 alua",
1153                 .pgpolicy      = GROUP_BY_PRIO,
1154                 .pgfailback    = -FAILBACK_IMMEDIATE,
1155                 .prio_name     = PRIO_ALUA,
1156                 .no_path_retry = 30,
1157         },
1158         {
1159                 /* FSP 7000 family */
1160                 .vendor        = "VIOLIN",
1161                 .product       = "CONCERTO ARRAY",
1162                 .pgpolicy      = MULTIBUS,
1163                 .no_path_retry = 30,
1164         },
1165         /*
1166          * Promise Technology
1167          */
1168         {
1169                 /* VTrak family */
1170                 .vendor        = "Promise",
1171                 .product       = "VTrak",
1172                 .bl_product    = "VTrak V-LUN",
1173                 .hwhandler     = "1 alua",
1174                 .pgpolicy      = GROUP_BY_PRIO,
1175                 .pgfailback    = -FAILBACK_IMMEDIATE,
1176                 .prio_name     = PRIO_ALUA,
1177                 .no_path_retry = 30,
1178         },
1179         {
1180                 /* Vess family */
1181                 .vendor        = "Promise",
1182                 .product       = "Vess",
1183                 .bl_product    = "Vess V-LUN",
1184                 .hwhandler     = "1 alua",
1185                 .pgpolicy      = GROUP_BY_PRIO,
1186                 .pgfailback    = -FAILBACK_IMMEDIATE,
1187                 .prio_name     = PRIO_ALUA,
1188                 .no_path_retry = 30,
1189         },
1190         /*
1191          * Infortrend Technology
1192          */
1193         {
1194                 /* EonStor / ESVA */
1195                 .vendor        = "^IFT",
1196                 .product       = ".*",
1197                 .pgpolicy      = GROUP_BY_PRIO,
1198                 .pgfailback    = -FAILBACK_IMMEDIATE,
1199                 .prio_name     = PRIO_ALUA,
1200                 .no_path_retry = 30,
1201         },
1202         /*
1203          * Seagate Technology (Dot Hill Systems)
1204          */
1205         {
1206                 /* SANnet family */
1207                 .vendor        = "DotHill",
1208                 .product       = "SANnet",
1209                 .pgpolicy      = MULTIBUS,
1210                 .no_path_retry = 30,
1211         },
1212         {
1213                 /* R/Evolution family */
1214                 .vendor        = "DotHill",
1215                 .product       = "R/Evo",
1216                 .pgpolicy      = GROUP_BY_PRIO,
1217                 .pgfailback    = -FAILBACK_IMMEDIATE,
1218                 .prio_name     = PRIO_ALUA,
1219                 .no_path_retry = 30,
1220         },
1221         {
1222                 /* AssuredSAN family */
1223                 .vendor        = "DotHill",
1224                 .product       = "^DH",
1225                 .pgpolicy      = GROUP_BY_PRIO,
1226                 .pgfailback    = -FAILBACK_IMMEDIATE,
1227                 .prio_name     = PRIO_ALUA,
1228                 .no_path_retry = 30,
1229         },
1230         /*
1231          * AccelStor
1232          */
1233         {
1234                 /* NeoSapphire */
1235                 .vendor        = "AStor",
1236                 .product       = "NeoSapphire",
1237                 .pgpolicy      = MULTIBUS,
1238                 .no_path_retry = 30,
1239         },
1240         /*
1241          * INSPUR
1242          */
1243         {
1244                 /* AS5300/AS5500 G2 */
1245                 .vendor        = "INSPUR",
1246                 .product       = "MCS",
1247                 .pgpolicy      = GROUP_BY_PRIO,
1248                 .pgfailback    = -FAILBACK_IMMEDIATE,
1249                 .prio_name     = PRIO_ALUA,
1250         },
1251         /*
1252          * EOL
1253          */
1254         {
1255                 /* NULL */
1256                 .vendor        = NULL,
1257                 .product       = NULL,
1258         },
1259 };
1260
1261 int setup_default_hwtable(vector hw)
1262 {
1263         int r = 0;
1264         struct hwentry * hwe = default_hw;
1265
1266         while (hwe->vendor) {
1267                 r += store_hwe(hw, hwe);
1268                 hwe++;
1269         }
1270         return r;
1271 }