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