cvs commit: src/sys/i386/pci pci_bus.c src/sys/i386/include legacyvar.h

John Baldwin jhb at FreeBSD.org
Fri Jun 6 11:06:41 PDT 2003


On 06-Jun-2003 John Baldwin wrote:
> jhb         2003/06/06 10:56:30 PDT
> 
>   FreeBSD src repository
> 
>   Modified files:
>     sys/i386/pci         pci_bus.c 
>     sys/i386/include     legacyvar.h 
>   Log:
>   - Rename nexus_pcib to legacy_pcib.  I've been meaning to do this for a
>     while after the legacy device was added since this driver hangs from
>     legacy and not nexus.
>   - Make several methods non-static so they can be reused in a mptable
>     host -> pci bridge driver that will be added at a later date.
>   - Let legacy_pcib() use pcibios_pcib_route_interrupt() directly instead of
>     wrapping it in a private function.  Originally, I thought I was going to
>     have the nexus_pcib() driver make a runtime APIC vs. 8259A check and call
>     the appropriate routing method (MPTable vs. PIR) that way, but it ended
>     up being cleaner to make nexus_pcib() just work with PIR and have a
>     separate host -> pci bridge driver for the mptable/apic case.

The eventual MPTable PCI bridge drivers are not pure theory but already
exist in the jhb_acpipci p4 branch.  There are several changes in that
branch to allow for one kernel that supports using both the 8259A's
and the I/O APIC and using a runtime decision as to how to which one to
use.  The upshot is that we will be able to stick SMP in GENERIC on i386
and that UP machines with an MP table or ACPI MADT table will be able to
use the I/O APIC to handle interrupts.  I hope to have it all in the tree
in time for 5.2.  For a bit of a preview:

Copyright (c) 1992-2003 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
        The Regents of the University of California. All rights reserved.
FreeBSD 5.1-CURRENT #48: Thu Jun  5 17:08:15 EDT 2003
    jbaldwin at bsdboy.atl.weather.com:/usr/work/jbaldwin/p4/acpipci/i386/compile/B
LUE
Preloaded elf kernel "/boot/acpipci/kernel" at 0xc042d000.
Timecounter "i8254"  frequency 1193182 Hz
Timecounter "TSC"  frequency 2394168536 Hz
CPU: Intel(R) Pentium(R) 4 CPU 2.40GHz (2394.17-MHz 686-class CPU)
  Origin = "GenuineIntel"  Id = 0xf24  Stepping = 4
  Features=0x3febfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,C
MOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM>
real memory  = 1072889856 (1023 MB)
avail memory = 1037742080 (989 MB)
MP Configuration Table version 1.4 found at 0xc00fc440
lapic_init: local apic addr = 0xfee00000, truc_page() = 0xfee00000
ioapic1: Assuming intbase of 0
ioapic1: Routing external 8259A's -> intpin 0
ioapic1: intpin 2 -> irq 0
APIC: Using the MPTable enumerator.
...
pcib0: <MPTable Host-PCI bridge> at pcibus 0 on motherboard
pci0: <PCI bus> on pcib0
pcib0: slot 29 INTA routed to irq 16
pcib0: slot 29 INTB routed to irq 19
pcib0: slot 29 INTC routed to irq 18
pcib0: slot 29 INTA routed to irq 16
pcib0: slot 29 INTD routed to irq 23
pcib0: slot 31 INTA routed to irq 18
pcib0: slot 31 INTB routed to irq 17
pcib0: slot 31 INTB routed to irq 17
agp0: <Intel 82865 host to AGP bridge> mem 0xf4000000-0xf7ffffff at device 0.0 o
n pci0
pcib1: <MPTable PCI-PCI bridge> at device 1.0 on pci0
pci1: <PCI bus> on pcib1
pcib1: slot 0 INTA routed to irq 16
pci1: <display, VGA> at device 0.0 (no driver attached)
uhci0: <Intel 82801EB (ICH5) USB controller USB-A> port 0xcc00-0xcc1f irq 16 at 
device 29.0 on pci0
usb0: <Intel 82801EB (ICH5) USB controller USB-A> on uhci0
usb0: USB revision 1.0
uhub0: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub0: 2 ports with 2 removable, self powered
uhci1: <Intel 82801EB (ICH5) USB controller USB-B> port 0xd000-0xd01f irq 19 at 
device 29.1 on pci0
usb1: <Intel 82801EB (ICH5) USB controller USB-B> on uhci1
usb1: USB revision 1.0
...
etc.

You can see the mptable and dmesg output at http://www.FreeBSD.org/~jhb/apic/

-- 

John Baldwin <jhb at FreeBSD.org>  <><  http://www.FreeBSD.org/~jhb/
"Power Users Use the Power to Serve!"  -  http://www.FreeBSD.org/


More information about the cvs-src mailing list