From c1973cc94eed9e94518cfc9a8ecbb6585c8808bf Mon Sep 17 00:00:00 2001 From: markj Date: Wed, 23 Aug 2017 16:50:10 +0000 Subject: [PATCH] Set the bus number field when attaching a PCI device. MFC after: 1 week --- sys/compat/linuxkpi/common/src/linux_pci.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/compat/linuxkpi/common/src/linux_pci.c b/sys/compat/linuxkpi/common/src/linux_pci.c index 9220a2d90409..a1fc2461800b 100644 --- a/sys/compat/linuxkpi/common/src/linux_pci.c +++ b/sys/compat/linuxkpi/common/src/linux_pci.c @@ -167,6 +167,7 @@ linux_pci_attach(device_t dev) if (pdev->bus == NULL) { pbus = malloc(sizeof(*pbus), M_DEVBUF, M_WAITOK | M_ZERO); pbus->self = pdev; + pbus->number = pci_get_bus(dev); pdev->bus = pbus; }