Skip to content

Commit 882d6ed

Browse files
committed
Merge tag 'gpio-updates-for-v5.12' of git://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux
Pull gpio updates from Bartosz Golaszewski: "It's been a relatively calm release cycle and we're actually removing more code than we're adding. Summary: - new driver for the Toshiba Visconti platform - rework of interrupt handling in gpio-tegra - updates for GPIO selftests: we're now using the character device to perform the subsystem checks - support for a new rcar variant + some code refactoring - refactoring of gpio-ep93xx - SPDX License identifier has been updated in the uapi header so that userspace programs bundling it can become fully REUSE-compliant - improvements to pwm handling in gpio-mvebu - support for interrupt handling and power management for gpio-xilinx as well as some code refactoring - support for a new chip variant in gpio-pca953x - removal of drivers: zte xs & intel-mid and removal of leftovers from intel-msic - impovements to intel drivers pulled from Andy Shevchenko - improvements to the gpio-aggregator virtual GPIO driver - and several minor tweaks and fixes to code and documentation all over the place" * tag 'gpio-updates-for-v5.12' of git://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux: (71 commits) gpio: pcf857x: Fix missing first interrupt gpio: ep93xx: refactor base IRQ number gpio: ep93xx: refactor ep93xx_gpio_add_bank gpio: ep93xx: Fix typo s/hierarchial/hierarchical gpio: ep93xx: drop to_irq binding gpio: ep93xx: Fix wrong irq numbers in port F gpio: uapi: use the preferred SPDX license identifier gpio: gpio-xilinx: Add check if width exceeds 32 gpio: gpio-xilinx: Add support for suspend and resume gpio: gpio-xilinx: Add interrupt support gpio: gpio-xilinx: Reduce spinlock array to array gpio: gpio-xilinx: Simplify with dev_err_probe() gpio: msic: Drop driver from Makefile gpio: wcove: Split out to_ireg() helper and deduplicate the code gpio: wcove: Switch to use regmap_set_bits(), regmap_clear_bits() gpio: wcove: Get rid of error prone casting in IRQ handler gpio: intel-mid: Remove driver for deprecated platform gpio: msic: Remove driver for deprecated platform gpio: aggregator: Remove trailing comma in terminator entries gpio: aggregator: Use compound literal from the header ...
2 parents 0328b5f + a8002a3 commit 882d6ed

Some content is hidden

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

44 files changed

+1811
-1397
lines changed

Documentation/devicetree/bindings/arm/marvell/ap80x-system-controller.txt

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,11 @@ Required properties:
8080

8181
- offset: offset address inside the syscon block
8282

83+
Optional properties:
84+
85+
- marvell,pwm-offset: offset address of PWM duration control registers inside
86+
the syscon block
87+
8388
Example:
8489
ap_syscon: system-controller@6f4000 {
8590
compatible = "syscon", "simple-mfd";
@@ -101,6 +106,9 @@ ap_syscon: system-controller@6f4000 {
101106
gpio-controller;
102107
#gpio-cells = <2>;
103108
gpio-ranges = <&ap_pinctrl 0 0 19>;
109+
marvell,pwm-offset = <0x10c0>;
110+
#pwm-cells = <2>;
111+
clocks = <&ap_clk 3>;
104112
};
105113
};
106114

Documentation/devicetree/bindings/gpio/gpio-davinci.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ Required Properties:
77
"ti,k2g-gpio", "ti,keystone-gpio": for 66AK2G
88
"ti,am654-gpio", "ti,keystone-gpio": for TI K3 AM654
99
"ti,j721e-gpio", "ti,keystone-gpio": for J721E SoCs
10+
"ti,am64-gpio", "ti,keystone-gpio": for AM64 SoCs
1011

1112
- reg: Physical base address of the controller and the size of memory mapped
1213
registers.

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

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ properties:
3232
- maxim,max7327
3333
- nxp,pca6416
3434
- nxp,pca9505
35+
- nxp,pca9506
3536
- nxp,pca9534
3637
- nxp,pca9535
3738
- nxp,pca9536
@@ -70,7 +71,7 @@ properties:
7071

7172
gpio-line-names:
7273
minItems: 1
73-
maxItems: 32
74+
maxItems: 40
7475

7576
interrupts:
7677
maxItems: 1

Documentation/devicetree/bindings/gpio/renesas,rcar-gpio.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,9 @@ properties:
4848
- renesas,gpio-r8a77995 # R-Car D3
4949
- const: renesas,rcar-gen3-gpio # R-Car Gen3 or RZ/G2
5050

51+
- items:
52+
- const: renesas,gpio-r8a779a0 # R-Car V3U
53+
5154
reg:
5255
maxItems: 1
5356

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
2+
%YAML 1.2
3+
---
4+
$id: http://devicetree.org/schemas/gpio/toshiba,gpio-visconti.yaml#
5+
$schema: http://devicetree.org/meta-schemas/core.yaml#
6+
7+
title: Toshiba Visconti ARM SoCs GPIO controller
8+
9+
maintainers:
10+
- Nobuhiro Iwamatsu <[email protected]>
11+
12+
properties:
13+
compatible:
14+
items:
15+
- const: toshiba,gpio-tmpv7708
16+
17+
reg:
18+
maxItems: 1
19+
20+
"#gpio-cells":
21+
const: 2
22+
23+
gpio-ranges: true
24+
25+
gpio-controller: true
26+
27+
interrupt-controller: true
28+
29+
"#interrupt-cells":
30+
const: 2
31+
32+
interrupts:
33+
description:
34+
interrupt mapping one per GPIO.
35+
minItems: 16
36+
maxItems: 16
37+
38+
required:
39+
- compatible
40+
- reg
41+
- "#gpio-cells"
42+
- gpio-ranges
43+
- gpio-controller
44+
- interrupt-controller
45+
- "#interrupt-cells"
46+
- interrupt-parent
47+
48+
additionalProperties: false
49+
50+
examples:
51+
- |
52+
#include <dt-bindings/interrupt-controller/irq.h>
53+
#include <dt-bindings/interrupt-controller/arm-gic.h>
54+
55+
soc {
56+
#address-cells = <2>;
57+
#size-cells = <2>;
58+
59+
gpio: gpio@28020000 {
60+
compatible = "toshiba,gpio-tmpv7708";
61+
reg = <0 0x28020000 0 0x1000>;
62+
#gpio-cells = <0x2>;
63+
gpio-ranges = <&pmux 0 0 32>;
64+
gpio-controller;
65+
interrupt-controller;
66+
#interrupt-cells = <2>;
67+
interrupt-parent = <&gic>;
68+
};
69+
};
70+
...

Documentation/devicetree/bindings/gpio/zx296702-gpio.txt

Lines changed: 0 additions & 24 deletions
This file was deleted.

Documentation/driver-api/gpio/consumer.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -361,12 +361,13 @@ corresponding chip driver. In that case a significantly improved performance
361361
can be expected. If simultaneous access is not possible the GPIOs will be
362362
accessed sequentially.
363363

364-
The functions take three arguments:
364+
The functions take four arguments:
365+
365366
* array_size - the number of array elements
366367
* desc_array - an array of GPIO descriptors
367368
* array_info - optional information obtained from gpiod_get_array()
368369
* value_bitmap - a bitmap to store the GPIOs' values (get) or
369-
a bitmap of values to assign to the GPIOs (set)
370+
a bitmap of values to assign to the GPIOs (set)
370371

371372
The descriptor array can be obtained using the gpiod_get_array() function
372373
or one of its variants. If the group of descriptors returned by that function

Documentation/driver-api/gpio/intro.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -106,11 +106,11 @@ don't. When you need open drain signaling but your hardware doesn't directly
106106
support it, there's a common idiom you can use to emulate it with any GPIO pin
107107
that can be used as either an input or an output:
108108

109-
LOW: gpiod_direction_output(gpio, 0) ... this drives the signal and overrides
110-
the pullup.
109+
**LOW**: ``gpiod_direction_output(gpio, 0)`` ... this drives the signal and
110+
overrides the pullup.
111111

112-
HIGH: gpiod_direction_input(gpio) ... this turns off the output, so the pullup
113-
(or some other device) controls the signal.
112+
**HIGH**: ``gpiod_direction_input(gpio)`` ... this turns off the output, so
113+
the pullup (or some other device) controls the signal.
114114

115115
The same logic can be applied to emulate open source signaling, by driving the
116116
high signal and configuring the GPIO as input for low. This open drain/open

MAINTAINERS

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2609,10 +2609,12 @@ S: Supported
26092609
T: git git://git.kernel.org/pub/scm/linux/kernel/git/iwamatsu/linux-visconti.git
26102610
F: Documentation/devicetree/bindings/arm/toshiba.yaml
26112611
F: Documentation/devicetree/bindings/net/toshiba,visconti-dwmac.yaml
2612+
F: Documentation/devicetree/bindings/gpio/toshiba,gpio-visconti.yaml
26122613
F: Documentation/devicetree/bindings/pinctrl/toshiba,tmpv7700-pinctrl.yaml
26132614
F: Documentation/devicetree/bindings/watchdog/toshiba,visconti-wdt.yaml
26142615
F: arch/arm64/boot/dts/toshiba/
26152616
F: drivers/net/ethernet/stmicro/stmmac/dwmac-visconti.c
2617+
F: drivers/gpio/gpio-visconti.c
26162618
F: drivers/pinctrl/visconti/
26172619
F: drivers/watchdog/visconti_wdt.c
26182620
N: visconti

drivers/gpio/Kconfig

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -487,11 +487,11 @@ config GPIO_PXA
487487
Say yes here to support the PXA GPIO device
488488

489489
config GPIO_RCAR
490-
tristate "Renesas R-Car GPIO"
490+
tristate "Renesas R-Car and RZ/G GPIO support"
491491
depends on ARCH_RENESAS || COMPILE_TEST
492492
select GPIOLIB_IRQCHIP
493493
help
494-
Say yes here to support GPIO on Renesas R-Car SoCs.
494+
Say yes here to support GPIO on Renesas R-Car or RZ/G SoCs.
495495

496496
config GPIO_RDA
497497
bool "RDA Micro GPIO controller support"
@@ -595,7 +595,7 @@ config GPIO_TB10X
595595
select OF_GPIO
596596

597597
config GPIO_TEGRA
598-
bool "NVIDIA Tegra GPIO support"
598+
tristate "NVIDIA Tegra GPIO support"
599599
default ARCH_TEGRA
600600
depends on ARCH_TEGRA || COMPILE_TEST
601601
depends on OF_GPIO
@@ -648,6 +648,16 @@ config GPIO_VF610
648648
help
649649
Say yes here to support Vybrid vf610 GPIOs.
650650

651+
config GPIO_VISCONTI
652+
tristate "Toshiba Visconti GPIO support"
653+
depends on ARCH_VISCONTI || COMPILE_TEST
654+
depends on OF_GPIO
655+
select GPIOLIB_IRQCHIP
656+
select GPIO_GENERIC
657+
select IRQ_DOMAIN_HIERARCHY
658+
help
659+
Say yes here to support GPIO on Tohisba Visconti.
660+
651661
config GPIO_VR41XX
652662
tristate "NEC VR4100 series General-purpose I/O Uint support"
653663
depends on CPU_VR41XX
@@ -670,7 +680,7 @@ config GPIO_WCD934X
670680
tristate "Qualcomm Technologies Inc WCD9340/WCD9341 gpio controller driver"
671681
depends on MFD_WCD934X && OF_GPIO
672682
help
673-
This driver is to supprot GPIO block found on the Qualcomm Technologies
683+
This driver is to support GPIO block found on the Qualcomm Technologies
674684
Inc WCD9340/WCD9341 Audio Codec.
675685

676686
config GPIO_XGENE
@@ -694,6 +704,8 @@ config GPIO_XGENE_SB
694704

695705
config GPIO_XILINX
696706
tristate "Xilinx GPIO support"
707+
select GPIOLIB_IRQCHIP
708+
depends on OF_GPIO
697709
help
698710
Say yes here to support the Xilinx FPGA GPIO device
699711

@@ -731,13 +743,6 @@ config GPIO_ZYNQ
731743
help
732744
Say yes here to support Xilinx Zynq GPIO controller.
733745

734-
config GPIO_ZX
735-
bool "ZTE ZX GPIO support"
736-
depends on ARCH_ZX || COMPILE_TEST
737-
select GPIOLIB_IRQCHIP
738-
help
739-
Say yes here to support the GPIO device on ZTE ZX SoCs.
740-
741746
config GPIO_LOONGSON1
742747
tristate "Loongson1 GPIO support"
743748
depends on MACH_LOONGSON32
@@ -1623,8 +1628,7 @@ config GPIO_MOCKUP
16231628
select IRQ_SIM
16241629
help
16251630
This enables GPIO Testing driver, which provides a way to test GPIO
1626-
subsystem through sysfs(or char device) and debugfs. GPIO_SYSFS
1627-
must be selected for this test.
1631+
subsystem through sysfs (or char device) and debugfs.
16281632
User could use it through the script in
16291633
tools/testing/selftests/gpio/gpio-mockup.sh. Reference the usage in
16301634
it.

0 commit comments

Comments
 (0)