Commit afce285b authored by Marco Felsch's avatar Marco Felsch Committed by Dmitry Torokhov

Input: da9063 - fix capability and drop KEY_SLEEP

Since commit f889beaa ("Input: da9063 - report KEY_POWER instead of
KEY_SLEEP during power key-press") KEY_SLEEP isn't supported anymore. This
caused input device to not generate any events if "dlg,disable-key-power"
is set.

Fix this by unconditionally setting KEY_POWER capability, and not
declaring KEY_SLEEP.

Fixes: f889beaa ("Input: da9063 - report KEY_POWER instead of KEY_SLEEP during power key-press")
Signed-off-by: default avatarMarco Felsch <m.felsch@pengutronix.de>
Cc: stable@vger.kernel.org
Signed-off-by: default avatarDmitry Torokhov <dmitry.torokhov@gmail.com>
parent 08987822
...@@ -232,10 +232,7 @@ static int da9063_onkey_probe(struct platform_device *pdev) ...@@ -232,10 +232,7 @@ static int da9063_onkey_probe(struct platform_device *pdev)
onkey->input->phys = onkey->phys; onkey->input->phys = onkey->phys;
onkey->input->dev.parent = &pdev->dev; onkey->input->dev.parent = &pdev->dev;
if (onkey->key_power) input_set_capability(onkey->input, EV_KEY, KEY_POWER);
input_set_capability(onkey->input, EV_KEY, KEY_POWER);
input_set_capability(onkey->input, EV_KEY, KEY_SLEEP);
INIT_DELAYED_WORK(&onkey->work, da9063_poll_on); INIT_DELAYED_WORK(&onkey->work, da9063_poll_on);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment