Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d4e65476 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull input subsystem updates from Dmitry Torokhov:
 "You will get

   - a new driver for Elan eKTF2127 touchscreen controllers

   - a new "gpio-decoder" driver to read and report state of several
     GPIO lines

   - an ADC resistor ladder driver

   - the ft6326 driver is removed because edt-ft5x06 handles the same
     devices just fine.

  .. plus the regular slew of driver fixes/enhancements"

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: (26 commits)
  Input: elan_i2c - fix return tests of i2c_smbus_read_block_data()
  Input: ektf2127 - mark PM functions as __maybe_unused
  Input: snvs_pwrkey - drop input_free_device call if input_register_device fails
  Input: add support for Elan eKTF2127 touchscreen controller
  Input: serio - add hangup support
  Input: tps65218-pwrbutton - add support for tps65217 variant
  Input: jornada720_ts - get rid of mach/irqs.h and mach/hardware.h includes
  Input: jornada720_kbd - remove unneeded mach/hardware.h include
  Input: focaltech - mark focaltech_set_resolution() static
  Input: wdt87xx_i2c - fix the flash erase issue
  Input: gpio-keys-polled - don't use unit-address with button nodes
  Input: add generic input driver to read encoded GPIO lines
  Input: add ADC resistor ladder driver
  Input: pegasus_notetaker - directly include workqueue header
  Input: elants_i2c - get product id on recovery mode for FW update
  Input: wm97xx - remove deprecated create_singletheread_workqueue
  Input: mc13783_ts - remove deprecated create_singletheread_workqueue
  Input: psmouse - remove deprecated create_singletheread_workqueue
  Input: jornada720_kbd - switch to using dev_dbg
  Input: jornada720_kbd - get rid of mach/irqs.h include
  ...
parents d0423808 c758f96a
Loading
Loading
Loading
Loading
+49 −0
Original line number Diff line number Diff line
ADC attached resistor ladder buttons
------------------------------------

Required properties:
 - compatible: "adc-keys"
 - io-channels: Phandle to an ADC channel
 - io-channel-names = "buttons";
 - keyup-threshold-microvolt: Voltage at which all the keys are considered up.

Optional properties:
	- poll-interval: Poll interval time in milliseconds
	- autorepeat: Boolean, Enable auto repeat feature of Linux input
	  subsystem.

Each button (key) is represented as a sub-node of "adc-keys":

Required subnode-properties:
	- label: Descriptive name of the key.
	- linux,code: Keycode to emit.
	- press-threshold-microvolt: Voltage ADC input when this key is pressed.

Example:

#include <dt-bindings/input/input.h>

	adc-keys {
		compatible = "adc-keys";
		io-channels = <&lradc 0>;
		io-channel-names = "buttons";
		keyup-threshold-microvolt = <2000000>;

		button-up {
			label = "Volume Up";
			linux,code = <KEY_VOLUMEUP>;
			press-threshold-microvolt = <1500000>;
		};

		button-down {
			label = "Volume Down";
			linux,code = <KEY_VOLUMEDOWN>;
			press-threshold-microvolt = <1000000>;
		};

		button-enter {
			label = "Enter";
			linux,code = <KEY_ENTER>;
			press-threshold-microvolt = <500000>;
		};
	};
+23 −0
Original line number Diff line number Diff line
* GPIO Decoder DT bindings

Required Properties:
- compatible: should be "gpio-decoder"
- gpios: a spec of gpios (at least two) to be decoded to a number with
  first entry representing the MSB.

Optional Properties:
- decoder-max-value: Maximum possible value that can be reported by
  the gpios.
- linux,axis: the input subsystem axis to map to (ABS_X/ABS_Y).
  Defaults to 0 (ABS_X).

Example:
	gpio-decoder0 {
		compatible = "gpio-decoder";
		gpios = <&pca9536 3 GPIO_ACTIVE_HIGH>,
			<&pca9536 2 GPIO_ACTIVE_HIGH>,
			<&pca9536 1 GPIO_ACTIVE_HIGH>,
			<&pca9536 0 GPIO_ACTIVE_HIGH>;
		linux,axis = <0>; /* ABS_X */
		decoder-max-value = <9>;
	};
+2 −3
Original line number Diff line number Diff line
@@ -34,11 +34,10 @@ Example nodes:

	gpio_keys_polled {
			compatible = "gpio-keys-polled";
			#address-cells = <1>;
			#size-cells = <0>;
			poll-interval = <100>;
			autorepeat;
			button@21 {

			button21 {
				label = "GPIO Key UP";
				linux,code = <103>;
				gpios = <&gpio1 0 1>;
+8 −0
Original line number Diff line number Diff line
@@ -19,6 +19,7 @@ Required properties:
           or:  "edt,edt-ft5306"
           or:  "edt,edt-ft5406"
           or:  "edt,edt-ft5506"
           or:  "focaltech,ft6236"

 - reg:         I2C slave address of the chip (0x38)
 - interrupt-parent: a phandle pointing to the interrupt controller
@@ -43,6 +44,13 @@ Optional properties:

 - offset:      allows setting the edge compensation in the range from
                0 to 31.
 - touchscreen-size-x	   : See touchscreen.txt
 - touchscreen-size-y	   : See touchscreen.txt
 - touchscreen-fuzz-x      : See touchscreen.txt
 - touchscreen-fuzz-y      : See touchscreen.txt
 - touchscreen-inverted-x  : See touchscreen.txt
 - touchscreen-inverted-y  : See touchscreen.txt
 - touchscreen-swapped-x-y : See touchscreen.txt

Example:
	polytouch: edt-ft5x06@38 {
+27 −0
Original line number Diff line number Diff line
* Elan eKTF2127 I2C touchscreen controller

Required properties:
 - compatible		  : "elan,ektf2127"
 - reg			  : I2C slave address of the chip (0x40)
 - interrupt-parent	  : a phandle pointing to the interrupt controller
			    serving the interrupt for this chip
 - interrupts		  : interrupt specification for the ektf2127 interrupt
 - power-gpios		  : GPIO specification for the pin connected to the
			    ektf2127's wake input. This needs to be driven high
			    to take ektf2127 out of it's low power state

For additional optional properties see: touchscreen.txt

Example:

i2c@00000000 {
	ektf2127: touchscreen@15 {
		compatible = "elan,ektf2127";
		reg = <0x15>;
		interrupt-parent = <&pio>;
		interrupts = <6 11 IRQ_TYPE_EDGE_FALLING>
		power-gpios = <&pio 1 3 GPIO_ACTIVE_HIGH>;
		touchscreen-inverted-x;
		touchscreen-swapped-x-y;
	};
};
Loading