diff options
-rw-r--r-- | ldetect.spec | 6 | ||||
-rw-r--r-- | pci.c | 15 |
2 files changed, 18 insertions, 3 deletions
diff --git a/ldetect.spec b/ldetect.spec index 399c720..5003955 100644 --- a/ldetect.spec +++ b/ldetect.spec @@ -1,6 +1,6 @@ Name: ldetect Version: 0.4.9 -Release: 1mdk +Release: 2mdk Summary: Light hardware detection library Source: %name.tar.bz2 Group: System/Libraries @@ -49,6 +49,10 @@ rm -rf $RPM_BUILD_ROOT %_libdir/* %changelog +* Thu Jul 31 2003 Pixel <pixel@mandrakesoft.com> 0.4.9-2mdk +- detect ohci1394 & ehci-hcd based on the pci class + (as done in RedHat's kudzu) + * Tue Apr 22 2003 Pixel <pixel@mandrakesoft.com> 0.4.9-1mdk - Use read() instead of fread() to read from "/proc/bus/pci/%02x/%02x.%d". Thanks a lot to Tom Cox for finding this bug: @@ -65,8 +65,19 @@ extern struct pciusb_entries pci_probe(int probe_type) { e->subdevice = 0xffff; } class_prog = buf[0x9]; - if (e->class_ == PCI_CLASS_SERIAL_USB) /* taken from kudzu's pci.c */ - e->module = strdup(class_prog == 0 ? "usb-uhci" : "usb-ohci"); + if (e->class_ == PCI_CLASS_SERIAL_USB) { + /* taken from kudzu's pci.c */ + char *module = + class_prog == 0 ? "usb-uhci" : + class_prog == 0x10 ? "usb-ohci" : + class_prog == 0x20 ? "ehci-hcd" : NULL; + if (module) e->module = strdup(module); + } + if (e->class_ == PCI_CLASS_SERIAL_FIREWIRE) { + /* taken from kudzu's pci.c */ + if (class_prog == 0x10) e->module = strdup("ohci1394"); + } + close(devf); } fclose(f); |