staging: unisys: visorinput: remove extraneous do_key function
do_key() is no longer needed. Signed-off-by: Tim Sell <Timothy.Sell@unisys.com> Signed-off-by: Benjamin Romer <benjamin.romer@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
b4f033f2d0
commit
464b577c8b
|
@ -452,12 +452,6 @@ visorinput_remove(struct visor_device *dev)
|
||||||
kfree(devdata);
|
kfree(devdata);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
|
||||||
do_key(struct input_dev *inpt, int keycode, int down)
|
|
||||||
{
|
|
||||||
input_report_key(inpt, keycode, down);
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Make it so the current locking state of the locking key indicated by
|
* Make it so the current locking state of the locking key indicated by
|
||||||
* <keycode> is as indicated by <desired_state> (1=locked, 0=unlocked).
|
* <keycode> is as indicated by <desired_state> (1=locked, 0=unlocked).
|
||||||
|
@ -490,9 +484,9 @@ handle_locking_key(struct input_dev *visorinput_dev,
|
||||||
int old_state = (test_bit(led, visorinput_dev->led) != 0);
|
int old_state = (test_bit(led, visorinput_dev->led) != 0);
|
||||||
|
|
||||||
if (old_state != desired_state) {
|
if (old_state != desired_state) {
|
||||||
do_key(visorinput_dev, keycode, 1);
|
input_report_key(visorinput_dev, keycode, 1);
|
||||||
input_sync(visorinput_dev);
|
input_sync(visorinput_dev);
|
||||||
do_key(visorinput_dev, keycode, 0);
|
input_report_key(visorinput_dev, keycode, 0);
|
||||||
input_sync(visorinput_dev);
|
input_sync(visorinput_dev);
|
||||||
__change_bit(led, visorinput_dev->led);
|
__change_bit(led, visorinput_dev->led);
|
||||||
}
|
}
|
||||||
|
@ -563,17 +557,17 @@ visorinput_channel_interrupt(struct visor_device *dev)
|
||||||
keycode = scancode_to_keycode(scancode);
|
keycode = scancode_to_keycode(scancode);
|
||||||
switch (r.activity.action) {
|
switch (r.activity.action) {
|
||||||
case inputaction_key_down:
|
case inputaction_key_down:
|
||||||
do_key(visorinput_dev, keycode, 1);
|
input_report_key(visorinput_dev, keycode, 1);
|
||||||
input_sync(visorinput_dev);
|
input_sync(visorinput_dev);
|
||||||
break;
|
break;
|
||||||
case inputaction_key_up:
|
case inputaction_key_up:
|
||||||
do_key(visorinput_dev, keycode, 0);
|
input_report_key(visorinput_dev, keycode, 0);
|
||||||
input_sync(visorinput_dev);
|
input_sync(visorinput_dev);
|
||||||
break;
|
break;
|
||||||
case inputaction_key_down_up:
|
case inputaction_key_down_up:
|
||||||
do_key(visorinput_dev, keycode, 1);
|
input_report_key(visorinput_dev, keycode, 1);
|
||||||
input_sync(visorinput_dev);
|
input_sync(visorinput_dev);
|
||||||
do_key(visorinput_dev, keycode, 0);
|
input_report_key(visorinput_dev, keycode, 0);
|
||||||
input_sync(visorinput_dev);
|
input_sync(visorinput_dev);
|
||||||
break;
|
break;
|
||||||
case inputaction_set_locking_key_state:
|
case inputaction_set_locking_key_state:
|
||||||
|
|
Loading…
Reference in New Issue