diff options
author | Mauro Carvalho Chehab <mchehab@infradead.org> | 2008-07-23 13:10:23 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2008-07-23 13:10:23 -0400 |
commit | a4e0d9af403d099e751797f6cc69e4a8e2d78ef1 (patch) | |
tree | 6f4afdffe5dbaad7529be987b8c3259a07395031 /drivers/input/misc/wistron_btns.c | |
parent | c60f2b5c1defb6b1345968e1c65c2008c221d57d (diff) | |
parent | c010b2f76c3032e48097a6eef291d8593d5d79a6 (diff) |
Merge ../linux-2.6
Diffstat (limited to 'drivers/input/misc/wistron_btns.c')
-rw-r--r-- | drivers/input/misc/wistron_btns.c | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/drivers/input/misc/wistron_btns.c b/drivers/input/misc/wistron_btns.c index 72176f3d49cb..fe268be3293b 100644 --- a/drivers/input/misc/wistron_btns.c +++ b/drivers/input/misc/wistron_btns.c | |||
@@ -1186,7 +1186,7 @@ static int wistron_setkeycode(struct input_dev *dev, int scancode, int keycode) | |||
1186 | 1186 | ||
1187 | static int __devinit setup_input_dev(void) | 1187 | static int __devinit setup_input_dev(void) |
1188 | { | 1188 | { |
1189 | const struct key_entry *key; | 1189 | struct key_entry *key; |
1190 | struct input_dev *input_dev; | 1190 | struct input_dev *input_dev; |
1191 | int error; | 1191 | int error; |
1192 | 1192 | ||
@@ -1219,6 +1219,23 @@ static int __devinit setup_input_dev(void) | |||
1219 | set_bit(key->sw.code, input_dev->swbit); | 1219 | set_bit(key->sw.code, input_dev->swbit); |
1220 | break; | 1220 | break; |
1221 | 1221 | ||
1222 | /* if wifi or bluetooth are not available, create normal keys */ | ||
1223 | case KE_WIFI: | ||
1224 | if (!have_wifi) { | ||
1225 | key->type = KE_KEY; | ||
1226 | key->keycode = KEY_WLAN; | ||
1227 | key--; | ||
1228 | } | ||
1229 | break; | ||
1230 | |||
1231 | case KE_BLUETOOTH: | ||
1232 | if (!have_bluetooth) { | ||
1233 | key->type = KE_KEY; | ||
1234 | key->keycode = KEY_BLUETOOTH; | ||
1235 | key--; | ||
1236 | } | ||
1237 | break; | ||
1238 | |||
1222 | default: | 1239 | default: |
1223 | break; | 1240 | break; |
1224 | } | 1241 | } |