This service will be undergoing maintenance at 00:00 UTC, 2016-09-28. It is expected to last about 1 hours
Bug 399601 - Bluetooth hot key does not work
Bluetooth hot key does not work
Status: CLOSED WONTFIX
Product: Fedora
Classification: Fedora
Component: kernel (Show other bugs)
11
All Linux
low Severity medium
: ---
: ---
Assigned To: John Feeney
Fedora Extras Quality Assurance
:
: 334891 384111 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2007-11-26 10:53 EST by Walter Cervini
Modified: 2013-01-10 03:37 EST (History)
8 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-06-28 06:29:51 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description Walter Cervini 2007-11-26 10:53:41 EST
Description of problem:
I have a IBM Thinkpad T42. The bluetooth device is activate with Fn+F5. 
This host key is not assigned to activate bluetooth device.

Version-Release number of selected component (if applicable):
bluez-utils.i386  version: 3.20-4.fc8 

Adittional info:
I can activate the bluetooth device via /proc/acpi/ibm/bluetooth, enable o
disable this.

echo enable > /proc/acpi/ibm/bluetooth 
echo disable > /proc/acpi/ibm/bluetooth 

On Fedora 7 or older this hotkey was work.

I'm think is not assigned the activate function key for this device.
Comment 1 Tim Niemueller 2008-05-16 06:57:51 EDT
The problem also appears on T60 laptops on x86_64 (probably even more, I just
checked this one).

A workaround is to catch the ACPI event and use a script to toggle it. For this
create a script /etc/acpi/actions/toggle-bluetooth.sh with the following content:
#!/bin/sh

BT_STATUS=`cat /proc/acpi/ibm/bluetooth | grep status | awk -F: '{ print $2 }' |
tr -d " \t"`

if [ "$BT_STATUS" = "disabled" ]; then
        echo enable > /proc/acpi/ibm/bluetooth
else
        echo disable > /proc/acpi/ibm/bluetooth
fi


Then create a file /etc/acpi/events/bluetooth.conf with the following content:
event=ibm/hotkey HKEY 00000080 00001005
action=/etc/acpi/actions/toggle-bluetooth.sh

To check if that is the correct code for your laptop use acpi_listen.

Now reload acpid configuration with /sbin/service acpid reload and from then on
Fn-F5 should work again.

Is there a chance that this gets included in some package so that it just works
again?
Comment 2 Paul Bolle 2008-05-30 06:40:47 EDT
I can confirm this on an IBM ThinkPad T41 and an IBM ThinkPad X41.

For what it's worth, another workaround  is to unmask Fn+F5 in the "ibm hotkey
mask". This workaround doesn't require acpid. (I seem to have written this
workaround for F8. It still works in F9.)

$ cat /etc/sysconfig/modules/thinkpad_acpi.modules 
#!/bin/sh
/sbin/modprobe thinkpad_acpi

# 12 December 2007
# unmask Fn+F5 (bluetooth toggle key)
HOTKEY_STATUS=$(sed -ne '/status:/ {s/^status:[ \t]*//; p}' /proc/acpi/ibm/hotkey)
if [ "x$HOTKEY_STATUS" == "xenabled" ]; then
    HOTKEY_MASK=$(sed -ne '/mask:/ {s/^mask:[ \t]*//; p}' /proc/acpi/ibm/hotkey)
    printf "0x%x\n" $(( $HOTKEY_MASK & 0xffffffef )) > /proc/acpi/ibm/hotkey
fi

(The executable file /etc/sysconfig/modules/thinkpad_acpi.modules is executed by
/etc/rc.sysinit at system initialization, as far as I can see _before_
thinkpad_acpi is automagically loaded. I'm not sure how that works, though.)
Comment 3 petrosyan 2008-06-04 10:56:14 EDT
*** Bug 334891 has been marked as a duplicate of this bug. ***
Comment 4 petrosyan 2008-07-17 19:16:07 EDT
This bug is also present in ThinkPad X61.
Comment 5 Bug Zapper 2008-11-25 21:03:41 EST
This bug appears to have been reported against 'rawhide' during the Fedora 10 development cycle.
Changing version to '10'.

More information and reason for this action is here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping
Comment 6 Edmond Hui 2008-12-01 03:34:21 EST
*** Bug 384111 has been marked as a duplicate of this bug. ***
Comment 7 Matthew Garrett 2008-12-03 21:45:13 EST
Try loading rfkill-input
Comment 8 Tim Niemueller 2008-12-04 07:48:48 EST
Nope, does not work. I did the following:

# Bluetooth is disabled
- Move away ACPI workaround script mentioned above
- /sbin/service acpid reload
- modprobe rfkill
# This turned on bluetooth

Fn-F5 still has no effect, neither turning on nor off.

Interesting is this:
# lsmod | grep rfkill
rfkill_input           13824  0 
rfkill                 17316  5 rfkill_input,iwl3945,thinkpad_acpi

So should the thinkpad_acpi already be able to cope with this or should it be patched there?
Comment 9 Dan Alderman 2009-01-16 05:43:54 EST
Same bug on Thinkpad X61s (76693JG) using a live USB system (2.6.27.5-117 i686).

Bluetooth is on from boot for me. Please contact me if you would like me to test anything.
Comment 10 Paul Bolle 2009-02-11 15:54:33 EST
(In reply to comment #9)
> Bluetooth is on from boot for me.

Separate issue. A fix (that worked for me under 2.6.27.12-78.2.8.fc9.i686) for that issue:
    $ cat /etc/modprobe.d/rfkill 
    options rfkill default_state=0
Comment 11 Edmond Hui 2009-04-26 02:27:26 EDT
I just tested out the rfkill solution above.

It works, but it also turn off the Wifi connection by default on my T60. The problem with this is the soft Fn-F5 on-off is only turning on/off bluetooth but not wifi, which left wifi struck in disabled state....
Comment 12 Paul Bolle 2009-04-26 04:31:33 EDT
(In reply to comment #11)
> I just tested out the rfkill solution above.

Just to be clear: did you mean the "load rfkill-input" suggestion of comment #7 or the "rfkill default_state=0" fix of comment #10?
Comment 13 Edmond Hui 2009-04-27 03:15:51 EDT
comment #10...
Comment 14 Chris Nutt 2009-06-13 18:42:01 EDT
I am receiving the same error with Fedora 11, KDE4 IBM - T41
Comment 15 Edmond Hui 2009-07-01 14:40:14 EDT
This problem still exist in F11....
Comment 16 Bug Zapper 2009-11-18 05:08:56 EST
This message is a reminder that Fedora 10 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 10.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '10'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 10's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 10 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping
Comment 17 Tim Niemueller 2009-11-18 05:45:27 EST
It at least exists on F11 according to comment #15 (I'm running with the workaround mentioned in comment #1), haven't tried on F12, yet. Anyone else?
Comment 18 Paul Bolle 2009-11-18 06:32:59 EST
(In reply to comment #17)
> Anyone else?

0) Still reproducible with the IBM ThinkPad T41 mentioned in comment #2 (not using the workaround I described there). It is now running Rawhide (ie, kernel-2.6.32-0.48.rc7.git1.fc13.i686; any other packages relevant?). That kernel doesn't have a module rfkill-input (see comment #7).

2) Using that workaround the Fn+F5 combo does work as I expect. (Using that combo will currently launch some bluetooth stuff automagically, though that apparently ends with this error: "bluetoothd[...]: Can't init device hci0: Unknown error 132 (132)". I seem to remember that this error rfkill related. Anyhow, I suppose that might be another issue).
Comment 19 Bug Zapper 2010-04-27 07:50:19 EDT
This message is a reminder that Fedora 11 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 11.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '11'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 11's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 11 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping
Comment 20 Paul Bolle 2010-05-02 06:57:23 EDT
0) Still reproducible with the IBM ThinkPad T41 mentioned in comment #2 (ie, when not using the workaround I described there). It is still running Rawhide (ie, kernel-2.6.34-0.38.rc5.git0.fc14.i686; any other packages relevant?). That kernel still doesn't have a module rfkill-input (see comment #7).

2) Using that workaround the Fn+F5 combo will currently launch some bluetooth stuff automagically, and bluetooth seems to work correctly. However, for some reason, while bluetooth is working WiFi is always rfkill'ed (regardless whether bluetooth is on or off): 
$ /sbin/ifup wlan0
RTNETLINK answers: Operation not possible due to RF-kill

Determining IP information for wlan0...Can't create /var/run/dhclient-wlan0.pid: Permission denied
RTNETLINK answers: Operation not possible due to RF-kill

(At which point ifup seems to hang.)

3) In summary: still reproducible, but my old workaround now runs into trouble, possibly through some weird interaction with the rfkill module.
Comment 21 Bug Zapper 2010-06-28 06:29:51 EDT
Fedora 11 changed to end-of-life (EOL) status on 2010-06-25. Fedora 11 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.

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