看板 FB_current 關於我們 聯絡資訊
This patch adds a new API (pcib_host_res_*) that Host-PCI bridge drivers = can=20 use to restrict allocations for child devices to a known subset of = address=20 ranges that the bridge decodes. Originally I tried to allocate the full=20= ranges and use rmans just as we now do for PCI-PCI bridge windows. = However,=20 this broke due to the fact that all of our ACPI LPC/ISA devices attach = at the=20 "wrong" place in the tree (they aren't behind the host-PCI bridges) and = a=20 typical ACPI BIOS will allocate the full I/O port range to the host-PCI=20= bridge. We could perhaps fix this later if we relocate all the ACPI = devices=20 that are actually ISA devices down onto an ACPI-aware ISA bus (i.e. an = ISA bus=20 that uses ACPI to enumerate devices). Anyway, I punted on that for now. = =20 Instead, the current API works by using a resource_list to keep track of = all=20 the valid address ranges. When an allocation request is made, it simply = tries=20 all the address ranges in turn. I still made it honor = hw.pci.host_mem_start=20 since the ACPI BIOSes I have seen will optionally include option ROM = space=20 below 1MB if any ROMs are active, but we don't want to allocate that = space for=20 a wildcard BAR operation. I've changed the ACPI and MPTable Host-PCI bridge drivers to use this = helper=20 API. For ACPI we claim that bridges decode any "producer" address = ranges in=20 the bridges _CRS. For the MPTable I had to add logic to walk the = extended=20 MPTable entries and use those extended entries to find the list of = decoded=20 ranges. I'd like to get this into 9.0 and would appreciate folks = testing it out. http://www.FreeBSD.org/~jhb/patches/pci_host_res.patch --=20 John Baldwin _______________________________________________ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org"