mirror of
https://github.com/torvalds/linux.git
synced 2026-06-01 02:53:36 +02:00
dt-bindings: gpio: Convert STMPE GPIO to YAML schema
This rewrites the STMPE GPIO bindings to a YAML schema. We add the properties that are used in the widely used STMPE GPIO device nodes found in the wild, most notably interrupt support, so interrupt-cells and interrupt-controller is now part of the bindings. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
This commit is contained in:
parent
1c23553a66
commit
6c19974d1e
|
|
@ -1,17 +0,0 @@
|
|||
STMPE gpio
|
||||
----------
|
||||
|
||||
Required properties:
|
||||
- compatible: "st,stmpe-gpio"
|
||||
|
||||
Optional properties:
|
||||
- st,norequest-mask: bitmask specifying which GPIOs should _not_ be requestable
|
||||
due to different usage (e.g. touch, keypad)
|
||||
|
||||
Node should be child node of stmpe node to which it belongs.
|
||||
|
||||
Example:
|
||||
stmpe_gpio {
|
||||
compatible = "st,stmpe-gpio";
|
||||
st,norequest-mask = <0x20>; //gpio 5 can't be used
|
||||
};
|
||||
53
Documentation/devicetree/bindings/gpio/st,stmpe-gpio.yaml
Normal file
53
Documentation/devicetree/bindings/gpio/st,stmpe-gpio.yaml
Normal file
|
|
@ -0,0 +1,53 @@
|
|||
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
|
||||
%YAML 1.2
|
||||
---
|
||||
$id: http://devicetree.org/schemas/gpio/st,stmpe-gpio.yaml#
|
||||
$schema: http://devicetree.org/meta-schemas/core.yaml#
|
||||
|
||||
title: STMicroelectonics Port Expander (STMPE) GPIO Block
|
||||
|
||||
description:
|
||||
STMicroelectronics Port Expander (STMPE) is a series of slow
|
||||
bus controllers for various expanded peripherals such as GPIO, keypad,
|
||||
touchscreen, ADC, PWM or rotator. It can contain one or several different
|
||||
peripherals connected to SPI or I2C. These bindings pertain to the
|
||||
GPIO portions of these expanders.
|
||||
|
||||
maintainers:
|
||||
- Linus Walleij <linus.walleij@linaro.org>
|
||||
|
||||
properties:
|
||||
compatible:
|
||||
const: st,stmpe-gpio
|
||||
|
||||
"#gpio-cells":
|
||||
const: 2
|
||||
|
||||
"#interrupt-cells":
|
||||
const: 2
|
||||
|
||||
gpio-controller: true
|
||||
|
||||
interrupt-controller: true
|
||||
|
||||
st,norequest-mask:
|
||||
description:
|
||||
A bitmask of GPIO lines that cannot be requested because for
|
||||
for example not being connected to anything on the system
|
||||
$ref: /schemas/types.yaml#/definitions/uint32
|
||||
|
||||
patternProperties:
|
||||
"^.+-hog(-[0-9]+)?$":
|
||||
type: object
|
||||
|
||||
required:
|
||||
- gpio-hog
|
||||
|
||||
additionalProperties: false
|
||||
|
||||
required:
|
||||
- compatible
|
||||
- "#gpio-cells"
|
||||
- "#interrupt-cells"
|
||||
- gpio-controller
|
||||
- interrupt-controller
|
||||
Loading…
Reference in New Issue
Block a user