From fa619d726d5ac3a25aca302987e08008bade1836 Mon Sep 17 00:00:00 2001 From: Stephen Hemminger Date: Wed, 13 Jun 2012 00:03:45 -0700 Subject: PCI-E physical slot number doesn't work right The use of PCI-E physical slot number doesn't work. But on same systems the DMI slot information does work. So for now just remove PCI-E slot code. --- src/pci.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/pci.c b/src/pci.c index 31b4457..29c40f5 100644 --- a/src/pci.c +++ b/src/pci.c @@ -263,6 +263,7 @@ static int pci_find_capability(struct pci_dev *p, int cap) static struct pci_device * find_parent(struct libbiosdevname_state *state, struct pci_device *dev); +#if 0 static int pcie_get_slot(struct libbiosdevname_state *state, struct pci_device *p) { int pos; @@ -280,6 +281,7 @@ static int pcie_get_slot(struct libbiosdevname_state *state, struct pci_device * } return PHYSICAL_SLOT_UNKNOWN; } +#endif static int read_pci_sysfs_path(char *buf, size_t bufsize, const struct pci_dev *pdev) { @@ -498,8 +500,11 @@ static void dev_to_slot(struct libbiosdevname_state *state, struct pci_device *d int slot; do { slot = pci_dev_to_slot(state, d); +#if 0 + /* PCI-E slot detection is broken?? */ if (slot == PHYSICAL_SLOT_UNKNOWN) slot = pcie_get_slot(state, d); +#endif if (slot == PHYSICAL_SLOT_UNKNOWN) slot = pirq_dev_to_slot(state, d); if (slot == PHYSICAL_SLOT_UNKNOWN) -- cgit v1.2.3