這或許是一個很弱智的問題,但是確實折磨了我好多天才搞定。廢話就不多說了,下面就把我遇到的問題共享出來。
HP6515b筆記本的lspci輸出:
30:00.0 Network controller: Broadcom Corporation BCM94311MCG wlan mini-PCI (rev 02)
lspci -vn的輸出:
30:00.0 0280: 14e4:4311 (rev 02)
Subsystem: 103c:1375
Flags: bus master, fast devsel, latency 0, IRQ 18
Memory at c8000000 (64-bit, non-prefetchable) [size=16K]
Capabilities: [40] Power Management version 3
Capabilities: [58] Vendor Specific Information
Capabilities: [e8] Message Signalled Interrupts: Mask- 64bit+ Queue=0/0 Enable-
Capabilities: [d0] Express Endpoint IRQ 0
/usr/share/hwdata/pci.ids也能正確查找到。
但是問題就出現在這裡了,Fedora 8默認的竟然加載的是ssb.ko,這就是十分令人費解的事情的了。
dmesg的輸出:
ssb: rev 60000000
WARNING: at drivers/ssb/main.c:890 ssb_tmslow_reject_bitmask() (Not tainted)
Call Trace:
[<ffffffff880e2870>] :ssb:ssb_tmslow_reject_bitmask+0x76/0x7f
[<ffffffff880e303e>] :ssb:ssb_device_is_enabled+0xf/0x39
[<ffffffff880e5192>] :ssb:ssb_pcicore_init+0x19/0x4a
[<ffffffff880e25d6>] :ssb:ssb_attach_queued_buses+0x7d/0x25c
[<ffffffff880e3cb4>] :ssb:ssb_pci_get_invariants+0x0/0x2b7
[<ffffffff880e2bca>] :ssb:ssb_bus_register+0x131/0x183
[<ffffffff880e2ccc>] :ssb:ssb_bus_pcibus_register+0x2a/0x4b
[<ffffffff880e4575>] :ssb:ssb_pcihost_probe+0x6f/0x9e
[<ffffffff8112da13>] pci_device_probe+0xd0/0x137
[<ffffffff811963e2>] driver_probe_device+0xff/0x17c
[<ffffffff811965a7>] __driver_attach+0x90/0xcc
[<ffffffff81196517>] __driver_attach+0x0/0xcc
[<ffffffff81196517>] __driver_attach+0x0/0xcc
[<ffffffff81195786>] bus_for_each_dev+0x43/0x6e
[<ffffffff81195afe>] bus_add_driver+0x7b/0x19d
Nov 26 19: [<ffffffff8112dbde>] __pci_register_driver+0x58/0x8a
[<ffffffff880ca045>] :ssb:ssb_modinit+0x45/0x5d
[<ffffffff81056e25>] sys_init_module+0x15d5/0x173a
[<ffffffff8100bbce>] system_call+0x7e/0x83
ssb: Sonics Silicon Backplane found on PCI device 0000:30:00.0
ssb.ko占用了14e4:4311!而它又占著茅坑不拉屎。
我們知道遇到bcmwl5這樣的驅動,在linux下用ndiswrapper是很好使的(關於ndiswrapper詳見官方網站http://ndiswrapper.sourceforge.net)
先說說這個ssb是個什麼東西吧。Sonics Silicon Backplane這是在內核中自帶的,截圖為證:
that can be used by ssb based device drivers auch as bcm43xx and b44.
有心人知道,bcm無線網卡在linuxwiress.sourcdforge.net上是需要用到bcm43xx或b44模塊,甚至還會用到一個bcmxxbuffer的程序。但是在這款BCM94311MCG wlan mini-PCI (rev 02)就有很多bug,而且也不會驅動起來。fedora 8默認會去用此來試圖驅動網卡,畢竟沒人願意接近夠日的微軟,不過話說回來,你hp提供了windows下的程序,或是brandcom不提供linux下的驅動,我們就只能靠ndiswrapper了。
好了,毛病找到了,怎麼辦了呢?重新編譯內核?太費時了。重做initrd是個不錯的主義。下面是我的步驟:
#rm /lib/module/`uname -r`/kernel/driver/ssb -rf
#depmod -a
#mv /boot/`uname -r`-img /boot/xx.bak
#mkinitrd /boot/xxx.img `uname -r`
#ndiswrapper -m
#reboot
在開機時執行下面的腳本:
#!/bin/sh
OK=`sudo mii-tool eth0|awk '{print $3}' -`
echo "有線網卡的狀態是$OK"
if [ -z "$OK" -o "$OK" != "ok" ];then
sudo iwconfig wlan0 essid "xxxxxxx" key s:xxxxxx
sudo dhclient &&echo "wireless already,now you ...."
fi
exit 0;
that's all.