@@ -143,9 +143,9 @@ static void nwinfo_help(void)
143143 " 'NOCSMI' and 'CSMIRAID'.\n"
144144 " --display[=FILE] Print EDID info.\n"
145145 " FILE Specify the file name of the EDID dump.\n"
146- " --pci[=CLASS] Print PCI info.\n"
147- " CLASS specifies the class code of PCI devices,\n"
148- " e.g. '0C05' (SMBus) .\n"
146+ " --pci[=CLASS,..] Print PCI info.\n"
147+ " CLASS specifies the class codes of PCI devices,\n"
148+ " e.g. '0c05' or '03,0c05' .\n"
149149 " --usb Print USB info.\n"
150150 " --spd[=FILE] Print DIMM SPD info.\n"
151151 " WARNING: This option may damage the hardware.\n"
@@ -275,6 +275,7 @@ int main(int argc, char* argv[])
275275 nwContext .AcpiTable = 0 ;
276276 nwContext .SmbiosTypes = NULL ;
277277 nwContext .DiskPath = NULL ;
278+ nwContext .PciClasses = NULL ;
278279
279280 struct optparse options ;
280281 optparse_init (& options , argv );
@@ -354,8 +355,7 @@ int main(int argc, char* argv[])
354355 nwContext .AcpiInfo = TRUE;
355356 break ;
356357 case NW_OPT_SMBIOS :
357- if (options .optarg && options .optarg [0 ])
358- nwinfo_parse_arg_set (options .optarg , & nwContext .SmbiosTypes , FALSE);
358+ nwinfo_parse_arg_set (options .optarg , & nwContext .SmbiosTypes , FALSE);
359359 nwContext .DmiInfo = TRUE;
360360 break ;
361361 case NW_OPT_DISK :
@@ -420,8 +420,7 @@ int main(int argc, char* argv[])
420420 nwContext .EdidInfo = TRUE;
421421 break ;
422422 case NW_OPT_PCI :
423- if (options .optarg && options .optarg [0 ])
424- nwContext .PciClass = options .optarg ;
423+ nwinfo_parse_arg_set (options .optarg , & nwContext .PciClasses , TRUE);
425424 nwContext .PciInfo = TRUE;
426425 break ;
427426 case NW_OPT_USB :
0 commit comments