Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 232043

Summary: sys-firmware/iwl3945-ucode-2.14.1.5 - doesn't work if iwl3945 module loaded with kill switch
Product: Gentoo Linux Reporter: Erik Boritsch <borych>
Component: [OLD] Core systemAssignee: No maintainer - Look at https://wiki.gentoo.org/wiki/Project:Proxy_Maintainers if you want to take care of it <maintainer-needed>
Status: RESOLVED WONTFIX    
Severity: normal CC: amigadave, andri, gabriel, giovannino.perdigiorno, mobile+disabled, pacho, roland, treecleaner
Priority: High Keywords: PMASKED
Version: 2008.0   
Hardware: AMD64   
OS: Linux   
Whiteboard: Pending Removal: 2013-07-15
Package list:
Runtime testing required: ---
Attachments: My Kernel .config File

Description Erik Boritsch 2008-07-17 04:19:41 UTC
If I load the iwl3945 module with the card turned off via the kill switch, and then disable kill switch - the card won't come up. Otherwise if works fine. Kill switch works fine too except for this case.
The card in question is (lspci snippet):
04:00.0 Network controller: Intel Corporation PRO/Wireless 3945ABG Network Connection (rev 02)

dmesg output upon insertion with killer switch engaged:
iwl3945: Intel(R) PRO/Wireless 3945ABG/BG Network Connection driver for Linux, 1.2.23k
iwl3945: Copyright(c) 2003-2007 Intel Corporation
ACPI: PCI Interrupt 0000:04:00.0[A] -> GSI 18 (level, low) -> IRQ 18
PCI: Setting latency timer of device 0000:04:00.0 to 64
iwl3945: Detected Intel PRO/Wireless 3945ABG Network Connection
iwl3945: Tunable channels: 13 802.11bg, 23 802.11a channels
phy3: Selected rate control algorithm 'iwl-3945-rs'
ACPI: PCI Interrupt 0000:04:00.0[A] -> GSI 18 (level, low) -> IRQ 18
iwl3945: Radio disabled by HW RF Kill switch
ACPI: PCI Interrupt 0000:04:00.0[A] -> GSI 18 (level, low) -> IRQ 18
iwl3945: Radio disabled by HW RF Kill switch
ACPI: PCI Interrupt 0000:04:00.0[A] -> GSI 18 (level, low) -> IRQ 18
iwl3945: Radio disabled by HW RF Kill switch
ACPI: PCI Interrupt 0000:04:00.0[A] -> GSI 18 (level, low) -> IRQ 18
iwl3945: Radio disabled by HW RF Kill switch

if I re-enable the card then - nothing happens. Neither wlan0 or wmaster0 interfaces even appear on ifconfig (iwconfig finds wlan0 though).

It there any way to change that behavior?
Comment 1 Erik Boritsch 2008-07-17 04:21:26 UTC
The kernel in question is sys-kernel/vanilla-sources-2.6.26 with net-wireless/iwl3945-ucode-2.14.1.5 on amd64 Gentoo. It has happened on 2.6.25 too.
Comment 2 Bartosz Krzeszewski 2008-10-20 09:50:44 UTC
I have the same problem. BTW what is this "RF Kill switch"?

uname -a
Linux ESPRIMO 2.6.25-gentoo-r7 #1 SMP PREEMPT Sat Oct 18 16:36:10 CEST 2008 x86_64 Intel(R) Core(TM)2 Duo CPU T5450 @ 1.66GHz GenuineIntel GNU/Linux
Comment 3 Bartosz Krzeszewski 2009-01-18 00:14:56 UTC
ESPRIMO ~ # /etc/init.d/net.wlan0 restart
 * Caching service dependencies ...                                                                                                                                                                                                   [ ok ]
 * Starting wlan0
SIOCSIFFLAGS: No such device
SIOCSIFFLAGS: No such device
SIOCSIFFLAGS: No such device
 *   Configuring wireless network for wlan0
 *   Failed to configure wireless for wlan0

dmesg:
...
iwl3945 0000:08:00.0: PCI INT A -> GSI 18 (level, low) -> IRQ 18
iwl3945 0000:08:00.0: restoring config space at offset 0x1 (was 0x100102, writing 0x100106)
iwl3945 0000:08:00.0: firmware: requesting iwlwifi-3945-1.ucode
iwl3945: Radio disabled by HW RF Kill switch
iwl3945 0000:08:00.0: PCI INT A disabled

uname -a
Linux ESPRIMO 2.6.28-gentoo #1 SMP PREEMPT Mon Dec 29 14:22:11 CET 2008 x86_64 Intel(R) Core(TM)2 Duo CPU T5450 @ 1.66GHz GenuineIntel GNU/Linux

Is anyone trying to solve this bug?
Comment 4 Gabriel Máculus 2009-01-18 04:43:42 UTC
(In reply to comment #3)
> ESPRIMO ~ # /etc/init.d/net.wlan0 restart
>  * Caching service dependencies ...                                            
>                                                                                
>                                                                       [ ok ]
>  * Starting wlan0
> SIOCSIFFLAGS: No such device
> SIOCSIFFLAGS: No such device
> SIOCSIFFLAGS: No such device
>  *   Configuring wireless network for wlan0
>  *   Failed to configure wireless for wlan0
> 
> dmesg:
> ...
> iwl3945 0000:08:00.0: PCI INT A -> GSI 18 (level, low) -> IRQ 18
> iwl3945 0000:08:00.0: restoring config space at offset 0x1 (was 0x100102,
> writing 0x100106)
> iwl3945 0000:08:00.0: firmware: requesting iwlwifi-3945-1.ucode
> iwl3945: Radio disabled by HW RF Kill switch
> iwl3945 0000:08:00.0: PCI INT A disabled
> 
> uname -a
> Linux ESPRIMO 2.6.28-gentoo #1 SMP PREEMPT Mon Dec 29 14:22:11 CET 2008 x86_64
> Intel(R) Core(TM)2 Duo CPU T5450 @ 1.66GHz GenuineIntel GNU/Linux
> 
> Is anyone trying to solve this bug?
> 
I have the same, and RF kill switch does not work anymore and Radio disabled by HW RF Kill switch.


Comment 5 Peter Volkov (RETIRED) gentoo-dev 2009-01-22 10:51:30 UTC
Please, try iwl3945-ucode-15.28.1.8.ebuild and then iwl3945-ucode-15.28.2.8.ebuild (in such order) and tell me if this bug is still reproducible there. Also please, try kernel 2.6.28 as it'll go stable soon.
Comment 6 Roland Baldenhofer 2009-01-25 21:03:29 UTC
Hi,

I emerged iwl3945-ucode-15.28.1.8.ebuild and then
iwl3945-ucode-15.28.2.8.ebuild. I also use the Kernel 2.6.28.
My Laptop is a Amilo Si 1520.
The dmesg output shows
iwl3945: Copyright(c) 2003-2008 Intel Corporation
iwl3945 0000:01:00.0: PCI INT A -> GSI 16 (level, low) -> IRQ 16
iwl3945 0000:01:00.0: setting latency timer to 64
iwl3945: Detected Intel Wireless WiFi Link 3945ABG
iwl3945: Tunable channels: 13 802.11bg, 23 802.11a channels
phy4: Selected rate control algorithm 'iwl-3945-rs'
iwl3945 0000:01:00.0: PCI INT A -> GSI 16 (level, low) -> IRQ 16
iwl3945 0000:01:00.0: irq 1275 for MSI/MSI-X
iwl3945 0000:01:00.0: firmware: requesting iwlwifi-3945-1.ucode
Registered led device: iwl-phy4:radio
Registered led device: iwl-phy4:assoc
Registered led device: iwl-phy4:RX
Registered led device: iwl-phy4:TX
iwl3945: MAC is in deep sleep!
iwl3945: MAC is in deep sleep!
iwl3945: MAC is in deep sleep!
iwl3945 0000:01:00.0: PCI INT A -> GSI 16 (level, low) -> IRQ 16
iwl3945 0000:01:00.0: irq 1275 for MSI/MSI-X
iwl3945: Radio disabled by SW RF kill (module parameter)

The card stops to work after a view seconds.
I hope this bug is related to this problem.

Cheers

Roland 
Comment 7 Peter Volkov (RETIRED) gentoo-dev 2009-01-26 06:46:22 UTC
(In reply to comment #6)
> iwl3945: Radio disabled by SW RF kill (module parameter)

Try to enable SW RF kill:
echo -n 0 > /sys/bus/pci/drivers/iwl3945/<dev id>/rfkill\:rfkill0/state
(sorry I don't have 3945 device at hand right now, so I could post wrong path, but please find how to enable and try to enable)

> The card stops to work after a view seconds.

How did it work? Have you any sites opened?

Also you driver loaded iwlwifi-3945-1.ucode. Try to emerge -C net-wireless/iwl3945-ucode:0 and keep only ucode with more recent API=2. What happens?
Comment 8 Roland Baldenhofer 2009-01-26 14:41:20 UTC
Hi Peter,

thanks for the quick reply!
I have no clue idea how to fix this problem.
What is the meaning of "MAC is in deep sleep!"?

I am not able to access any sites with the current configuration.

The echo -n 0 didn't help. It sets the state file to 0 but thats it. Nothing
happens.

When I emerge the iwlwifi-3945-2.ucode the following dmesg output results:
iwl3945: Intel(R) PRO/Wireless 3945ABG/BG Network Connection driver for Linux,
1.2.26kds
iwl3945: Copyright(c) 2003-2008 Intel Corporation
iwl3945 0000:01:00.0: PCI INT A -> GSI 16 (level, low) -> IRQ 16
iwl3945 0000:01:00.0: setting latency timer to 64
iwl3945: Detected Intel Wireless WiFi Link 3945ABG
iwl3945: Tunable channels: 13 802.11bg, 23 802.11a channels
phy3: Selected rate control algorithm 'iwl-3945-rs'
iwl3945 0000:01:00.0: PCI INT A -> GSI 16 (level, low) -> IRQ 16
iwl3945 0000:01:00.0: irq 1275 for MSI/MSI-X
iwl3945 0000:01:00.0: firmware: requesting iwlwifi-3945-1.ucode
iwl3945: iwlwifi-3945-1.ucode firmware file req failed: Reason -2
iwl3945: Could not read microcode: -2

I moved the iwlwifi-3945-2.ucode file in /lib/firmware to iwlwifi-3945-1.ucode
file. So the microcode will be found.

When I start with:
modprobe -r iwl3945
modprobe iwl3945
the wireless starts and the LED is on for about 7 seconds.
Then the wireless stops again.

During the seven seconds ifconfig shows this entries:

wlan0     Protokoll:Ethernet  Hardware Adresse 00:18:de:35:81:50
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          Kollisionen:0	Sendewarteschlangenlänge:100
	  RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
dmesg shows the following info:
iwl3945: Intel(R) PRO/Wireless 3945ABG/BG Network Connection driver for Linux,
1.2.26kds
iwl3945: Copyright(c) 2003-2008 Intel Corporation
iwl3945 0000:01:00.0: PCI INT A -> GSI 16 (level, low) -> IRQ 16
iwl3945 0000:01:00.0: setting latency timer to 64
iwl3945: Detected Intel Wireless WiFi Link 3945ABG
iwl3945: Tunable channels: 13 802.11bg, 23 802.11a channels
phy2: Selected rate control algorithm 'iwl-3945-rs'
iwl3945 0000:01:00.0: PCI INT A -> GSI 16 (level, low) -> IRQ 16
iwl3945 0000:01:00.0: irq 1275 for MSI/MSI-X
iwl3945 0000:01:00.0: firmware: requesting iwlwifi-3945-1.ucode
Registered led device: iwl-phy2:radio
Registered led device: iwl-phy2:assoc
Registered led device: iwl-phy2:RX
Registered led device: iwl-phy2:TX
phy2: HW CONFIG: freq=2412
ADDRCONF(NETDEV_UP): wlan0: link is not ready
phy2: HW CONFIG: freq=2412
phy2: HW CONFIG: freq=2412
phy2: HW CONFIG: freq=2412
iwl3945: MAC is in deep sleep!
iwl3945: MAC is in deep sleep!
iwl3945: MAC is in deep sleep!

With a Kernel version /usr/src/linux-2.6.25-gentoo-r2 it worked (more or less)
Since the upgrade I have no idea how to run the wireless.
I added my Kernel .config file. If you have any idea what I make wrong please let me know.

Greetings

Roland
Comment 9 Roland Baldenhofer 2009-01-26 14:43:34 UTC
Created attachment 179765 [details]
My Kernel .config File
Comment 10 Peter Volkov (RETIRED) gentoo-dev 2009-01-26 16:51:15 UTC
(In reply to comment #8
> The echo -n 0 didn't help. It sets the state file to 0 but thats it. Nothing
> happens.

Please, try configure your card manually. At what point the process stops?
ip link set wlan0 up
iwlist wlan0 scan
?

> When I emerge the iwlwifi-3945-2.ucode the following dmesg output results:

Sorry. I was wrong. 2.6.28 kernels use ucode with API=1. So you need net-wireless/iwl3945-ucode:0.

> I moved the iwlwifi-3945-2.ucode file in /lib/firmware to iwlwifi-3945-1.ucode
> file. 

Please, revert. This is not a solution.

> When I start with:
> modprobe -r iwl3945
> modprobe iwl3945

What happens with net-wireless/iwl3945-ucode:0?

I still don't get what and how is broken... So back to initial questions:

> The card stops to work after a view seconds.

How did it work? Have you any sites opened? How do you see that it's broken? From the output you showed here, I don't see any errors...


Also note that initial bug report was about different problem and I still don't have any reports about success/failure with 15.28.1.6/15.28.1.8 ucode... Eric, Bartosz do you still experience this problem?
Comment 11 Peter Volkov (RETIRED) gentoo-dev 2009-01-26 16:56:35 UTC
And Eric, Bartosz. If problem persists, could you try the following workaround:

modprobe -r iwl3945
modprobe iwl3945 disable_hw_scan=1
Comment 12 Roland Baldenhofer 2009-01-26 21:01:37 UTC
You are a hero!

I created a small script with following content:
-------------------------------
/etc/init.d/net.wlan0 stop
modprobe -r iwl3945
modprobe iwl3945 disable_hw_scan=1
ip link set wlan0 up
iwlist wlan0 scan
-------------------------------

And it works!
So I think the disable_hw_scan=1 entry stops that the MAC is going in deep sleep.

Thanks for your help!

Greetings

Roland
Comment 13 Roland Baldenhofer 2009-01-27 07:19:26 UTC
One last info:

I have changed the start() function in the /etc/init.d/net.wlan0 and added:
        if [ ${IFACE} = "wlan0" ]; then
                modprobe -r iwl3945
                modprobe iwl3945 disable_hw_scan=1
        fi
So everytime the net.wlan0 is restarted, or started for first time, the module is loaded with disable_hw_scan=1.
If Eric has a similar issue, this could help.

Cheers

Roland
Comment 14 Andri Möll 2009-02-12 21:23:05 UTC
Somewhat related to this, when loading iwl3945 *with* a net.wlan0 symlink in /etc/init.d, kernel prints "iwl3945: MAC is in deep sleep!" very soon after modprobing. Removing the net.wlan0 symlink makes the card work fine.
My /etc/conf.d/net has no *_wlan0 settings.
Comment 15 Leontiev Anton 2009-03-15 14:03:16 UTC
I have the quite same problem. But in my case iwl3945 compiled as a part of the kernel, so I can't reload it as proposed.
But the solution of Andri Möll realy work! If I delete net.wlan0, after reboot I can up and configure the interface by myself. I try to debug net.wlan0 using '/etc/init.d/net.wlan0 --verbose --debug start' but it is very amount of unknown code.
And the question is: where the bug is?
Comment 16 David King 2009-04-09 19:49:14 UTC
My fix for this problem (on stable x86) was unmasking the latest git-sources (2.6.30_rc1-git2), where the iwl3945 driver works fine. I was using gentoo-sources 2.6.29 (and -r1) up to that point, which were broken for me.
Comment 17 giovannino.perdigiorno 2009-04-29 22:58:17 UTC
I am using 2.6.30-rc3 vanilla, and experiencing the same problem as I was with most of the previous versions I tried.

My solution -- thanks to the posters above -- was to put a file in /etc/modprobe.d/ with the line:

options iwl3945 disable_hw_scan=1

it works well keeping a symlink to /etc/conf.d/net.lo in /etc/conf.d/net.wlan0.
Comment 18 Pacho Ramos gentoo-dev 2013-02-16 13:15:22 UTC
Probably could be treecleaned in favor of sys-kernel/linux-firmware
Comment 19 Pacho Ramos gentoo-dev 2013-07-21 07:12:18 UTC
looks like someone already dropped it