Subject: Re: kern/30592: wi(4) doesn't work
To: None <kern-bug-people@netbsd.org, gnats-admin@netbsd.org,>
From: YAMAMOTO Takashi <yamt@mwd.biglobe.ne.jp>
List: netbsd-bugs
Date: 06/26/2005 17:20:24
> >Number: 30592
> >Category: kern
> >Synopsis: wi(4) doesn't work
wi.c rev.1.199 seems to work except the following problems.
1. (the first attempt of?) "ifconfig wi0 -nwkey" takes longer than before
and causes the following messages.
wi0: timeout in wi_seek to fc2a/0
wi0: timeout in wi_seek to fc28/0
wi0: timeout in wi_seek to fc2a/0
wi0: timeout in wi_seek to fc28/0
wi0: timeout in wi_seek to fc2a/0
wi0: timeout in wi_seek to fc28/0
wi0: timeout in wi_seek to fc2a/0
wi0: timeout in wi_seek to fc28/0
wi0: timeout in wi_seek to fc2a/0
wi0: timeout in wi_seek to fc28/0
2. "ifconfig wi0 up" causes the following unless i do
"ifconfig wi0 -nwkey" beforehand.
ic->ic_def_txkey is IEEE80211_KEYIX_NONE (== 0xffff) at that point.
uvm_fault(0xc0834140, 0xc1532000, 0, 1) -> 0xe
wi_write_wep(c1172000,fc85,cc2369b6,2,0,1000,4) at netbsd:wi_write_wep+0x158
wi_init(c1172038,0,11f2e,3,0,cc236aa8,c03897aa) at netbsd:wi_init+0x59b
ether_ioctl(c1172038,8020690c,c12bc500,0,c0dc8bf4,c0e93c00,bfefeff8) at netbsd:ether_ioctl+0x67
ieee80211_ioctl(c117223c,8020690c,c12bc500,0,7,0,cc236b5c) at netbsd:ieee80211_ioctl+0x7b
wi_ioctl(c1172038,8020690c,c12bc500,0,7,1,0) at netbsd:wi_ioctl+0x93
in6_ifinit(c1172038,c12bc500,cc236d24,1,1,2bb,0) at netbsd:in6_ifinit+0x14a
in6_update_ifa(c1172038,cc236d14,0,0,0,0,0) at netbsd:in6_update_ifa+0x1b8
in6_ifattach_linklocal(c1172038,0,42bd78be,308e9,42bd78be,308e9,3) at netbsd:in6_ifattach_linklocal+0xb7
in6_ifattach(c1172038,0,c084b2a0,ca816498,80206910,0,cc236e6c) at netbsd:in6_ifattach+0xbc
in6_if_up(c1172038,cb412986,1,c02fdd69,c0f9afe0,c0f69c64,cc236e3c) at netbsd:in6_if_up+0x12
ifioctl(c0f69bd0,80206910,cc236ea4,cb412800,0,cc236ea4,80206910) at netbsd:ifioctl+0x3a9
sys_ioctl(ca80bc60,cc236f64,cc236f5c,0,cc236fa4,1384f000,0) at netbsd:sys_ioctl+0x122
syscall_plain() at netbsd:syscall_plain+0x7e
--- syscall (number 54) ---
0xbdbba4f3:
(gdb) l *(wi_write_wep+0x158)
0xc01bb720 is in wi_write_wep (/home/takashi/nbsd/sys/dev/ic/wi.c:2577).
2572 * It seems that the firmware accept 104bit key only if
2573 * all the keys have 104bit length. We get the length of
2574 * the transmit key and use it for all other keys.
2575 * Perhaps we should use software WEP for such situation.
2576 */
2577 keylen = ic->ic_nw_keys[ic->ic_def_txkey].wk_keylen;
2578 if (keylen > IEEE80211_WEP_KEYLEN)
2579 keylen = 13; /* 104bit keys */
2580 else
2581 keylen = IEEE80211_WEP_KEYLEN;
(gdb)