Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 16 Feb 2024 20:10:17 GMT
From:      John Baldwin <jhb@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: 66d37dbedfbf - main - pci_host_generic: Fix build without PCI_RES_BUS
Message-ID:  <202402162010.41GKAHMd054864@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by jhb:

URL: https://cgit.FreeBSD.org/src/commit/?id=66d37dbedfbf2dc94ccf49e6983c3652d5909b91

commit 66d37dbedfbf2dc94ccf49e6983c3652d5909b91
Author:     John Baldwin <jhb@FreeBSD.org>
AuthorDate: 2024-02-16 20:09:46 +0000
Commit:     John Baldwin <jhb@FreeBSD.org>
CommitDate: 2024-02-16 20:09:46 +0000

    pci_host_generic: Fix build without PCI_RES_BUS
    
    Fixes:          d79b6b8ec267 pci_host_generic: Don't rewrite resource start address for translation
---
 sys/dev/pci/pci_host_generic.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/sys/dev/pci/pci_host_generic.c b/sys/dev/pci/pci_host_generic.c
index 386b8411d29a..520462972a66 100644
--- a/sys/dev/pci/pci_host_generic.c
+++ b/sys/dev/pci/pci_host_generic.c
@@ -537,10 +537,14 @@ struct resource *
 pci_host_generic_core_alloc_resource(device_t dev, device_t child, int type,
     int *rid, rman_res_t start, rman_res_t end, rman_res_t count, u_int flags)
 {
+#if defined(NEW_PCIB) && defined(PCI_RES_BUS)
 	struct generic_pcie_core_softc *sc;
+#endif
 	struct resource *res;
 
+#if defined(NEW_PCIB) && defined(PCI_RES_BUS)
 	sc = device_get_softc(dev);
+#endif
 
 	switch (type) {
 #if defined(NEW_PCIB) && defined(PCI_RES_BUS)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202402162010.41GKAHMd054864>