Subject: Re: How to enable a PCI device on macppc?
To: Allen Briggs <briggs@netbsd.org>
From: Rui DeSousa <rui@crazybean.net>
List: tech-kern
Date: 10/06/2005 10:13:02
Allen Briggs wrote:

>That sounds like OpenFirmware isn't configuring the device at all,
>so we'll have to do it.  Which macppc system do you have?
>
>-allen
>
>  
>
I'm running NetBSD 2.0.2 on a PowerMac Dual G4 500 MHz Gigabit Ethernet 
system.

Here's the dmesg output (the on-board Gigabit Ethernet no longer works 
and I'm using some Intel network cards instead):

NetBSD 2.0.2 (GENERIC.MP) #0: Tue Mar 22 16:21:50 UTC 2005
        
jmc@faith.netbsd.org:/home/builds/ab/netbsd-2-0-2-RELEASE/macppc/200503220140Z-obj/home/builds/ab/netbsd-2-0-2-RELEASE/src/sys/arch/macppc/compile/GENERIC.MP
total memory = 1152 MB
avail memory = 1098 MB
mainbus0 (root)
cpu0 at mainbus0: 7400 (Revision 2.9), ID 0 (primary)
cpu0: HID0 8094c0a4<EMCP,DOZE,DPM,EIEC,ICE,DCE,SGE,BTIC,BHT>
cpu0: 500.00 MHz, no-parity 1MB WB L2 cache (PB SRAM) at 2:1 ratio
cpu1 at mainbus0: 7400 (Revision 2.9), ID 1
cpu1: HID0 8094c0a4<EMCP,DOZE,DPM,EIEC,ICE,DCE,SGE,BTIC,BHT>
cpu1: 500.00 MHz, no-parity 1MB WB L2 cache (PB SRAM) at 2:1 ratio
uninorth0 at mainbus0
pci0 at uninorth0 bus 0
pci0: i/o space, memory space enabled
pchb0 at pci0 dev 11 function 0
pchb0: Apple Computer UniNorth AGP Interface (rev. 0x00)
ofb0 at pci0 dev 16 function 0: ATI Technologies product 0x4966
ofb0: 640 x 480, 8bpp
wsdisplay0 at ofb0 kbdmux 1: console (std, vt100 emulation)
wsmux1: connecting to wsdisplay0
uninorth1 at mainbus0
pci1 at uninorth1 bus 0
pci1: i/o space, memory space enabled
pchb1 at pci1 dev 11 function 0
pchb1: Apple Computer UniNorth Host-PCI Bridge (rev. 0x00)
ppb0 at pci1 dev 13 function 0: Digital Equipment DECchip 21154 PCI-PCI 
Bridge (rev. 0x05)
pci2 at ppb0 bus 1
pci2: i/o space, memory space enabled
ex0 at pci2 dev 2 function 0: 3Com 3c905C-TX 10/100 Ethernet with mngmt 
(rev. 0x6c)
ex0: interrupting at irq 52
ex0: MAC address 00:50:da:5d:10:f8
bmtphy0 at ex0 phy 24: Broadcom 3c905C internal PHY, rev. 4
bmtphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto
artsata0 at pci2 dev 3 function 0
artsata0: Intel 31244 Serial ATA Controller (rev. 0x00)
artsata0: device disabled (at device)
wm0 at pci2 dev 4 function 0: Intel i82540EM 1000BASE-T Ethernet, rev. 2
wm0: interrupting at irq 54
wm0: 32-bit 33MHz PCI bus
wm0: 64 word (6 address bits) MicroWire EEPROM
wm0: Ethernet address 00:07:e9:08:df:39
makphy0 at wm0 phy 1: Marvell 88E1011 Gigabit PHY, rev. 3
makphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT, 
1000baseT-FDX, auto
obio0 at pci2 dev 7 function 0: addr 0x80000000
zsc0 at obio0 offset 0x13000: irq 22,50
zstty0 at zsc0 channel 0
zstty1 at zsc0 channel 1
davbus at obio0 offset 0x14000 not configured
adb0 at obio0 offset 0x16000 irq 47: pm_adb_op: timeout. command = 0x0
0 targets
aed0 at adb0 addr 0: ADB Event device
apm0 at adb0: battery flags 0x9, 0% charged
wdc0 at obio0 offset 0x1f000 irq 19: DMA transfer
atabus0 at wdc0 channel 0
wdc1 at obio0 offset 0x20000 irq 20: DMA transfer
atabus1 at wdc1 channel 0
wdc2 at obio0 offset 0x21000 irq 21: DMA transfer
atabus2 at wdc2 channel 0
ohci0 at pci2 dev 8 function 0: Apple Computer KeyLargo USB Controller 
(rev. 0x00)
ohci0: interrupting at irq 27
ohci0: OHCI version 1.0
usb0 at ohci0: USB revision 1.0
uhub0 at usb0
uhub0: Apple Computer OHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub0: 2 ports with 2 removable, self powered
ohci1 at pci2 dev 9 function 0: Apple Computer KeyLargo USB Controller 
(rev. 0x00)
ohci1: interrupting at irq 28
ohci1: OHCI version 1.0
usb1 at ohci1: USB revision 1.0
uhub1 at usb1
uhub1: Apple Computer OHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub1: 2 ports with 2 removable, self powered
fwohci0 at pci2 dev 10 function 0: Texas Instruments TSB12LV23 OHCI IEEE 
1394 Host Controller (rev. 0x00)
fwohci0: interrupting at irq 63
fwohci0: OHCI 1.0, 00:30:65:ff:fe:d5:4c:bc, 400Mb/s, 2048 max_rec, 4 
ir_ctx, 8 it_ctx
uninorth2 at mainbus0
pci3 at uninorth2 bus 0
pci3: i/o space, memory space enabled
pchb2 at pci3 dev 11 function 0
pchb2: Apple Computer UniNorth Host-PCI Bridge (rev. 0x00)
gem0 at pci3 dev 15 function 0: Apple Computer GMAC Ethernet (rev. 0x01)
gem0: interrupting at irq 41
gem0: Ethernet address 00:30:65:d5:4c:bc, 10KB RX fifo, 4KB TX fifo
brgphy0 at gem0 phy 0: BCM5400 1000BASE-T media interface, rev. 7
brgphy0: using BCM5401 DSP patch
brgphy0: 100baseTX, 100baseTX-FDX, 1000baseT, 1000baseT-FDX, auto
fw0 at fwohci0: 00:30:65:ff:fe:d5:4c:bc:0a:02:ff:ff:f0:01:00:00
wd0 at atabus0 drive 0: <ST3120026A>
wd0: drive supports 16-sector PIO transfers, LBA48 addressing
wd0: 111 GB, 232581 cyl, 16 head, 63 sec, 512 bytes/sect x 234441648 sectors
wd0: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 5 (Ultra/100)
wd1 at atabus0 drive 1: <IC35L120AVV207-1>
wd1: drive supports 16-sector PIO transfers, LBA48 addressing
wd1: 115 GB, 239340 cyl, 16 head, 63 sec, 512 bytes/sect x 241254720 sectors
wd1: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 5 (Ultra/100)
wd0(wdc0:0:0): using PIO mode 4, DMA mode 2, Ultra-DMA mode 4 (Ultra/66) 
(using DMA data transfers)
wd1(wdc0:0:1): using PIO mode 4, DMA mode 2, Ultra-DMA mode 4 (Ultra/66) 
(using DMA data transfers)
atapibus0 at atabus1: 2 targets
cd0 at atapibus0 drive 0: <HITACHI DVD-ROM GD-7000, , 016J> cdrom removable
cd0: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 2 (Ultra/33)
wd2 at atabus1 drive 1: <IC35L120AVV207-1>
wd2: drive supports 16-sector PIO transfers, LBA48 addressing
wd2: 115 GB, 239340 cyl, 16 head, 63 sec, 512 bytes/sect x 241254720 sectors
wd2: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 5 (Ultra/100)
cd0(wdc1:0:0): using PIO mode 4, DMA mode 2 (using DMA data transfers)
wd2(wdc1:0:1): using PIO mode 4, DMA mode 2 (using DMA data transfers)
uhub2 at uhub1 port 1
uhub2: Mitsumi Electric Hub in Apple Extended USB Keyboard, class 9/0, 
rev 1.10/1.22, addr 2
uhub2: 3 ports with 2 removable, bus powered
uhidev0 at uhub2 port 1 configuration 1 interface 0
uhidev0: Mitsumi Electric Apple Extended USB Keyboard, rev 1.10/1.22, 
addr 3, iclass 3/1
ukbd0 at uhidev0: 8 modifier keys, 6 key codes
wskbd1 at ukbd0 mux 1
wskbd1: connecting to wsdisplay0
uhidev1 at uhub2 port 1 configuration 1 interface 1
uhidev1: Mitsumi Electric Apple Extended USB Keyboard, rev 1.10/1.22, 
addr 3, iclass 3/0
uhidev1: 3 report ids
uhid0 at uhidev1 reportid 2: input=1, output=0, feature=0
uhid1 at uhidev1 reportid 3: input=3, output=0, feature=0
uhidev2 at uhub2 port 2 configuration 1 interface 0
uhidev2: Logitech Apple Optical USB Mouse, rev 2.00/3.40, addr 4, iclass 3/1
ums0 at uhidev2: 1 button
wsmouse1 at ums0 mux 0
boot device: wd0
root on wd0a dumps on wd0b
root file system type: ffs
cpu1: started