Port-powerpc archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: ibm4xx pci (Re: IBM405GP/GPr OPB bus_space endian (powerpc/ibm4xx/dev/opb.c))
On Wed, May 10, 2006 at 11:17:29PM +0900, Shigeyuki Fukushima wrote:
> I see. Then, is i386-port a special case? I think so. ok?
Yes. I think so, too.
> By the way, in pci-bus implementation (sys/dev/pci/pci.c), there is
> pci_attach_hook() function-call.
> This must be implemented at machine-dependent parts.
Yes. I think the current structure under ibm4xx needs to change.
I don't know if it needs to change for the 405GPr, but it will
need to change for some other.
The pci_attach_hook() is meant for pci busses--if you need to
do anything to configure a PCI bus before it is attached.
> In an ibm4xx case, this function is located at
> ibm4xx/dev/pci/pci_machdep.c.
> When this function was called, pchb had been already attached.
That's OK. The pci_attach_hook() is called before each PCI bus is
attached. So imagine a system with a 405GPr that has a quad-port
ethernet controller in it and that quad-port ethernet controller
has a built-in PCI bridge. That might look something like:
pchb0 at plb0
pci0 at pchb0
ppb0 at pci0 dev 1
pci1 at ppb0
tlp0 at pci1 dev 0
tlp1 at pci1 dev 1
tlp2 at pci1 dev 2
tlp3 at pci1 dev 3
Unless I am mistaken, pci_attach_hook() will be called before
"pci0 at pchb0" and again before "pci1 at ppb0".
pci_attach_hook() may not need to do anything, though. That
is machine-dependent.
-allen
--
Use NetBSD! http://www.NetBSD.org/
Home |
Main Index |
Thread Index |
Old Index