Skip to content

Commit

Permalink
Merge branch 'ib-nomadik-gpio' into devel
Browse files Browse the repository at this point in the history
  • Loading branch information
linusw committed Mar 7, 2024
2 parents 52279c3 + a0c807b commit 64df5ea
Show file tree
Hide file tree
Showing 11 changed files with 1,104 additions and 863 deletions.
31 changes: 0 additions & 31 deletions Documentation/devicetree/bindings/gpio/gpio-nmk.txt

This file was deleted.

95 changes: 95 additions & 0 deletions Documentation/devicetree/bindings/gpio/st,nomadik-gpio.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/gpio/st,nomadik-gpio.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Nomadik GPIO controller

description:
The Nomadik GPIO driver handles Nomadik SoC GPIO blocks. This block has also
been called ST STA2X11. On the Nomadik platform, this driver is intertwined
with pinctrl-nomadik.

maintainers:
- Linus Walleij <[email protected]>

properties:
$nodename:
pattern: "^gpio@[0-9a-f]+$"

compatible:
enum:
- st,nomadik-gpio
- mobileye,eyeq5-gpio

reg:
maxItems: 1

interrupts:
maxItems: 1

"#gpio-cells":
const: 2

gpio-controller: true

interrupt-controller: true

"#interrupt-cells":
const: 2

gpio-bank:
description: System-wide GPIO bank index.
$ref: /schemas/types.yaml#/definitions/uint32

st,supports-sleepmode:
description: Whether the controller can sleep or not.
$ref: /schemas/types.yaml#/definitions/flag

clocks:
maxItems: 1

gpio-ranges:
maxItems: 1

ngpios:
minimum: 0
maximum: 32

resets:
maxItems: 1

required:
- compatible
- reg
- interrupts
- "#gpio-cells"
- gpio-controller
- interrupt-controller
- gpio-bank

unevaluatedProperties: false

allOf:
- if:
properties:
compatible:
contains:
const: mobileye,eyeq5-gpio
then:
properties:
st,supports-sleepmode: false

examples:
- |
gpio@8012e080 {
compatible = "st,nomadik-gpio";
reg = <0x8012e080 0x80>;
interrupts = <0 120 0x4>;
#gpio-cells = <2>;
gpio-controller;
interrupt-controller;
st,supports-sleepmode;
gpio-bank = <1>;
};
2 changes: 2 additions & 0 deletions MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -2465,6 +2465,7 @@ T: git git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-nomadik.git
F: Documentation/devicetree/bindings/arm/ste-*
F: Documentation/devicetree/bindings/arm/ux500.yaml
F: Documentation/devicetree/bindings/arm/ux500/
F: Documentation/devicetree/bindings/gpio/st,nomadik-gpio.yaml
F: Documentation/devicetree/bindings/i2c/st,nomadik-i2c.yaml
F: arch/arm/boot/dts/st/ste-*
F: arch/arm/mach-nomadik/
Expand All @@ -2473,6 +2474,7 @@ F: drivers/clk/clk-nomadik.c
F: drivers/clocksource/clksrc-dbx500-prcmu.c
F: drivers/dma/ste_dma40*
F: drivers/pmdomain/st/ste-ux500-pm-domain.c
F: drivers/gpio/gpio-nomadik.c
F: drivers/hwspinlock/u8500_hsem.c
F: drivers/i2c/busses/i2c-nomadik.c
F: drivers/iio/adc/ab8500-gpadc.c
Expand Down
12 changes: 12 additions & 0 deletions drivers/gpio/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -478,6 +478,18 @@ config GPIO_MXS
select GPIO_GENERIC
select GENERIC_IRQ_CHIP

config GPIO_NOMADIK
bool "Nomadik GPIO driver"
depends on ARCH_U8500 || ARCH_NOMADIK || MACH_EYEQ5 || COMPILE_TEST
select GPIOLIB_IRQCHIP
help
Say yes here to support the Nomadik SoC GPIO block. This block is also
used by the Mobileye EyeQ5 SoC.

It handles up to 32 GPIOs per bank, that can all be interrupt sources.
It is deeply interconnected with the associated pinctrl driver as GPIO
registers handle muxing ("alternate functions") as well.

config GPIO_NPCM_SGPIO
bool "Nuvoton SGPIO support"
depends on ARCH_NPCM || COMPILE_TEST
Expand Down
1 change: 1 addition & 0 deletions drivers/gpio/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ obj-$(CONFIG_GPIO_MT7621) += gpio-mt7621.o
obj-$(CONFIG_GPIO_MVEBU) += gpio-mvebu.o
obj-$(CONFIG_GPIO_MXC) += gpio-mxc.o
obj-$(CONFIG_GPIO_MXS) += gpio-mxs.o
obj-$(CONFIG_GPIO_NOMADIK) += gpio-nomadik.o
obj-$(CONFIG_GPIO_NPCM_SGPIO) += gpio-npcm-sgpio.o
obj-$(CONFIG_GPIO_OCTEON) += gpio-octeon.o
obj-$(CONFIG_GPIO_OMAP) += gpio-omap.o
Expand Down
Loading

0 comments on commit 64df5ea

Please sign in to comment.