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

Commit d85486d4 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull input updates from Dmitry Torokhov:
 "Updates for the input subsystem.  This contains the following new
  drivers promised in the last merge window:

   - driver for touchscreen controller found in Surface 3
   - driver for Pegasus Notetaker tablet
   - driver for Atmel Captouch Buttons
   - driver for Raydium I2C touchscreen controllers
   - powerkey driver for HISI 65xx SoC

  plus a few fixes"

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: (40 commits)
  Input: tty/vt/keyboard - use memdup_user()
  Input: pegasus_notetaker - set device mode in reset_resume() if in use
  Input: pegasus_notetaker - cancel workqueue's work in suspend()
  Input: pegasus_notetaker - fix usb_autopm calls to be balanced
  Input: pegasus_notetaker - handle usb control msg errors
  Input: wacom_w8001 - handle errors from input_mt_init_slots()
  Input: wacom_w8001 - resolution wasn't set for ABS_MT_POSITION_X/Y
  Input: pixcir_ts - add support for axis inversion / swapping
  Input: icn8318 - use of_touchscreen helpers for inverting / swapping axes
  Input: edt-ft5x06 - add support for inverting / swapping axes
  Input: of_touchscreen - add support for inverted / swapped axes
  Input: synaptics-rmi4 - use the RMI_F11_REL_BYTES define in rmi_f11_rel_pos_report
  Input: synaptics-rmi4 - remove unneeded variable
  Input: synaptics-rmi4 - remove pointer to rmi_function in f12_data
  Input: synaptics-rmi4 - support regulator supplies
  Input: raydium_i2c_ts - check CRC of incoming packets
  Input: xen-kbdfront - prefer xenbus_write() over xenbus_printf() where possible
  Input: fix a double word "is is" in include/linux/input.h
  Input: add powerkey driver for HISI 65xx SoC
  Input: apanel - spelling mistake - "skiping" -> "skipping"
  ...
parents 66304207 08088828
Loading
Loading
Loading
Loading
+36 −0
Original line number Diff line number Diff line
Device tree bindings for Atmel capacitive touch device, typically
an Atmel touch sensor connected to AtmegaXX MCU running firmware
based on Qtouch library.

The node for this device must be a child of a I2C controller node, as the
device communicates via I2C.

Required properties:

	compatible:	Must be "atmel,captouch".
	reg:		The I2C slave address of the device.
	interrupts:	Property describing the interrupt line the device
			is connected to. The device only has one interrupt
			source.
	linux,keycodes:	Specifies an array of numeric keycode values to
			be used for reporting button presses. The array can
			contain up to 8 entries.

Optional properties:

	autorepeat:	Enables the Linux input system's autorepeat
			feature on the input device.

Example:

	atmel-captouch@51 {
		compatible = "atmel,captouch";
		reg = <0x51>;
		interrupt-parent = <&tlmm>;
		interrupts = <67 IRQ_TYPE_EDGE_FALLING>;
		linux,keycodes = <BTN_0>, <BTN_1>,
			<BTN_2>, <BTN_3>,
			<BTN_4>, <BTN_5>,
			<BTN_6>, <BTN_7>;
		autorepeat;
	};
+20 −0
Original line number Diff line number Diff line
Raydium I2C touchscreen

Required properties:
- compatible: must be "raydium,rm32380"
- reg: The I2C address of the device
- interrupt-parent: the phandle for the interrupt controller
- interrupts: interrupt to which the chip is connected
    See ../interrupt-controller/interrupts.txt
Optional properties:
- avdd-supply: analog power supply needed to power device
- vccio-supply: IO Power source
- reset-gpios: reset gpio the chip is connected to.

Example:
	touchscreen@39 {
		compatible = "raydium,rm32380";
		reg = <0x39>;
		interrupt-parent = <&gpio>;
		interrupts = <0x0 IRQ_TYPE_EDGE_FALLING>;
	};
+9 −0
Original line number Diff line number Diff line
@@ -22,6 +22,15 @@ See Documentation/devicetree/bindings/interrupt-controller/interrupts.txt
- syna,reset-delay-ms: The number of milliseconds to wait after resetting the
			device.

- syna,startup-delay-ms: The number of milliseconds to wait after powering on
			 the device.

- vdd-supply: VDD power supply.
See ../regulator/regulator.txt

- vio-supply: VIO power supply
See ../regulator/regulator.txt

Function Parameters:
Parameters specific to RMI functions are contained in child nodes of the rmi device
 node. Documentation for the parameters of each function can be found in:
+1 −0
Original line number Diff line number Diff line
@@ -214,6 +214,7 @@ raidsonic RaidSonic Technology GmbH
ralink	Mediatek/Ralink Technology Corp.
ramtron	Ramtron International
raspberrypi	Raspberry Pi Foundation
raydium	Raydium Semiconductor Corp.
realtek Realtek Semiconductor Corp.
renesas	Renesas Electronics Corporation
richtek	Richtek Technology Corporation
+16 −1
Original line number Diff line number Diff line
@@ -218,8 +218,23 @@ void input_mt_report_pointer_emulation(struct input_dev *dev, bool use_count)
	}

	input_event(dev, EV_KEY, BTN_TOUCH, count > 0);
	if (use_count)

	if (use_count) {
		if (count == 0 &&
		    !test_bit(ABS_MT_DISTANCE, dev->absbit) &&
		    test_bit(ABS_DISTANCE, dev->absbit) &&
		    input_abs_get_val(dev, ABS_DISTANCE) != 0) {
			/*
			 * Force reporting BTN_TOOL_FINGER for devices that
			 * only report general hover (and not per-contact
			 * distance) when contact is in proximity but not
			 * on the surface.
			 */
			count = 1;
		}

		input_mt_report_finger_count(dev, count);
	}

	if (oldest) {
		int x = input_mt_get_value(oldest, ABS_MT_POSITION_X);
Loading