summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@vyatta.com>2012-06-13 00:03:45 -0700
committerStephen Hemminger <shemminger@vyatta.com>2012-06-13 00:03:45 -0700
commitfa619d726d5ac3a25aca302987e08008bade1836 (patch)
tree1ee0ed5e18b5b8ebce8aee55502919ef44a6f7ab
parenta157245510ddf78e6faa2e5e89a392d2a9e1640e (diff)
downloadvyatta-biosdevname-fa619d726d5ac3a25aca302987e08008bade1836.tar.gz
vyatta-biosdevname-fa619d726d5ac3a25aca302987e08008bade1836.zip
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.
-rw-r--r--src/pci.c5
1 files changed, 5 insertions, 0 deletions
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)