Skip to content

Commit d701782

Browse files
committed
Merge tag 'gpio-updates-for-v7.0-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux
Pull gpio updates from Bartosz Golaszewski: "There are two new drivers and some changes to GPIO core but mostly just GPIO driver updates across a wide array of files, adding support for new models as well as various refactoring changes. Nothing controversial and everything has spent a good measure of time in linux-next. GPIOLIB core: - shrink the GPIO bus driver stub code - rework software node support for "undefined" software nodes - provide and use devm_fwnode_gpiod_get_optional() - only compile the OF quirk for MT2701 when needed New drivers: - add the GPIO driver for ROHM bd72720 - add the gpio-line-mux driver providing 1-to-many mapping for a single real GPIO Driver changes: - refactor gpio-pca9570: use lock guard, add missing headers, use devres consistently - add support for a new model (G7 Aspeed sgpiom) to the aspeed-sgpio driver along with some prerequisite refactoring - use device_get_match_data() where applicable and save some lines - add support for more models to gpio-cadence - add the compatible property to reset-gpio and use it in shared GPIO management - drop unnecessary use of irqd_get_trigger_type() in gpio-max77759 - add support for a new variant to gpio-pca953x - extend build coverage with COMPILE_TEST for more drivers - constify configfs structures in gpio-sim and gpio-virtuser - add support for the K3 SoC to gpio-spacemit - implement the missing .get_direction() callback in gpio-max77620 - add support for Tegra264 to gpio-tegra186 - drop unneeded MODULE_ALIAS() from gpio-menz127 DT bindings: - document support for the opencores GPIO controller in gpio-mmio - document new variants for gpio-pca953x Documentation: - extensively describe interrupt source detection for gpio-pca953x and add more models to the list of supported variants" * tag 'gpio-updates-for-v7.0-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux: (59 commits) gpio: tegra186: Add support for Tegra264 dt-bindings: gpio: Add Tegra264 support gpio: spacemit-k1: Use PDR for pin direction, not SDR/CDR gpio: max77620: Implement .get_direction() callback gpio: aspeed-sgpio: Support G7 Aspeed sgpiom controller dt-bindings: gpio: aspeed,sgpio: Support ast2700 gpio: aspeed-sgpio: Convert IRQ functions to use llops callbacks gpio: aspeed-sgpio: Create llops to handle hardware access gpio: aspeed-sgpio: Remove unused bank name field gpio: aspeed-sgpio: Change the macro to support deferred probe regulator: bd71815: switch to devm_fwnode_gpiod_get_optional gpiolib: introduce devm_fwnode_gpiod_get_optional() wrapper gpio: mmio: Add compatible for opencores GPIO dt-bindings: gpio-mmio: Correct opencores GPIO gpio: pca9570: use lock guards gpio: pca9570: Don't use "proxy" headers gpio: pca9570: Use devm_mutex_init() for mutex initialization MAINTAINERS: Add ROHM BD72720 PMIC power: supply: bd71828-power: Support ROHM BD72720 power: supply: bd71828: Support wider register addresses ...
2 parents 893ace4 + af9b4a5 commit d701782

51 files changed

Lines changed: 4170 additions & 430 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

Documentation/devicetree/bindings/gpio/aspeed,sgpio.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@ maintainers:
1010
- Andrew Jeffery <andrew@aj.id.au>
1111

1212
description:
13-
This SGPIO controller is for ASPEED AST2400, AST2500 and AST2600 SoC,
13+
This SGPIO controller is for ASPEED AST2400, AST2500, AST2600 and AST2700 SoC,
14+
AST2700 have two sgpio master both with 256 pins,
1415
AST2600 have two sgpio master one with 128 pins another one with 80 pins,
1516
AST2500/AST2400 have one sgpio master with 80 pins. Each of the Serial
1617
GPIO pins can be programmed to support the following options
@@ -27,6 +28,7 @@ properties:
2728
- aspeed,ast2400-sgpio
2829
- aspeed,ast2500-sgpio
2930
- aspeed,ast2600-sgpiom
31+
- aspeed,ast2700-sgpiom
3032

3133
reg:
3234
maxItems: 1
Lines changed: 107 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,107 @@
1+
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2+
%YAML 1.2
3+
---
4+
$id: http://devicetree.org/schemas/gpio/gpio-line-mux.yaml#
5+
$schema: http://devicetree.org/meta-schemas/core.yaml#
6+
7+
title: GPIO line mux
8+
9+
maintainers:
10+
- Jonas Jelonek <jelonek.jonas@gmail.com>
11+
12+
description: |
13+
A GPIO controller to provide virtual GPIOs for a 1-to-many input-only mapping
14+
backed by a single shared GPIO and a multiplexer. A simple illustrated
15+
example is:
16+
17+
+----- A
18+
IN /
19+
<-----o------- B
20+
/ |\
21+
| | +----- C
22+
| | \
23+
| | +--- D
24+
| |
25+
M1 M0
26+
27+
MUX CONTROL
28+
29+
M1 M0 IN
30+
0 0 A
31+
0 1 B
32+
1 0 C
33+
1 1 D
34+
35+
This can be used in case a real GPIO is connected to multiple inputs and
36+
controlled by a multiplexer, and another subsystem/driver does not work
37+
directly with the multiplexer subsystem.
38+
39+
properties:
40+
compatible:
41+
const: gpio-line-mux
42+
43+
gpio-controller: true
44+
45+
"#gpio-cells":
46+
const: 2
47+
48+
gpio-line-mux-states:
49+
description: Mux states corresponding to the virtual GPIOs.
50+
$ref: /schemas/types.yaml#/definitions/uint32-array
51+
52+
gpio-line-names: true
53+
54+
mux-controls:
55+
maxItems: 1
56+
description:
57+
Phandle to the multiplexer to control access to the GPIOs.
58+
59+
ngpios: false
60+
61+
muxed-gpios:
62+
maxItems: 1
63+
description:
64+
GPIO which is the '1' in 1-to-many and is shared by the virtual GPIOs
65+
and controlled via the mux.
66+
67+
required:
68+
- compatible
69+
- gpio-controller
70+
- gpio-line-mux-states
71+
- mux-controls
72+
- muxed-gpios
73+
74+
additionalProperties: false
75+
76+
examples:
77+
- |
78+
#include <dt-bindings/gpio/gpio.h>
79+
#include <dt-bindings/mux/mux.h>
80+
81+
sfp_gpio_mux: mux-controller-1 {
82+
compatible = "gpio-mux";
83+
mux-gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>,
84+
<&gpio0 1 GPIO_ACTIVE_HIGH>;
85+
#mux-control-cells = <0>;
86+
idle-state = <MUX_IDLE_AS_IS>;
87+
};
88+
89+
sfp1_gpio: sfp-gpio-1 {
90+
compatible = "gpio-line-mux";
91+
gpio-controller;
92+
#gpio-cells = <2>;
93+
94+
mux-controls = <&sfp_gpio_mux>;
95+
muxed-gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>;
96+
97+
gpio-line-mux-states = <0>, <1>, <3>;
98+
};
99+
100+
sfp1: sfp-p1 {
101+
compatible = "sff,sfp";
102+
103+
i2c-bus = <&sfp1_i2c>;
104+
los-gpios = <&sfp1_gpio 0 GPIO_ACTIVE_HIGH>;
105+
mod-def0-gpios = <&sfp1_gpio 1 GPIO_ACTIVE_LOW>;
106+
tx-fault-gpios = <&sfp1_gpio 2 GPIO_ACTIVE_HIGH>;
107+
};

Documentation/devicetree/bindings/gpio/gpio-mmio.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,10 @@ properties:
2020
compatible:
2121
enum:
2222
- brcm,bcm6345-gpio
23+
- intel,ixp4xx-expansion-bus-mmio-gpio
2324
- ni,169445-nand-gpio
25+
- opencores,gpio
2426
- wd,mbl-gpio # Western Digital MyBook Live memory-mapped GPIO controller
25-
- intel,ixp4xx-expansion-bus-mmio-gpio
2627

2728
big-endian: true
2829

Documentation/devicetree/bindings/gpio/gpio-pca95xx.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,8 @@ properties:
7474
- ti,tca9538
7575
- ti,tca9539
7676
- ti,tca9554
77+
- ti,tcal6408
78+
- ti,tcal6416
7779

7880
reg:
7981
maxItems: 1

Documentation/devicetree/bindings/gpio/nvidia,tegra186-gpio.yaml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,9 @@ properties:
8686
- nvidia,tegra234-gpio
8787
- nvidia,tegra234-gpio-aon
8888
- nvidia,tegra256-gpio
89+
- nvidia,tegra264-gpio
90+
- nvidia,tegra264-gpio-uphy
91+
- nvidia,tegra264-gpio-aon
8992

9093
reg-names:
9194
items:
@@ -110,6 +113,10 @@ properties:
110113
ports, in the order the HW manual describes them. The number of entries
111114
required varies depending on compatible value.
112115

116+
wakeup-parent:
117+
description: Phandle to the parent interrupt controller used for wake-up. On
118+
Tegra, this typically references the PMC interrupt controller.
119+
113120
gpio-controller: true
114121

115122
gpio-ranges:
@@ -157,6 +164,8 @@ allOf:
157164
- nvidia,tegra194-gpio
158165
- nvidia,tegra234-gpio
159166
- nvidia,tegra256-gpio
167+
- nvidia,tegra264-gpio
168+
- nvidia,tegra264-gpio-uphy
160169
then:
161170
properties:
162171
interrupts:
@@ -171,12 +180,25 @@ allOf:
171180
- nvidia,tegra186-gpio-aon
172181
- nvidia,tegra194-gpio-aon
173182
- nvidia,tegra234-gpio-aon
183+
- nvidia,tegra264-gpio-aon
174184
then:
175185
properties:
176186
interrupts:
177187
minItems: 1
178188
maxItems: 4
179189

190+
- if:
191+
properties:
192+
compatible:
193+
contains:
194+
enum:
195+
- nvidia,tegra264-gpio
196+
- nvidia,tegra264-gpio-uphy
197+
- nvidia,tegra264-gpio-aon
198+
then:
199+
required:
200+
- wakeup-parent
201+
180202
required:
181203
- compatible
182204
- reg

Documentation/devicetree/bindings/gpio/spacemit,k1-gpio.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,9 @@ properties:
1919
pattern: "^gpio@[0-9a-f]+$"
2020

2121
compatible:
22-
const: spacemit,k1-gpio
22+
enum:
23+
- spacemit,k1-gpio
24+
- spacemit,k3-gpio
2325

2426
reg:
2527
maxItems: 1

Documentation/devicetree/bindings/leds/rohm,bd71828-leds.yaml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,12 @@ maintainers:
1010
- Matti Vaittinen <mazziesaccount@gmail.com>
1111

1212
description: |
13-
This module is part of the ROHM BD71828 MFD device. For more details
14-
see Documentation/devicetree/bindings/mfd/rohm,bd71828-pmic.yaml.
13+
This module is part of the ROHM BD71828 and BD72720 MFD device. For more
14+
details see Documentation/devicetree/bindings/mfd/rohm,bd71828-pmic.yaml
15+
and Documentation/devicetree/bindings/mfd/rohm,bd72720-pmic.yaml
1516
1617
The LED controller is represented as a sub-node of the PMIC node on the device
17-
tree.
18+
tree. This should be located under "leds" - node in PMIC node.
1819
1920
The device has two LED outputs referred as GRNLED and AMBLED in data-sheet.
2021

0 commit comments

Comments
 (0)