diff --git a/sys/dev/pci/pci_subr.c b/sys/dev/pci/pci_subr.c index 65372632f..462fd5672 100644 --- a/sys/dev/pci/pci_subr.c +++ b/sys/dev/pci/pci_subr.c @@ -617,7 +617,11 @@ pci_subclass_name(pcireg_t reg) subclassp++; } - return subclassp->name; + if (subclassp) { + return subclassp->name; + } else { + return NULL; + } } #endif /* defined(__minix) && defined(_PCI_SERVER) */