Commit 56f94452 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull input updates from Dmitry Torokhov:

 - a brand new driver for touchpads and touchbars in newer Apple devices

 - support for Berlin-A series in goodix-berlin touchscreen driver

 - improvements to matrix_keypad driver to better handle GPIOs toggling

 - assorted small cleanups in other input drivers

* tag 'input-for-v6.15-rc0' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
  Input: goodix_berlin - add support for Berlin-A series
  dt-bindings: input: goodix,gt9916: Document gt9897 compatible
  dt-bindings: input: matrix_keypad - add wakeup-source property
  dt-bindings: input: matrix_keypad - add missing property
  Input: pm8941-pwrkey - fix dev_dbg() output in pm8941_pwrkey_irq()
  Input: synaptics - hide unused smbus_pnp_ids[] array
  Input: apple_z2 - fix potential confusion in Kconfig
  Input: matrix_keypad - use fsleep for delays after activating columns
  Input: matrix_keypad - add settle time after enabling all columns
  dt-bindings: input: matrix_keypad: add settle time after enabling all columns
  dt-bindings: input: matrix_keypad: convert to YAML
  dt-bindings: input: Correct indentation and style in DTS example
  MAINTAINERS: Add entries for Apple Z2 touchscreen driver
  Input: apple_z2 - add a driver for Apple Z2 touchscreens
  dt-bindings: input: touchscreen: Add Z2 controller
  Input: Switch to use hrtimer_setup()
  Input: drop vb2_ops_wait_prepare/finish
parents a8662bcd 946661e3
Loading
Loading
Loading
Loading
+0 −49
Original line number Diff line number Diff line
* GPIO driven matrix keypad device tree bindings

GPIO driven matrix keypad is used to interface a SoC with a matrix keypad.
The matrix keypad supports multiple row and column lines, a key can be
placed at each intersection of a unique row and a unique column. The matrix
keypad can sense a key-press and key-release by means of GPIO lines and
report the event using GPIO interrupts to the cpu.

Required Properties:
- compatible:		Should be "gpio-matrix-keypad"
- row-gpios:		List of gpios used as row lines. The gpio specifier
			for this property depends on the gpio controller to
			which these row lines are connected.
- col-gpios:		List of gpios used as column lines. The gpio specifier
			for this property depends on the gpio controller to
			which these column lines are connected.
- linux,keymap:		The definition can be found at
			bindings/input/matrix-keymap.txt

Optional Properties:
- linux,no-autorepeat:	do no enable autorepeat feature.
- wakeup-source:	use any event on keypad as wakeup event.
			(Legacy property supported: "linux,wakeup")
- debounce-delay-ms:	debounce interval in milliseconds
- col-scan-delay-us:	delay, measured in microseconds, that is needed
			before we can scan keypad after activating column gpio
- drive-inactive-cols:	drive inactive columns during scan,
			default is to turn inactive columns into inputs.

Example:
	matrix-keypad {
		compatible = "gpio-matrix-keypad";
		debounce-delay-ms = <5>;
		col-scan-delay-us = <2>;

		row-gpios = <&gpio2 25 0
			     &gpio2 26 0
			     &gpio2 27 0>;

		col-gpios = <&gpio2 21 0
			     &gpio2 22 0>;

		linux,keymap = <0x0000008B
				0x0100009E
				0x02000069
				0x0001006A
				0x0101001C
				0x0201006C>;
	};
+103 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---

$id: http://devicetree.org/schemas/input/gpio-matrix-keypad.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: GPIO matrix keypad

maintainers:
  - Marek Vasut <marek.vasut@gmail.com>

description:
  GPIO driven matrix keypad is used to interface a SoC with a matrix keypad.
  The matrix keypad supports multiple row and column lines, a key can be
  placed at each intersection of a unique row and a unique column. The matrix
  keypad can sense a key-press and key-release by means of GPIO lines and
  report the event using GPIO interrupts to the cpu.

allOf:
  - $ref: /schemas/input/matrix-keymap.yaml#

properties:
  compatible:
    const: gpio-matrix-keypad

  row-gpios:
    description:
      List of GPIOs used as row lines. The gpio specifier for this property
      depends on the gpio controller to which these row lines are connected.

  col-gpios:
    description:
      List of GPIOs used as column lines. The gpio specifier for this property
      depends on the gpio controller to which these column lines are connected.

  linux,keymap: true

  linux,no-autorepeat:
    type: boolean
    description: Do not enable autorepeat feature.

  gpio-activelow:
    type: boolean
    description:
      Force GPIO polarity to active low.
      In the absence of this property GPIOs are treated as active high.

  debounce-delay-ms:
    description: Debounce interval in milliseconds.
    default: 0

  col-scan-delay-us:
    description:
      Delay, measured in microseconds, that is needed
      before we can scan keypad after activating column gpio.
    default: 0

  all-cols-on-delay-us:
    description:
      Delay, measured in microseconds, that is needed
      after activating all column gpios.
    default: 0

  drive-inactive-cols:
    type: boolean
    description:
      Drive inactive columns during scan,
      default is to turn inactive columns into inputs.

  wakeup-source: true

required:
  - compatible
  - row-gpios
  - col-gpios
  - linux,keymap

additionalProperties: false

examples:
  - |
    matrix-keypad {
        compatible = "gpio-matrix-keypad";
        debounce-delay-ms = <5>;
        col-scan-delay-us = <2>;

        row-gpios = <&gpio2 25 0
                     &gpio2 26 0
                     &gpio2 27 0>;

        col-gpios = <&gpio2 21 0
                     &gpio2 22 0>;

        linux,keymap = <0x0000008B
                        0x0100009E
                        0x02000069
                        0x0001006A
                        0x0101001C
                        0x0201006C>;

        wakeup-source;
    };
+70 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/input/touchscreen/apple,z2-multitouch.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Apple touchscreens attached using the Z2 protocol

maintainers:
  - Sasha Finkelstein <fnkl.kernel@gmail.com>

description: A series of touschscreen controllers used in Apple products

allOf:
  - $ref: touchscreen.yaml#
  - $ref: /schemas/spi/spi-peripheral-props.yaml#

properties:
  compatible:
    enum:
      - apple,j293-touchbar
      - apple,j493-touchbar

  interrupts:
    maxItems: 1

  reset-gpios:
    maxItems: 1

  firmware-name:
    maxItems: 1

  apple,z2-cal-blob:
    $ref: /schemas/types.yaml#/definitions/uint8-array
    maxItems: 4096
    description:
      Calibration blob supplied by the bootloader

required:
  - compatible
  - interrupts
  - reset-gpios
  - firmware-name
  - touchscreen-size-x
  - touchscreen-size-y

unevaluatedProperties: false

examples:
  - |
    #include <dt-bindings/gpio/gpio.h>
    #include <dt-bindings/interrupt-controller/irq.h>

    spi {
        #address-cells = <1>;
        #size-cells = <0>;

        touchscreen@0 {
            compatible = "apple,j293-touchbar";
            reg = <0>;
            spi-max-frequency = <11500000>;
            reset-gpios = <&pinctrl_ap 139 GPIO_ACTIVE_LOW>;
            interrupts-extended = <&pinctrl_ap 194 IRQ_TYPE_EDGE_FALLING>;
            firmware-name = "apple/dfrmtfw-j293.bin";
            touchscreen-size-x = <23045>;
            touchscreen-size-y = <640>;
        };
    };

...
+1 −0
Original line number Diff line number Diff line
@@ -19,6 +19,7 @@ allOf:
properties:
  compatible:
    enum:
      - goodix,gt9897
      - goodix,gt9916

  reg:
+1 −1
Original line number Diff line number Diff line
@@ -23,7 +23,7 @@ List of legacy properties and respective binding document

1. "gpio-key,wakeup"		Documentation/devicetree/bindings/input/gpio-keys{,-polled}.txt
2. "has-tpo"			Documentation/devicetree/bindings/rtc/rtc-opal.txt
3. "linux,wakeup"		Documentation/devicetree/bindings/input/gpio-matrix-keypad.txt
3. "linux,wakeup"		Documentation/devicetree/bindings/input/gpio-matrix-keypad.yaml
				Documentation/devicetree/bindings/mfd/tc3589x.txt
				Documentation/devicetree/bindings/input/touchscreen/ti,ads7843.yaml
4. "linux,keypad-wakeup"	Documentation/devicetree/bindings/input/qcom,pm8921-keypad.yaml
Loading