Subject: iwi driver crashes Intrinsyc 405EP with Intel PRO Wireless 2200BG
To: None <tech-net@netbsd.org>
From: Jim Higgins <jhiggins@alektrona.com>
List: tech-net
Date: 12/10/2006 20:41:22
Hi,
I am running a snapshot of NetBSD-current from last week. The Intel
2200BG card is recognized during auto-configuration and at a shell
prompt 'ifconfig -a' correctly displays the iwi0 interface. However,
'ifconfig iwi0 up', causes the iwi driver to successfully load the iwi
firmware and then immediately crash the system without a panic.
If I enable the maximum amount of iwi debug AND add additional debug
output in the iwi interrupt handler then the card will 'work' for
several minutes spewing debug output (channel scanning), but it too
ultimately crashes without a panic.
There have been changes to make iwi work on big endian architectures,
and those changes seem to work (the MAC address is reported correctly
and the firmware actually loads as compared to earlier versions).
NetBSD 4.0 Beta 2 exhibits the same crash. This particular 2200BG card
works well in a NetBSD/x86 system. Some small tweaks to the
OPENBLOCKS266 kernel were made to bring up the Intrinsyc 405EP SBC.
Any suggestions?
Cheers,
Jim Higgins
PPCBoot 2.0.0 (Dec 9 2006 - 21:40:52)
CPU: IBM PowerPC 405EP? (PVR=51210950) at 266.333 MHz (PLB=133,
OPB=66, EBC=44 MHz)
16 kB I-Cache 16 kB D-Cache
**************************************************
** PowerPC Boot 2.0.0 - 1.0 JIM **
** Copyright 2002,2003 Intrinsyc Software Inc. **
** Version: 1.0-RELEASE **
** Support: http://support.intrinsyc.com **
**************************************************
AMD NOR and NAND flash supported
Board: Intrinsyc IceCube
VCO: 799 MHz
PLLA:266 MHz
CPU: 266 MHz
PLB: 133 MHz
OPB: 66 MHz
EPB: 44 MHz
PCI: 33 MHz
I2C: ready
DRAM: 32 MB
=> tftp
ENET Speed is 100 Mbps - FULL duplex connection
ARP broadcast 1
TFTP from server 192.168.1.103; our IP address is 192.168.1.232
Filename 'boot3.img'.
Load address: 0x1c00000
Loading: *######
done
Bytes transferred = 28704 (7020 hex)
=> tftp 800000 nob1
ENET Speed is 100 Mbps - FULL duplex connection
ARP broadcast 1
TFTP from server 192.168.1.103; our IP address is 192.168.1.232
Filename 'nob1'.
Load address: 0x800000
Loading: *#####...
done
Bytes transferred = 3829520 (3a6f10 hex)
=> bootm 1c00000
## Booting image at 01c00000 ...
Image Name: 2nd stage
Image Type: PowerPC NetBSD Kernel Image (uncompressed)
Data Size: 28640 Bytes = 27.10 kB
Load Address: 01c00000
Entry Point: 01c00040
Verifying Checksum ... OK
XIP Kernel Image ... OK
## Transferring control to NetBSD stage-2 loader (at address 01c00040) ...?
>> NetBSD/powerpc PPCBoot stage-2 loader, Revision 1.1
>> (jhiggins@bemused.alektrona.com, Wed Nov 15 03:41:35 EST 2006)
3450772+261256 [157568+152724]=0x3d63fc
## Transferring control to NetBSD (at address 0x25000) ...
+2000000,
00025000-02000000 -> 003bc000-02000000 = 1c44000
Board config data:
usr_config_ver = 1234ROM_SW_VER
rom_sw_ver = ROM_SW_VER
mem_size = 33554432
mac_address_local = 00:01:02:03:05:06
mac_address_pci = 06:07:08:09:0a:0b
processor_speed = 266666666
plb_speed = 133333333
pci_speed = 33333333
Loaded initial symtab at 0x307068, strtab at 0x32dcd4, # entries 9829
Copyright (c) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
2005, 2006
The NetBSD Foundation, Inc. All rights reserved.
Copyright (c) 1982, 1986, 1989, 1991, 1993
The Regents of the University of California. All rights reserved.
NetBSD 4.99.4 (OPENBLOCKS266) #52: Sun Dec 10 05:56:56 EST 2006
jhiggins@bemused.alektrona.com:/alk/ppc5/usr/src/sys/arch/evbppc/compile/OPENBLOCKS266
Model: OpenBlockS266 IBM PowerPC 405GPr Board
total memory = 32768 KB
avail memory = 28624 KB
plb0 (root)
cpu0 at plb0: 266MHz 405EP (PVR 0x51210950)
cpu0: Instruction cache size 16384 line size 32
cpu0: Data cache size 16384 line size 32
ecc0 at plb0 irq 16: ECC controller
opb0 at plb0
com0 at opb0 addr 0xef600300 irq 0: ns16550a, working fifo
com0: console
com1 at opb0 addr 0xef600400 irq 1: ns16550a, working fifo
emac0 at opb0 addr 0xef600800 irq 9: 405GP EMAC
emac0: interrupting at irqs 9 .. 15
emac0: Ethernet address 00:01:02:03:05:06
OUI 0x1000e8 model 0x0003 rev 0 at emac0 phy 1 not configured
OUI 0x1000e8 model 0x0003 rev 0 at emac0 phy 2 not configured
opbgpio0 at opb0 addr 0xef600700: On-Chip GPIO controller
gpio0 at opbgpio0: 24 pins
gpiic0 at opb0 addr 0xef600500 irq 2: On-Chip IIC controller
iic0 at gpiic0: I2C bus
xrtc0 at iic0 addr 0x6f: Xicor X1226 Real-time Clock/NVRAM
wdog0 at opb0: 4 second period
pchb0 at plb0
pchb0: IBM PPC 405GP PCI Bridge (rev. 0x00)
Local -> PCI map
0: 80000000,f0000001 -> 0000000080000000 not prefetchable, enabled
1: 00000000,00000000 -> 0000000000000000 not prefetchable, disabled
2: 00000000,00000000 -> 0000000000000000 not prefetchable, disabled
PCI -> Local map
1: 00000008 -> 00000000,f0000001 enabled
2: 00000000 -> 00000000,00000000 disabled
PCI: bus 0, device 0, function 0: id=1561014: Vendor=1014, Product=156
PCI: bus 0, device 0, function 0: Found dev 0x1014 0x0156 -- really probing.
PCI: bus 0, device 1, function 0: id=42208086: Vendor=8086, Product=4220
PCI: bus 0, device 1, function 0: Found dev 0x8086 0x4220 -- really probing.
PCI: bus 0, device 1, function 0: MEM32 BAR 0x10 has size 1000
PCI: bus 0, device 1, function 0: Register 0x10, memory size 4096
PCI: bus 0, device 1, function 0: MEM32 BAR 0x14 is void
PCI: bus 0, device 1, function 0: MEM32 BAR 0x18 is void
PCI: bus 0, device 1, function 0: MEM32 BAR 0x1c is void
PCI: bus 0, device 1, function 0: MEM32 BAR 0x20 is void
PCI: bus 0, device 1, function 0: MEM32 BAR 0x24 is void
PCI: bus 0, device 2, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 3, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 4, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 5, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 6, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 7, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 8, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 9, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 10, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 11, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 12, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 13, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 14, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 15, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 16, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 17, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 18, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 19, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 20, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 21, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 22, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 23, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 24, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 25, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 26, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 27, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 28, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 29, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 30, function 0: id=ffffffff: Vendor=ffff, Product=ffff
PCI: bus 0, device 1, function 0: Putting 4096 MEM bytes @ 0x80000000
(reg 10)
PCI: bus 0, device 1, function 0: Configuring device.
PCI bus 0 configured
running config_found PCI
pci0 at pchb0pci_attach_hook
Local -> PCI map
0: 80000000,f0000001 -> 0000000080000000 not prefetchable, enabled
1: 00000000,00000000 -> 0000000000000000 not prefetchable, disabled
2: 00000000,00000000 -> 0000000000000000 not prefetchable, disabled
PCI -> Local map
1: 00000008 -> 00000000,f0000001 enabled
2: 00000000 -> 00000000,00000000 disabled
Local -> PCI map
0: 80000000,f0000001 -> 0000000080000000 not prefetchable, enabled
1: 00000000,00000000 -> 0000000000000000 not prefetchable, disabled
2: 00000000,00000000 -> 0000000000000000 not prefetchable, disabled
PCI -> Local map
1: 00000008 -> 00000000,f0000001 enabled
2: 00000000 -> 00000000,00000000 disabled
pci0: i/o space, memory space enabled
IBM PPC 405GP PCI Bridge (host bridge) at pci0 dev 0 function 0 not
configured
iwi0 at pci0 dev 1 function 0: Intel PRO/Wireless LAN 2200BG Mini-PCI
Adapter (rev. 0x05)
iwi0: interrupting at irq 25
iwi0: 802.11 address 00:12:f0:5d:39:b6
iwi0: NIC type 0
iwi0: 11b rates: 1Mbps 2Mbps 5.5Mbps 11Mbps
iwi0: 11g rates: 1Mbps 2Mbps 5.5Mbps 11Mbps 6Mbps 9Mbps 12Mbps 18Mbps
24Mbps 36Mbps 48Mbps 54Mbps
biomask 1c00 netmask 7f1c40 ttymask 7f1c40
Setting PIT to 266666666/100 = 2666666
root device: emac0
dump device: nfs
file system (default generic): nfs
root on emac0
nfs_boot: trying DHCP/BOOTP
nfs_boot: DHCP next-server: 192.168.1.103
nfs_boot: my_addr=192.168.1.232
nfs_boot: my_mask=255.255.255.0
root on 192.168.1.103:/alk/ppc5/usr/src/obj/destdir.evbppc
root time: 0x457d8f44
xrtc0: xrtc_clock_read: failed to read rtc at 0x0
xrtc0: xrtc_clock_read: failed to read rtc at 0x0
WARNING: preposterous TOD clock time
WARNING: using filesystem time
WARNING: CHECK AND RESET THE DATE!
init path (default /sbin/init):
init: copying out path `/sbin/init' 11
Mon Dec 11 17:03:01 UTC 2006
Checking for botched superblock upgrades: done.
Starting file system checks:
192.168.1.103:/alk/ppc5/usr/src/obj/destdir.evbppc: inaccurate wcc data
(ctime) detected, disabling wcc
Setting tty flags.
Setting sysctl variables:
Starting network.
Hostname: bsd.alektrona.com
IPv6 mode: host
Configuring network interfaces:.
add net default: gateway 192.168.1.1
Adding interface aliases:
Building databases...
Starting syslogd.
Checking for core dump...
savecore: no core dump (no dumpdev)
Mounting all filesystems...
Clearing /tmp.
Checking quotas: done.
Setting securelevel: kern.securelevel: 0 -> 1
swapctl: WARNING: /swap is readable by the world
swapctl: adding 192.168.1.103:/alk/ppc5/usr/src/obj/swap as swap device
at priority 0
Starting local daemons:.
Updating motd.
Starting cron.
Mon Dec 11 17:03:46 UTC 2006
NetBSD/evbppc (bsd.alektrona.com) (console)
login: root
Dec 11 17:03:54 bsd login: ROOT LOGIN (root) ON console
Last login: Mon Dec 11 17:01:13 2006 on console
Copyright (c) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
2005, 2006
The NetBSD Foundation, Inc. All rights reserved.
Copyright (c) 1982, 1986, 1989, 1991, 1993
The Regents of the University of California. All rights reserved.
NetBSD 4.99.4 (OPENBLOCKS266) #52: Sun Dec 10 05:56:56 EST 2006
Welcome to NetBSD!
This system is running a development snapshot of the NetBSD operating
system,
also known as NetBSD-current. It is highly possible for it to contain
serious
bugs, regressions, broken features or other problems. Please bear this
in mind
and use the system with care.
You are encouraged to test this version as thoroughly as possible.
Should you
encounter any problem, please report it back to the development team
using the
send-pr(1) utility (requires a working MTA). If yours is not properly
set up,
use the web interface at: http://www.NetBSD.org/Misc/send-pr.html
Thank you for helping us test and improve NetBSD.
Terminal type is vt100.
We recommend creating a non-root account and using su(1) for root access.
bsd# ifconfig -a
emac0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
address: 00:01:02:03:05:06
media: Ethernet none (none)
inet 192.168.1.232 netmask 0xffffff00 broadcast 192.168.1.255
inet6 fe80::201:2ff:fe03:506%emac0 prefixlen 64 scopeid 0x1
iwi0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> mtu 1500
ssid ""
powersave off
address: 00:12:f0:5d:39:b6
media: IEEE802.11 autoselect
status: no network
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 33192
inet 127.0.0.1 netmask 0xff000000
inet6 ::1 prefixlen 128
inet6 fe80::1%lo0 prefixlen 64 scopeid 0x3
bsd# pcictl /dev/pci0 list
000:00:0: IBM PPC 405GP PCI Bridge (host bridge)
000:01:0: Intel PRO/Wireless LAN 2200BG Mini-PCI Adapter (miscellaneous
network, revision 0x05)
bsd# pcictl /dev/pci0 dump -d 0
PCI configuration registers:
Common header:
0x00: 0x01561014 0x22100006 0x06000000 0x00000000
Vendor Name: IBM (0x1014)
Device Name: PPC 405GP PCI Bridge (0x0156)
Command register: 0x0006
I/O space accesses: off
Memory space accesses: on
Bus mastering: on
Special cycles: off
MWI transactions: off
Palette snooping: off
Parity error checking: off
Address/data stepping: off
System error (SERR): off
Fast back-to-back transactions: off
Interrupt disable: off
Status register: 0x2210
Capability List support: on
66 MHz capable: off
User Definable Features (UDF) support: off
Fast back-to-back capable: off
Data parity error detected: off
DEVSEL timing: medium (0x1)
Slave signaled Target Abort: off
Master received Target Abort: off
Master received Master Abort: on
Asserted System Error (SERR): off
Parity error detected: off
Class Name: bridge (0x06)
Subclass Name: host (0x00)
Interface: 0x00
Revision ID: 0x00
BIST: 0x00
Header Type: 0x00 (0x00)
Latency Timer: 0x00
Cache Line Size: 0x00
Type 0 ("normal" device) header:
0x10: 0x00000000 0x00000008 0x00000000 0x00000000
0x20: 0x00000000 0x00000000 0x00000000 0x00000000
0x30: 0x00000000 0x00000058 0x00000000 0x00000100
Base address register at 0x10
not implemented(?)
Base address register at 0x14
type: 32-bit prefetchable memory
base: 0x00000000, not sized
Base address register at 0x18
not implemented(?)
Base address register at 0x1c
not implemented(?)
Base address register at 0x20
not implemented(?)
Base address register at 0x24
not implemented(?)
Cardbus CIS Pointer: 0x00000000
Subsystem vendor ID: 0x0000
Subsystem ID: 0x0000
Expansion ROM Base Address: 0x00000000
Capability list pointer: 0x58
Reserved @ 0x38: 0x00000000
Maximum Latency: 0x00
Minimum Grant: 0x00
Interrupt pin: 0x01 (pin A)
Interrupt line: 0x00
Capability register at 0x58
type: 0x01 (Power Management, rev. 1.0)
Device-dependent header:
0x40: 0x00000000 0x00000000 0xff600000 0x00000000
0x50: 0x00000000 0x00000000 0x02020001 0x00000000
0x60: 0x00000101 0x00000010 0x00000000 0x00000000
0x70: 0x00000000 0x00000000 0x00000000 0x00000000
0x80: 0x00000000 0x00000000 0x00000000 0x00000000
0x90: 0x00000000 0x00000000 0x00000000 0x00000000
0xa0: 0x00000000 0x00000000 0x00000000 0x00000000
0xb0: 0x00000000 0x00000000 0x00000000 0x00000000
0xc0: 0x00000000 0x00000000 0x00000000 0x00000000
0xd0: 0x00000000 0x00000000 0x00000000 0x00000000
0xe0: 0x00000000 0x00000000 0x00000000 0x00000000
0xf0: 0x00000000 0x00000000 0x00000000 0x00000000
bsd# pcictl /dev/pci0 dump -d 1
PCI configuration registers:
Common header:
0x00: 0x42208086 0x02900146 0x02800005 0x0000c808
Vendor Name: Intel (0x8086)
Device Name: PRO/Wireless LAN 2200BG Mini-PCI Adapter (0x4220)
Command register: 0x0146
I/O space accesses: off
Memory space accesses: on
Bus mastering: on
Special cycles: off
MWI transactions: off
Palette snooping: off
Parity error checking: on
Address/data stepping: off
System error (SERR): on
Fast back-to-back transactions: off
Interrupt disable: off
Status register: 0x0290
Capability List support: on
66 MHz capable: off
User Definable Features (UDF) support: off
Fast back-to-back capable: on
Data parity error detected: off
DEVSEL timing: medium (0x1)
Slave signaled Target Abort: off
Master received Target Abort: off
Master received Master Abort: off
Asserted System Error (SERR): off
Parity error detected: off
Class Name: network (0x02)
Subclass Name: miscellaneous (0x80)
Interface: 0x00
Revision ID: 0x05
BIST: 0x00
Header Type: 0x00 (0x00)
Latency Timer: 0xc8
Cache Line Size: 0x08
Type 0 ("normal" device) header:
0x10: 0x80000000 0x00000000 0x00000000 0x00000000
0x20: 0x00000000 0x00000000 0x00000000 0x27018086
0x30: 0x00000000 0x000000dc 0x00000000 0x18030119
Base address register at 0x10
type: 32-bit nonprefetchable memory
base: 0x80000000, not sized
Base address register at 0x14
not implemented(?)
Base address register at 0x18
not implemented(?)
Base address register at 0x1c
not implemented(?)
Base address register at 0x20
not implemented(?)
Base address register at 0x24
not implemented(?)
Cardbus CIS Pointer: 0x00000000
Subsystem vendor ID: 0x8086
Subsystem ID: 0x2701
Expansion ROM Base Address: 0x00000000
Capability list pointer: 0xdc
Reserved @ 0x38: 0x00000000
Maximum Latency: 0x18
Minimum Grant: 0x03
Interrupt pin: 0x01 (pin A)
Interrupt line: 0x19
Capability register at 0xdc
type: 0x01 (Power Management, rev. 1.0)
Device-dependent header:
0x40: 0x00000080 0x00000000 0x00000000 0x00000000
0x50: 0x00000000 0x00000000 0x00000000 0x00000000
0x60: 0x00000000 0x00000000 0x00000000 0x00000000
0x70: 0x00000000 0x00000000 0x00000000 0x00000000
0x80: 0x00000000 0x00000000 0x00000000 0x00000000
0x90: 0x00000000 0x00000000 0x00000000 0x00000000
0xa0: 0x00000000 0x00000000 0x00000000 0x00000000
0xb0: 0x00000000 0x00000000 0x00000000 0x00000000
0xc0: 0x00000000 0x00000000 0x00000000 0x00000000
0xd0: 0x00000000 0x00000000 0x00000000 0xc8220001
0xe0: 0x13002000 0x00000000 0x00000000 0x00000000
0xf0: 0x00000000 0x00000000 0x00000000 0x00000000
bsd# ifconfig iwi0 up
Firmware cached: boot 6472, ucode 16334, main 166960
i2:1000000
i2:1000000
Setting MAC address to 00:12:f0:5d:39:b6
sending command idx=0 type=11 len=6
i2:800
Configuring adapter
sending command idx=1 type=6 len=20
i2:800
Setting power mode to 0
sending command idx=2 type=17 len=4
i2:800
Setting RTS threshold to 2346
sending command idx=3 type=15 len=4
i2:800
Setting fragmentation threshold to 2346
sending command idx=4 type=16 len=4
i2:800
Setting .11bg supported rates (12)
sending command idx=5 type=22 len=16
i2:800
Setting .11a supported rates (0)
sending command idx=6 type=22 len=16
i2:800
Setting initialization vector to 1731692252
sending command idx=7 type=34 len=4
i2:800
Setting wep key index 0 len 0
sending command idx=0 type=18 len=20
i2:800
Setting wep key index 1 len 0
sending command idx=1 type=18 len=20
i2:800
Setting wep key index 2 len 0
sending command idx=2 type=18 len=20
i2:800
Setting wep key index 3 len 0
sending command idx=3 type=18 len=20
i2:800
Enabling adapter
sending command idx=4 type=2 len=0
i2:800
Start scanning
sending command idx=5 type=26 len=96
i2:802
iwi_rx_intr: &hdr:0x1f6b800
Notification calibration(20)
rx done idx=0
bsd# [***resets after 1-2 seconds]
PPCBoot 2.0.0 (Dec 9 2006 - 21:40:52)
CPU: IBM PowerPC 405EP? (PVR=51210950) at 266.333 MHz (PLB=133,
OPB=66, EBC=44 MHz)
16 kB I-Cache 16 kB D-Cache
**************************************************
** PowerPC Boot 2.0.0 - 1.0 JIM **
** Copyright 2002,2003 Intrinsyc Software Inc. **
** Version: 1.0-RELEASE **
** Support: http://support.intrinsyc.com **
**************************************************
AMD NOR and NAND flash supported
Board: Intrinsyc IceCube
VCO: 799 MHz
PLLA:266 MHz
CPU: 266 MHz
PLB: 133 MHz
OPB: 66 MHz
EPB: 44 MHz
PCI: 33 MHz
I2C: ready
DRAM: 32 MB