linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Tóth János via B4 Relay" <devnull+gomba007.gmail.com@kernel.org>
To: Linus Walleij <linus.walleij@linaro.org>,
	 Bartosz Golaszewski <brgl@bgdev.pl>,
	Rob Herring <robh@kernel.org>,
	 Krzysztof Kozlowski <krzk+dt@kernel.org>,
	 Conor Dooley <conor+dt@kernel.org>,
	 Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Cc: linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org,
	devicetree@vger.kernel.org, "Tóth János" <gomba007@gmail.com>
Subject: [PATCH 1/2] drivers: gpio: Add support for PCF8574T.
Date: Mon, 17 Feb 2025 14:07:51 +0100	[thread overview]
Message-ID: <20250217-gpio-pcf8574t-v1-1-137e140df5fc@gmail.com> (raw)
In-Reply-To: <20250217-gpio-pcf8574t-v1-0-137e140df5fc@gmail.com>

From: Tóth János <gomba007@gmail.com>

Add support for the PCF8574T 8-bit I2C I/O expander.

The driver is tested with:
	+ tools/lsgpio
	+ tools/gpio-hammer
	+ some LEDs

[1] https://www.nxp.com/docs/en/data-sheet/PCF8574_PCF8574A.pdf

Signed-off-by: Tóth János <gomba007@gmail.com>
---
 drivers/gpio/Kconfig        | 2 +-
 drivers/gpio/gpio-pcf857x.c | 2 ++
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/gpio/Kconfig b/drivers/gpio/Kconfig
index 98b4d1633b25..d7cdc3cc1b00 100644
--- a/drivers/gpio/Kconfig
+++ b/drivers/gpio/Kconfig
@@ -1193,7 +1193,7 @@ config GPIO_PCF857X
 	  Most of these parts are from NXP, though TI is a second source for
 	  some of them.  Compatible models include:
 
-	  8 bits:   pcf8574, pcf8574a, pca8574, pca8574a,
+	  8 bits:   pcf8574, pcf8574a, pcf8574t, pca8574, pca8574a,
 	            pca9670, pca9672, pca9674, pca9674a,
 	            max7328, max7329
 
diff --git a/drivers/gpio/gpio-pcf857x.c b/drivers/gpio/gpio-pcf857x.c
index 7c57eaeb0afe..2464c527a4e8 100644
--- a/drivers/gpio/gpio-pcf857x.c
+++ b/drivers/gpio/gpio-pcf857x.c
@@ -20,6 +20,7 @@
 static const struct i2c_device_id pcf857x_id[] = {
 	{ "pcf8574", 8 },
 	{ "pcf8574a", 8 },
+	{ "pcf8574t", 8 },
 	{ "pca8574", 8 },
 	{ "pca9670", 8 },
 	{ "pca9672", 8 },
@@ -38,6 +39,7 @@ MODULE_DEVICE_TABLE(i2c, pcf857x_id);
 static const struct of_device_id pcf857x_of_table[] = {
 	{ .compatible = "nxp,pcf8574", (void *)8 },
 	{ .compatible = "nxp,pcf8574a", (void *)8 },
+	{ .compatible = "nxp,pcf8574t", (void *)8 },
 	{ .compatible = "nxp,pca8574", (void *)8 },
 	{ .compatible = "nxp,pca9670", (void *)8 },
 	{ .compatible = "nxp,pca9672", (void *)8 },

-- 
2.34.1



  reply	other threads:[~2025-02-17 13:08 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-17 13:07 [PATCH 0/2] Add support for the PCF8574T I/O expander Tóth János via B4 Relay
2025-02-17 13:07 ` Tóth János via B4 Relay [this message]
2025-02-17 13:07 ` [PATCH 2/2] dt-bindings: gpio: Add support for PCF8574T Tóth János via B4 Relay
2025-02-17 15:13   ` Laurent Pinchart
2025-02-17 17:49     ` Tóth János

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250217-gpio-pcf8574t-v1-1-137e140df5fc@gmail.com \
    --to=devnull+gomba007.gmail.com@kernel.org \
    --cc=brgl@bgdev.pl \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=gomba007@gmail.com \
    --cc=krzk+dt@kernel.org \
    --cc=laurent.pinchart+renesas@ideasonboard.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=robh@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).