Commit 0fe86b27 authored by Linus Torvalds's avatar Linus Torvalds

Merge tag 'input-for-v5.18-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input

Pull input fixes from Dmitry Torokhov:

 - a new set of keycodes to be used by marine navigation systems

 - minor fixes to omap4-keypad and cypress-sf drivers

* tag 'input-for-v5.18-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
  Input: add Marine Navigation Keycodes
  Input: omap4-keypad - fix pm_runtime_get_sync() error checking
  Input: cypress-sf - register a callback to disable the regulators
parents 8467f9e3 470776c6
...@@ -61,6 +61,14 @@ static irqreturn_t cypress_sf_irq_handler(int irq, void *devid) ...@@ -61,6 +61,14 @@ static irqreturn_t cypress_sf_irq_handler(int irq, void *devid)
return IRQ_HANDLED; return IRQ_HANDLED;
} }
static void cypress_sf_disable_regulators(void *arg)
{
struct cypress_sf_data *touchkey = arg;
regulator_bulk_disable(ARRAY_SIZE(touchkey->regulators),
touchkey->regulators);
}
static int cypress_sf_probe(struct i2c_client *client) static int cypress_sf_probe(struct i2c_client *client)
{ {
struct cypress_sf_data *touchkey; struct cypress_sf_data *touchkey;
...@@ -121,6 +129,12 @@ static int cypress_sf_probe(struct i2c_client *client) ...@@ -121,6 +129,12 @@ static int cypress_sf_probe(struct i2c_client *client)
return error; return error;
} }
error = devm_add_action_or_reset(&client->dev,
cypress_sf_disable_regulators,
touchkey);
if (error)
return error;
touchkey->input_dev = devm_input_allocate_device(&client->dev); touchkey->input_dev = devm_input_allocate_device(&client->dev);
if (!touchkey->input_dev) { if (!touchkey->input_dev) {
dev_err(&client->dev, "Failed to allocate input device\n"); dev_err(&client->dev, "Failed to allocate input device\n");
......
...@@ -393,7 +393,7 @@ static int omap4_keypad_probe(struct platform_device *pdev) ...@@ -393,7 +393,7 @@ static int omap4_keypad_probe(struct platform_device *pdev)
* revision register. * revision register.
*/ */
error = pm_runtime_get_sync(dev); error = pm_runtime_get_sync(dev);
if (error) { if (error < 0) {
dev_err(dev, "pm_runtime_get_sync() failed\n"); dev_err(dev, "pm_runtime_get_sync() failed\n");
pm_runtime_put_noidle(dev); pm_runtime_put_noidle(dev);
return error; return error;
......
...@@ -662,6 +662,27 @@ ...@@ -662,6 +662,27 @@
/* Select an area of screen to be copied */ /* Select an area of screen to be copied */
#define KEY_SELECTIVE_SCREENSHOT 0x27a #define KEY_SELECTIVE_SCREENSHOT 0x27a
/* Move the focus to the next or previous user controllable element within a UI container */
#define KEY_NEXT_ELEMENT 0x27b
#define KEY_PREVIOUS_ELEMENT 0x27c
/* Toggle Autopilot engagement */
#define KEY_AUTOPILOT_ENGAGE_TOGGLE 0x27d
/* Shortcut Keys */
#define KEY_MARK_WAYPOINT 0x27e
#define KEY_SOS 0x27f
#define KEY_NAV_CHART 0x280
#define KEY_FISHING_CHART 0x281
#define KEY_SINGLE_RANGE_RADAR 0x282
#define KEY_DUAL_RANGE_RADAR 0x283
#define KEY_RADAR_OVERLAY 0x284
#define KEY_TRADITIONAL_SONAR 0x285
#define KEY_CLEARVU_SONAR 0x286
#define KEY_SIDEVU_SONAR 0x287
#define KEY_NAV_INFO 0x288
#define KEY_BRIGHTNESS_MENU 0x289
/* /*
* Some keyboards have keys which do not have a defined meaning, these keys * Some keyboards have keys which do not have a defined meaning, these keys
* are intended to be programmed / bound to macros by the user. For most * are intended to be programmed / bound to macros by the user. For most
......
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