diff options
-rw-r--r-- | sys/arch/i386/pci/pci_addr_fixup.c | 38 | ||||
-rw-r--r-- | sys/arch/i386/pci/pcibiosvar.h | 3 |
2 files changed, 2 insertions, 39 deletions
diff --git a/sys/arch/i386/pci/pci_addr_fixup.c b/sys/arch/i386/pci/pci_addr_fixup.c index 294454e7a1a..e4eb1b4a2de 100644 --- a/sys/arch/i386/pci/pci_addr_fixup.c +++ b/sys/arch/i386/pci/pci_addr_fixup.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pci_addr_fixup.c,v 1.21 2007/02/20 21:15:01 tom Exp $ */ +/* $OpenBSD: pci_addr_fixup.c,v 1.22 2010/07/02 16:11:19 jsg Exp $ */ /* $NetBSD: pci_addr_fixup.c,v 1.7 2000/08/03 20:10:45 nathanw Exp $ */ /*- @@ -410,39 +410,3 @@ pciaddr_device_is_agp(pci_chipset_tag_t pc, pcitag_t tag) } return (0); } - - -struct extent * -pciaddr_search(int mem_port, bus_addr_t *startp, bus_size_t size) -{ - extern struct cfdriver pcibios_cd; - struct pcibios_softc *sc; - - sc = (struct pcibios_softc *)device_lookup(&pcibios_cd, 0); - if (sc && !(pcibios_flags & PCIBIOS_ADDR_FIXUP)) { - struct extent_region *rp; - struct extent *ex = mem_port? sc->extent_mem : sc->extent_port; - - /* Search the PCI I/O memory space extent for free - * space that will accommodate size. Remember that the - * extent stores allocated space and we're searching - * for the gaps. - * - * If we're at the end or the gap between this region - * and the next region big enough, then we're done - */ - for (rp = LIST_FIRST(&ex->ex_regions); - rp && *startp + size > rp->er_start; - rp = LIST_NEXT(rp, er_link)) { - bus_addr_t new_start; - - new_start = (rp->er_end - 1 + size) & ~(size - 1); - if (new_start > *startp) - *startp = new_start; - } - - return (ex); - } - - return (NULL); -} diff --git a/sys/arch/i386/pci/pcibiosvar.h b/sys/arch/i386/pci/pcibiosvar.h index ed7e0a69804..a03ed2c2aa9 100644 --- a/sys/arch/i386/pci/pcibiosvar.h +++ b/sys/arch/i386/pci/pcibiosvar.h @@ -1,4 +1,4 @@ -/* $OpenBSD: pcibiosvar.h,v 1.17 2007/03/19 05:32:05 deraadt Exp $ */ +/* $OpenBSD: pcibiosvar.h,v 1.18 2010/07/02 16:11:19 jsg Exp $ */ /* $NetBSD: pcibios.h,v 1.2 2000/04/28 17:15:16 uch Exp $ */ /* @@ -144,7 +144,6 @@ typedef const struct pciintr_icu *pciintr_icu_tag_t; #define PCIADDR_SEARCH_IO 0 #define PCIADDR_SEARCH_MEM 1 -struct extent *pciaddr_search(int, bus_addr_t *, bus_size_t); #define PCI_INT_VIA_ISA 0x20000000 /* XXX see APIC_INT_VIA_APIC */ |