[PATCH v9 00/22] pinctrl: add BCM63XX pincontrol support
From: Álvaro Fernández Rojas
Date: Wed Mar 24 2021 - 04:20:42 EST
First of all, I've based this on the patches sent by Jonas Gorski back in
2016:
https://www.spinics.net/lists/linux-gpio/msg15983.html
http://patchwork.ozlabs.org/project/linux-gpio/patch/1471604025-21575-2-git-send-email-jonas.gorski@xxxxxxxxx/
I've tried to address all coments from Linus Walleij, but I know that
this may still need some other modifications
This patchset adds appropriate binding documentation and drivers for
pin controller cores found in the BCM63XX MIPS SoCs currently supported.
While the GPIO part is always the same, the pinmux part varies quite a
lot between different SoCs. Sometimes they have defined groups which
can be muxed into different functions, sometimes each function has a
different group. Sometimes you can mux individual pins. Often it is a
combination of single pins and groups.
Some core versions require the GPIO direction to be set according to the
function, most do not. Sometimes the mux register(s) contain bits for
unrelated other functions.
v9: introduce changes suggested by Rob Herring and Andy Shevchenko.
v8: introduce changes suggested by Rob Herring.
v7: introduce changes suggested by Rob Herring.
v6: introduce changes suggested by Rob Herring and Andy Shevchenko.
v5: introduce changes suggested by Andy Shevchenko.
v4: fix gpiochip_irqchip_add_domain(), remove IRQ Kconfig selections and add
missing of_node_put().
v3: introduce new files for shared code and add more changes suggested by
Linus Walleij. Also add a new patch needed for properly parsing gpio-ranges.
v2: introduce changes suggested by Linus Walleij and remove interrupts
- In order to use GPIO_REGMAP, the need to get gpio_chip from gpio_regmap
and use it for pinctrl_add_gpio_range() and gpio_chip.direction_input()
and gpio_chip.direction_output().
Álvaro Fernández Rojas (22):
gpio: guard gpiochip_irqchip_add_domain() with GPIOLIB_IRQCHIP
gpio: regmap: set gpio_chip of_node
dt-bindings: improve BCM6345 GPIO binding documentation
pinctrl: bcm: add bcm63xx base code
dt-bindings: add BCM6328 pincontroller binding documentation
dt-bindings: add BCM6328 GPIO sysctl binding documentation
pinctrl: add a pincontrol driver for BCM6328
dt-bindings: add BCM6358 pincontroller binding documentation
dt-bindings: add BCM6358 GPIO sysctl binding documentation
pinctrl: add a pincontrol driver for BCM6358
dt-bindings: add BCM6362 pincontroller binding documentation
dt-bindings: add BCM6362 GPIO sysctl binding documentation
pinctrl: add a pincontrol driver for BCM6362
dt-bindings: add BCM6368 pincontroller binding documentation
dt-bindings: add BCM6368 GPIO sysctl binding documentation
pinctrl: add a pincontrol driver for BCM6368
dt-bindings: add BCM63268 pincontroller binding documentation
dt-bindings: add BCM63268 GPIO sysctl binding documentation
pinctrl: add a pincontrol driver for BCM63268
dt-bindings: add BCM6318 pincontroller binding documentation
dt-bindings: add BCM6318 GPIO sysctl binding documentation
pinctrl: add a pincontrol driver for BCM6318
.../bindings/gpio/brcm,bcm6345-gpio.txt | 46 --
.../bindings/gpio/brcm,bcm6345-gpio.yaml | 86 +++
.../mfd/brcm,bcm6318-gpio-sysctl.yaml | 177 +++++
.../mfd/brcm,bcm63268-gpio-sysctl.yaml | 194 ++++++
.../mfd/brcm,bcm6328-gpio-sysctl.yaml | 162 +++++
.../mfd/brcm,bcm6358-gpio-sysctl.yaml | 130 ++++
.../mfd/brcm,bcm6362-gpio-sysctl.yaml | 236 +++++++
.../mfd/brcm,bcm6368-gpio-sysctl.yaml | 246 +++++++
.../pinctrl/brcm,bcm6318-pinctrl.yaml | 143 ++++
.../pinctrl/brcm,bcm63268-pinctrl.yaml | 164 +++++
.../pinctrl/brcm,bcm6328-pinctrl.yaml | 127 ++++
.../pinctrl/brcm,bcm6358-pinctrl.yaml | 93 +++
.../pinctrl/brcm,bcm6362-pinctrl.yaml | 206 ++++++
.../pinctrl/brcm,bcm6368-pinctrl.yaml | 217 ++++++
drivers/gpio/gpio-regmap.c | 5 +
drivers/pinctrl/bcm/Kconfig | 55 ++
drivers/pinctrl/bcm/Makefile | 7 +
drivers/pinctrl/bcm/pinctrl-bcm6318.c | 498 ++++++++++++++
drivers/pinctrl/bcm/pinctrl-bcm63268.c | 643 ++++++++++++++++++
drivers/pinctrl/bcm/pinctrl-bcm6328.c | 404 +++++++++++
drivers/pinctrl/bcm/pinctrl-bcm6358.c | 369 ++++++++++
drivers/pinctrl/bcm/pinctrl-bcm6362.c | 617 +++++++++++++++++
drivers/pinctrl/bcm/pinctrl-bcm6368.c | 523 ++++++++++++++
drivers/pinctrl/bcm/pinctrl-bcm63xx.c | 109 +++
drivers/pinctrl/bcm/pinctrl-bcm63xx.h | 43 ++
include/linux/gpio/driver.h | 9 +
include/linux/gpio/regmap.h | 4 +
27 files changed, 5467 insertions(+), 46 deletions(-)
delete mode 100644 Documentation/devicetree/bindings/gpio/brcm,bcm6345-gpio.txt
create mode 100644 Documentation/devicetree/bindings/gpio/brcm,bcm6345-gpio.yaml
create mode 100644 Documentation/devicetree/bindings/mfd/brcm,bcm6318-gpio-sysctl.yaml
create mode 100644 Documentation/devicetree/bindings/mfd/brcm,bcm63268-gpio-sysctl.yaml
create mode 100644 Documentation/devicetree/bindings/mfd/brcm,bcm6328-gpio-sysctl.yaml
create mode 100644 Documentation/devicetree/bindings/mfd/brcm,bcm6358-gpio-sysctl.yaml
create mode 100644 Documentation/devicetree/bindings/mfd/brcm,bcm6362-gpio-sysctl.yaml
create mode 100644 Documentation/devicetree/bindings/mfd/brcm,bcm6368-gpio-sysctl.yaml
create mode 100644 Documentation/devicetree/bindings/pinctrl/brcm,bcm6318-pinctrl.yaml
create mode 100644 Documentation/devicetree/bindings/pinctrl/brcm,bcm63268-pinctrl.yaml
create mode 100644 Documentation/devicetree/bindings/pinctrl/brcm,bcm6328-pinctrl.yaml
create mode 100644 Documentation/devicetree/bindings/pinctrl/brcm,bcm6358-pinctrl.yaml
create mode 100644 Documentation/devicetree/bindings/pinctrl/brcm,bcm6362-pinctrl.yaml
create mode 100644 Documentation/devicetree/bindings/pinctrl/brcm,bcm6368-pinctrl.yaml
create mode 100644 drivers/pinctrl/bcm/pinctrl-bcm6318.c
create mode 100644 drivers/pinctrl/bcm/pinctrl-bcm63268.c
create mode 100644 drivers/pinctrl/bcm/pinctrl-bcm6328.c
create mode 100644 drivers/pinctrl/bcm/pinctrl-bcm6358.c
create mode 100644 drivers/pinctrl/bcm/pinctrl-bcm6362.c
create mode 100644 drivers/pinctrl/bcm/pinctrl-bcm6368.c
create mode 100644 drivers/pinctrl/bcm/pinctrl-bcm63xx.c
create mode 100644 drivers/pinctrl/bcm/pinctrl-bcm63xx.h
--
2.20.1