Bug 498622 - iwl3945 stays disabled after booted with rf killswitch on
Summary: iwl3945 stays disabled after booted with rf killswitch on
Alias: None
Product: Fedora
Classification: Fedora
Component: kernel
Version: 11
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Stanislaw Gruszka
QA Contact: Fedora Extras Quality Assurance
: 505456 (view as bug list)
Depends On:
TreeView+ depends on / blocked
Reported: 2009-05-01 14:50 UTC by Ales Zelinka
Modified: 2009-10-05 09:39 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2009-10-05 07:22:48 UTC
Type: ---

Attachments (Terms of Use)
Proposed fix. (1.18 KB, patch)
2009-07-02 06:55 UTC, Stanislaw Gruszka
no flags Details | Diff

Description Ales Zelinka 2009-05-01 14:50:02 UTC
Description of problem:
I can't get my wifi working after booting with rf kill switch on and turning it off afterwards.
Module iwl3945 has to be reloaded for wifi to work again.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. turn rf killswitch on
2. reboot
3. turn rf killswitch off
4. try to up the interface (ip l set up dev wlan0)
Actual results:
wlan0 device is not working
kernel thinks module has been disabled.
from /var/log/messages (after the "ip l set up dev wlan0" command)

kernel: iwl3945: Radio disabled by SW RF kill (module parameter)

Expected results:
working wlan interface after rf killswitch is turned off

Additional info:
It works as expected with vanilla kernel

Comment 1 Ales Zelinka 2009-05-01 14:52:41 UTC
I forgot to mention my hw:

Lenovo T61
03:00.0 Network controller: Intel Corporation PRO/Wireless 3945ABG [Golan] Network Connection (rev 02)

Comment 2 Bug Zapper 2009-06-09 14:57:07 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 11 development cycle.
Changing version to '11'.

More information and reason for this action is here:

Comment 3 Michał Rudowicz 2009-06-16 06:44:38 UTC
If you unload iwl3945 module using rmmod and then load it again using modprobe, wireless card starts to work, at least for me on Lenovo R61. There just needs to be a way to make system do that automatically after switching killswitch.

Comment 4 Ales Zelinka 2009-06-16 07:02:37 UTC
Thanks for reply.
I know this workaround and am glad there is a way to make my wireless work. But I'd rather see a clean fix than hard-wiring a workaround into the system. Especially when this behaviour is caused by some of fedora patches (upstream kernel worked fine).

Comment 5 Michał Rudowicz 2009-06-16 16:17:58 UTC
I've noticed that my workaround doesn't work in all cases.

Comment 6 Stanislaw Gruszka 2009-07-01 14:42:39 UTC
In rfkill subsystem switch has tree states HARD_BLOCK, SOFT_BLOCK and
UNBLOCKED and can be only in one state at the same time.

In iwl3945 driver are separate switches (bits) STATUS_RF_KILL_SW, STATUS_RF_KILL_HW, radio transmitter can be enabled only if both of these bits are clear.

What happens:

- during boot rfkill change state from UNBLOCK to SOFT_BLOCK and then again
- if rfkill move to SOFT_BLOCK it set STATUS_RF_KILL_SW in driver and
  clear it when change to UNBLOCK
- if iwl3945 driver initialize during SOFT_BLOCK and laptop killswitch is
  on, it change set STATUS_RF_KILL_HW and rfkill state to HARD_BLOCK
  (using rfkill_force_state())
- rfkill wants to change to UNBLOCK but the state is now HARD_BLOCK - so
  give up
- killswitch on laptop change to off, iwl3945 clear STATUS_RF_KILL_HW
- iwl3945 still has set STATUS_RF_KILL_SW, so not enable radio

Problem not happens if during rfkill UNBLOCK->SOFT_BLOCK->UNBLOCK
sequence iwl3945 driver is not initializing it's owns RF KILL internals or laptop killswitch is off.

Bug can be observed in fedora due to backported


It is also present in mainline 2.6.30 and fixed in 2.6.31-rc1 because of rewrite of rfkill subsystem in:  

commit 19d337dff95cbf76edd3ad95c0cee2732c3e1ec5
Author: Johannes Berg <johannes>
Date:   Tue Jun 2 13:01:37 2009 +0200

    rfkill: rewrite

After commit rfkill subsystem is mach more sane implemented and HW/SW switches are represented as separate bits line in iwl3945 dirver.

Comment 7 Stanislaw Gruszka 2009-07-02 06:55:48 UTC
Created attachment 350247 [details]
Proposed fix.

This is workaround/fix of problem. In iwl3945 we disable SW switch regardless of HW switch state. We also report SW state before HW state to move rfkill subsystem to SOFT_BLOCK rather than HARD_BLOCK.

Comment 8 Stanislaw Gruszka 2009-07-02 07:05:37 UTC
I do basic tests the patch on my laptop and generally it works. I not tested it with suspend (as KDE Hibernete button in F11 seems not work for me :-( )

Below is link to kernel with fix:


Comment 9 John W. Linville 2009-07-07 17:52:57 UTC
*** Bug 505456 has been marked as a duplicate of this bug. ***

Comment 10 Stanislaw Gruszka 2009-08-04 11:50:22 UTC
Fedora 11 now is switching to 2.6.30 kernel. Sadly on vanilla the rfkill with iwl3945 driver perform even worse. On my laptop after turning killswitch on and off wifi not work. Have to not use rfkill switch at all to make wifi working.

Comment 11 Stanislaw Gruszka 2009-10-05 07:22:48 UTC
I'm closing this bug since is fixed in kernel, and F11 ships now .

Comment 12 Ales Zelinka 2009-10-05 09:39:04 UTC
Fix confirmed, thanks.

Note You need to log in before you can comment on or make changes to this bug.