Lines Matching +full:max77650 +full:- +full:charger
1 // SPDX-License-Identifier: GPL-2.0
6 // ONKEY driver for MAXIM 77650/77651 charger/power-supply.
11 #include <linux/mfd/max77650.h>
29 input_report_key(onkey->input, onkey->code, 0); in max77650_onkey_falling()
30 input_sync(onkey->input); in max77650_onkey_falling()
39 input_report_key(onkey->input, onkey->code, 1); in max77650_onkey_rising()
40 input_sync(onkey->input); in max77650_onkey_rising()
53 dev = &pdev->dev; in max77650_onkey_probe()
54 parent = dev->parent; in max77650_onkey_probe()
58 return -ENODEV; in max77650_onkey_probe()
62 return -ENOMEM; in max77650_onkey_probe()
64 error = device_property_read_u32(dev, "linux,code", &onkey->code); in max77650_onkey_probe()
66 onkey->code = KEY_POWER; in max77650_onkey_probe()
68 if (device_property_read_bool(dev, "maxim,onkey-slide")) { in max77650_onkey_probe()
89 onkey->input = devm_input_allocate_device(dev); in max77650_onkey_probe()
90 if (!onkey->input) in max77650_onkey_probe()
91 return -ENOMEM; in max77650_onkey_probe()
93 onkey->input->name = "max77650_onkey"; in max77650_onkey_probe()
94 onkey->input->phys = "max77650_onkey/input0"; in max77650_onkey_probe()
95 onkey->input->id.bustype = BUS_I2C; in max77650_onkey_probe()
96 input_set_capability(onkey->input, type, onkey->code); in max77650_onkey_probe()
99 IRQF_ONESHOT, "onkey-down", onkey); in max77650_onkey_probe()
104 IRQF_ONESHOT, "onkey-up", onkey); in max77650_onkey_probe()
108 return input_register_device(onkey->input); in max77650_onkey_probe()
112 { .compatible = "maxim,max77650-onkey" },
119 .name = "max77650-onkey",
129 MODULE_ALIAS("platform:max77650-onkey");