.../devicetree/bindings/gpio/delta,tn48m-gpio.yaml | 39 -------- .../devicetree/bindings/mfd/delta,tn48m-cpld.yaml | 90 ------------------- MAINTAINERS | 9 -- drivers/gpio/Kconfig | 12 --- drivers/gpio/Makefile | 1 - drivers/gpio/gpio-tn48m.c | 100 --------------------- 6 files changed, 251 deletions(-)
The gpio-tn48m driver is useless without the simple-mfd parent, which is
not present in the kernel tree, so delete it and all references to it.
Also delete references to the (missing) mfd driver.
Fixes: b3dcb5de6209 ("gpio: Add Delta TN48M CPLD GPIO driver")
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
---
Based on v6.19-rc4.
Cc: Robert Marko <robert.marko@sartura.hr>
Cc: Linus Walleij <linusw@kernel.org>
Cc: Bartosz Golaszewski <brgl@kernel.org>
Cc: linux-gpio@vger.kernel.org
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Rob Herring <robh@kernel.org>
Cc: Krzysztof Kozlowski <krzk+dt@kernel.org>
Cc: Conor Dooley <conor+dt@kernel.org>
Cc: devicetree@vger.kernel.org
.../devicetree/bindings/gpio/delta,tn48m-gpio.yaml | 39 --------
.../devicetree/bindings/mfd/delta,tn48m-cpld.yaml | 90 -------------------
MAINTAINERS | 9 --
drivers/gpio/Kconfig | 12 ---
drivers/gpio/Makefile | 1 -
drivers/gpio/gpio-tn48m.c | 100 ---------------------
6 files changed, 251 deletions(-)
diff --git a/Documentation/devicetree/bindings/gpio/delta,tn48m-gpio.yaml b/Documentation/devicetree/bindings/gpio/delta,tn48m-gpio.yaml
deleted file mode 100644
index e3e668a12091..000000000000
--- a/Documentation/devicetree/bindings/gpio/delta,tn48m-gpio.yaml
+++ /dev/null
@@ -1,39 +0,0 @@
-# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
-%YAML 1.2
----
-$id: http://devicetree.org/schemas/gpio/delta,tn48m-gpio.yaml#
-$schema: http://devicetree.org/meta-schemas/core.yaml#
-
-title: Delta Networks TN48M CPLD GPIO controller
-
-maintainers:
- - Robert Marko <robert.marko@sartura.hr>
-
-description: |
- This module is part of the Delta TN48M multi-function device. For more
- details see ../mfd/delta,tn48m-cpld.yaml.
-
- Delta TN48M has an onboard Lattice CPLD that is used as an GPIO expander.
- It provides 12 pins in total, they are input-only or ouput-only type.
-
-properties:
- compatible:
- enum:
- - delta,tn48m-gpo
- - delta,tn48m-gpi
-
- reg:
- maxItems: 1
-
- "#gpio-cells":
- const: 2
-
- gpio-controller: true
-
-required:
- - compatible
- - reg
- - "#gpio-cells"
- - gpio-controller
-
-additionalProperties: false
diff --git a/Documentation/devicetree/bindings/mfd/delta,tn48m-cpld.yaml b/Documentation/devicetree/bindings/mfd/delta,tn48m-cpld.yaml
deleted file mode 100644
index d3b79140cce2..000000000000
--- a/Documentation/devicetree/bindings/mfd/delta,tn48m-cpld.yaml
+++ /dev/null
@@ -1,90 +0,0 @@
-# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
-%YAML 1.2
----
-$id: http://devicetree.org/schemas/mfd/delta,tn48m-cpld.yaml#
-$schema: http://devicetree.org/meta-schemas/core.yaml#
-
-title: Delta Networks TN48M CPLD controller
-
-maintainers:
- - Robert Marko <robert.marko@sartura.hr>
-
-description: |
- Lattice CPLD onboard the TN48M switches is used for system
- management.
-
- It provides information about the hardware model, revision,
- PSU status etc.
-
- It is also being used as a GPIO expander and reset controller
- for the switch MAC-s and other peripherals.
-
-properties:
- compatible:
- const: delta,tn48m-cpld
-
- reg:
- description:
- I2C device address.
- maxItems: 1
-
- "#address-cells":
- const: 1
-
- "#size-cells":
- const: 0
-
-required:
- - compatible
- - reg
- - "#address-cells"
- - "#size-cells"
-
-patternProperties:
- "^gpio(@[0-9a-f]+)?$":
- $ref: /schemas/gpio/delta,tn48m-gpio.yaml
-
- "^reset-controller?$":
- $ref: /schemas/reset/delta,tn48m-reset.yaml
-
-additionalProperties: false
-
-examples:
- - |
- i2c {
- #address-cells = <1>;
- #size-cells = <0>;
-
- cpld@41 {
- compatible = "delta,tn48m-cpld";
- reg = <0x41>;
- #address-cells = <1>;
- #size-cells = <0>;
-
- gpio@31 {
- compatible = "delta,tn48m-gpo";
- reg = <0x31>;
- gpio-controller;
- #gpio-cells = <2>;
- };
-
- gpio@3a {
- compatible = "delta,tn48m-gpi";
- reg = <0x3a>;
- gpio-controller;
- #gpio-cells = <2>;
- };
-
- gpio@40 {
- compatible = "delta,tn48m-gpi";
- reg = <0x40>;
- gpio-controller;
- #gpio-cells = <2>;
- };
-
- reset-controller {
- compatible = "delta,tn48m-reset";
- #reset-cells = <1>;
- };
- };
- };
diff --git a/MAINTAINERS b/MAINTAINERS
index 765ad2daa218..7d3c0d2375c8 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -7107,15 +7107,6 @@ S: Maintained
F: Documentation/hwmon/dps920ab.rst
F: drivers/hwmon/pmbus/dps920ab.c
-DELTA NETWORKS TN48M CPLD DRIVERS
-M: Robert Marko <robert.marko@sartura.hr>
-S: Maintained
-F: Documentation/devicetree/bindings/gpio/delta,tn48m-gpio.yaml
-F: Documentation/devicetree/bindings/mfd/delta,tn48m-cpld.yaml
-F: Documentation/devicetree/bindings/reset/delta,tn48m-reset.yaml
-F: drivers/gpio/gpio-tn48m.c
-F: include/dt-bindings/reset/delta,tn48m-reset.h
-
DELTA ST MEDIA DRIVER
M: Hugues Fruchet <hugues.fruchet@foss.st.com>
L: linux-media@vger.kernel.org
diff --git a/drivers/gpio/Kconfig b/drivers/gpio/Kconfig
index bd185482a7fd..d1d3f98b87f6 100644
--- a/drivers/gpio/Kconfig
+++ b/drivers/gpio/Kconfig
@@ -1619,18 +1619,6 @@ config GPIO_TIMBERDALE
help
Add support for the GPIO IP in the timberdale FPGA.
-config GPIO_TN48M_CPLD
- tristate "Delta Networks TN48M switch CPLD GPIO driver"
- depends on MFD_TN48M_CPLD || COMPILE_TEST
- select GPIO_REGMAP
- help
- This enables support for the GPIOs found on the Delta
- Networks TN48M switch Lattice CPLD. It provides 12 pins in total,
- they are input-only or output-only type.
-
- This driver can also be built as a module. If so, the
- module will be called gpio-tn48m.
-
config GPIO_TPS65086
tristate "TI TPS65086 GPO"
depends on MFD_TPS65086
diff --git a/drivers/gpio/Makefile b/drivers/gpio/Makefile
index 2421a8fd3733..c3ee30133c24 100644
--- a/drivers/gpio/Makefile
+++ b/drivers/gpio/Makefile
@@ -181,7 +181,6 @@ obj-$(CONFIG_GPIO_TEGRA186) += gpio-tegra186.o
obj-$(CONFIG_GPIO_TEGRA) += gpio-tegra.o
obj-$(CONFIG_GPIO_THUNDERX) += gpio-thunderx.o
obj-$(CONFIG_GPIO_TIMBERDALE) += gpio-timberdale.o
-obj-$(CONFIG_GPIO_TN48M_CPLD) += gpio-tn48m.o
obj-$(CONFIG_GPIO_TPIC2810) += gpio-tpic2810.o
obj-$(CONFIG_GPIO_TPS65086) += gpio-tps65086.o
obj-$(CONFIG_GPIO_TPS65218) += gpio-tps65218.o
diff --git a/drivers/gpio/gpio-tn48m.c b/drivers/gpio/gpio-tn48m.c
deleted file mode 100644
index cd4a80b22794..000000000000
--- a/drivers/gpio/gpio-tn48m.c
+++ /dev/null
@@ -1,100 +0,0 @@
-// SPDX-License-Identifier: GPL-2.0-only
-/*
- * Delta TN48M CPLD GPIO driver
- *
- * Copyright (C) 2021 Sartura Ltd.
- *
- * Author: Robert Marko <robert.marko@sartura.hr>
- */
-
-#include <linux/device.h>
-#include <linux/gpio/driver.h>
-#include <linux/gpio/regmap.h>
-#include <linux/mod_devicetable.h>
-#include <linux/module.h>
-#include <linux/platform_device.h>
-#include <linux/regmap.h>
-
-enum tn48m_gpio_type {
- TN48M_GP0 = 1,
- TN48M_GPI,
-};
-
-struct tn48m_gpio_config {
- int ngpio;
- int ngpio_per_reg;
- enum tn48m_gpio_type type;
-};
-
-static const struct tn48m_gpio_config tn48m_gpo_config = {
- .ngpio = 4,
- .ngpio_per_reg = 4,
- .type = TN48M_GP0,
-};
-
-static const struct tn48m_gpio_config tn48m_gpi_config = {
- .ngpio = 4,
- .ngpio_per_reg = 4,
- .type = TN48M_GPI,
-};
-
-static int tn48m_gpio_probe(struct platform_device *pdev)
-{
- const struct tn48m_gpio_config *gpio_config;
- struct gpio_regmap_config config = {};
- struct regmap *regmap;
- u32 base;
- int ret;
-
- if (!pdev->dev.parent)
- return -ENODEV;
-
- gpio_config = device_get_match_data(&pdev->dev);
- if (!gpio_config)
- return -ENODEV;
-
- ret = device_property_read_u32(&pdev->dev, "reg", &base);
- if (ret)
- return ret;
-
- regmap = dev_get_regmap(pdev->dev.parent, NULL);
- if (!regmap)
- return -ENODEV;
-
- config.regmap = regmap;
- config.parent = &pdev->dev;
- config.ngpio = gpio_config->ngpio;
- config.ngpio_per_reg = gpio_config->ngpio_per_reg;
- switch (gpio_config->type) {
- case TN48M_GP0:
- config.reg_set_base = base;
- break;
- case TN48M_GPI:
- config.reg_dat_base = base;
- break;
- default:
- return -EINVAL;
- }
-
- return PTR_ERR_OR_ZERO(devm_gpio_regmap_register(&pdev->dev, &config));
-}
-
-static const struct of_device_id tn48m_gpio_of_match[] = {
- { .compatible = "delta,tn48m-gpo", .data = &tn48m_gpo_config },
- { .compatible = "delta,tn48m-gpi", .data = &tn48m_gpi_config },
- { }
-};
-MODULE_DEVICE_TABLE(of, tn48m_gpio_of_match);
-
-static struct platform_driver tn48m_gpio_driver = {
- .driver = {
- .name = "delta-tn48m-gpio",
- .of_match_table = tn48m_gpio_of_match,
- },
- .probe = tn48m_gpio_probe,
-};
-module_platform_driver(tn48m_gpio_driver);
-
-MODULE_AUTHOR("Robert Marko <robert.marko@sartura.hr>");
-MODULE_DESCRIPTION("Delta TN48M CPLD GPIO driver");
-MODULE_LICENSE("GPL");
On Mon, Jan 12, 2026 at 7:49 AM Randy Dunlap <rdunlap@infradead.org> wrote:
> The gpio-tn48m driver is useless without the simple-mfd parent, which is
> not present in the kernel tree, so delete it and all references to it.
> Also delete references to the (missing) mfd driver.
>
> Fixes: b3dcb5de6209 ("gpio: Add Delta TN48M CPLD GPIO driver")
> Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Is an equally fine solution to get a rebased version of this patch:
https://lore.kernel.org/all/20220131133049.77780-2-robert.marko@sartura.hr/
to Lee, given that Robert indicates the driver has users?
AFAICT it was just reverted out because of process, not
because of any problem wit the driver/subdrivers themselves.
Lee might have something to add though.
Yours,
Linus Walleij
On Mon, Jan 12, 2026 at 11:30 AM Linus Walleij <linusw@kernel.org> wrote:
>
> On Mon, Jan 12, 2026 at 7:49 AM Randy Dunlap <rdunlap@infradead.org> wrote:
>
> > The gpio-tn48m driver is useless without the simple-mfd parent, which is
> > not present in the kernel tree, so delete it and all references to it.
> > Also delete references to the (missing) mfd driver.
> >
> > Fixes: b3dcb5de6209 ("gpio: Add Delta TN48M CPLD GPIO driver")
> > Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
>
> Is an equally fine solution to get a rebased version of this patch:
> https://lore.kernel.org/all/20220131133049.77780-2-robert.marko@sartura.hr/
>
> to Lee, given that Robert indicates the driver has users?
>
> AFAICT it was just reverted out because of process, not
> because of any problem wit the driver/subdrivers themselves.
It would be awesome to see it in the tree again, as the drivers
themselves work just fine
and allow SFP-s to work on the TN48M and I have patches for TN4810M
(Which is a SFP only version).
I still have both switches and there are some in the wild being
actually used as L3 switches so
it would be great to have the required CPLD drivers be compileable.
Regards,
Robert
>
> Lee might have something to add though.
>
> Yours,
> Linus Walleij
--
Robert Marko
Staff Embedded Linux Engineer
Sartura d.d.
Lendavska ulica 16a
10000 Zagreb, Croatia
Email: robert.marko@sartura.hr
Web: www.sartura.hr
On Mon, Jan 12, 2026 at 1:24 PM Robert Marko <robert.marko@sartura.hr> wrote: > It would be awesome to see it in the tree again, as the drivers > themselves work just fine > and allow SFP-s to work on the TN48M and I have patches for TN4810M > (Which is a SFP only version). I sent a rebased version of the old patch as v11 of that series so Lee can pick it up and we sort out this. Yours, Linus Walleij
On Mon, 12 Jan 2026, Linus Walleij wrote: > On Mon, Jan 12, 2026 at 1:24 PM Robert Marko <robert.marko@sartura.hr> wrote: > > > It would be awesome to see it in the tree again, as the drivers > > themselves work just fine > > and allow SFP-s to work on the TN48M and I have patches for TN4810M > > (Which is a SFP only version). > > I sent a rebased version of the old patch as v11 of that series > so Lee can pick it up and we sort out this. Applied. -- Lee Jones [李琼斯]
On 1/12/26 8:16 AM, Linus Walleij wrote: > On Mon, Jan 12, 2026 at 1:24 PM Robert Marko <robert.marko@sartura.hr> wrote: > >> It would be awesome to see it in the tree again, as the drivers >> themselves work just fine >> and allow SFP-s to work on the TN48M and I have patches for TN4810M >> (Which is a SFP only version). > > I sent a rebased version of the old patch as v11 of that series > so Lee can pick it up and we sort out this. > > Yours, > Linus Walleij Thanks. Sounds good. -- ~Randy
On Mon, Jan 12, 2026 at 7:49 AM Randy Dunlap <rdunlap@infradead.org> wrote:
> The gpio-tn48m driver is useless without the simple-mfd parent, which is
> not present in the kernel tree, so delete it and all references to it.
> Also delete references to the (missing) mfd driver.
>
> Fixes: b3dcb5de6209 ("gpio: Add Delta TN48M CPLD GPIO driver")
> Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
> ---
> Based on v6.19-rc4.
Cc:ing this to Roberts new mail address.
Linus Walleij
On 12/01/2026 07:49, Randy Dunlap wrote: > The gpio-tn48m driver is useless without the simple-mfd parent, which is > not present in the kernel tree, so delete it and all references to it. Same comment, simple-mfd exists in the kernel, so driver is perfectly usable based on above sentence... Best regards, Krzysztof
On Mon, Jan 12, 2026 at 8:27 AM Krzysztof Kozlowski <krzk@kernel.org> wrote: > > On 12/01/2026 07:49, Randy Dunlap wrote: > > The gpio-tn48m driver is useless without the simple-mfd parent, which is > > not present in the kernel tree, so delete it and all references to it. > > Same comment, simple-mfd exists in the kernel, so driver is perfectly > usable based on above sentence... My reply from the reset driver is valid here as well [1]. [1] https://lore.kernel.org/linux-devicetree/CA+HBbNGT+7x0Bs9p5=bNVUSHt66vd38RuFdjm_GxPWX6C6XDNA@mail.gmail.com/T/#t > > Best regards, > Krzysztof -- Robert Marko Staff Embedded Linux Engineer Sartura d.d. Lendavska ulica 16a 10000 Zagreb, Croatia Email: robert.marko@sartura.hr Web: www.sartura.hr
© 2016 - 2026 Red Hat, Inc.