aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/rt2x00/rt2x00rfkill.c
diff options
context:
space:
mode:
authorIvo van Doorn <ivdoorn@gmail.com>2009-01-07 08:51:41 -0500
committerJohn W. Linville <linville@tuxdriver.com>2009-01-29 15:59:57 -0500
commit64d74681433415855da02d2516f28d2ed859cde9 (patch)
treef4c2a530ca649ca18ca547ccc702f740d7e6bebf /drivers/net/wireless/rt2x00/rt2x00rfkill.c
parent46f2c4bd7e2ba2cfedbcd4fe15d316eebc608cba (diff)
rt2x00: Only register rfkill input when key is present
rt2x00 should only register the RFKILL input device when the hardware indicated the key was present. Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/rt2x00/rt2x00rfkill.c')
-rw-r--r--drivers/net/wireless/rt2x00/rt2x00rfkill.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2x00rfkill.c b/drivers/net/wireless/rt2x00/rt2x00rfkill.c
index 595efd05ce44..53f64b76a8c1 100644
--- a/drivers/net/wireless/rt2x00/rt2x00rfkill.c
+++ b/drivers/net/wireless/rt2x00/rt2x00rfkill.c
@@ -87,7 +87,8 @@ void rt2x00rfkill_allocate(struct rt2x00_dev *rt2x00dev)
87{ 87{
88 struct input_polled_dev *poll_dev; 88 struct input_polled_dev *poll_dev;
89 89
90 if (test_bit(RFKILL_STATE_ALLOCATED, &rt2x00dev->rfkill_state)) 90 if (test_bit(RFKILL_STATE_ALLOCATED, &rt2x00dev->rfkill_state) ||
91 !test_bit(CONFIG_SUPPORT_HW_BUTTON, &rt2x00dev->flags))
91 return; 92 return;
92 93
93 poll_dev = input_allocate_polled_device(); 94 poll_dev = input_allocate_polled_device();