Skip to contentSkip to conversation

Add support for NXP PCA6408

PATCH In review Justin Chen 4 participants 7 messages May 4, 2022 – May 5, 2022

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

v2 cover Add support for NXP PCA6408

The NXP PCA6408 is the 8 bit/8 GPIO version of the NXP PCA6416.

Justin Chen (2):
gpio: pca953xx: Add support for pca6408
dt-bindings: gpio: pca95xx: add entry for pca6408

 Documentation/devicetree/bindings/gpio/gpio-pca95xx.yaml | 1 +
 drivers/gpio/gpio-pca953x.c                              | 2 ++
 2 files changed, 3 insertions(+)
Signature · 1 line
2.7.4
#1 lore raw

PATCH v2 1/2 gpio: pca953xx: Add support for pca6408

Add support for pca6408 which is the 8-bit version of the pca6416.

https://www.nxp.com/docs/en/data-sheet/PCA6408A.pdf

---
 drivers/gpio/gpio-pca953x.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/gpio/gpio-pca953x.c +2 -0
index d2fe76f..4909175 100644
@@ -71,6 +71,7 @@
 #define PCA_CHIP_TYPE(x)	((x) & PCA_TYPE_MASK)
 
 static const struct i2c_device_id pca953x_id[] = {
+	{ "pca6408", 8  | PCA953X_TYPE | PCA_INT, },
 	{ "pca6416", 16 | PCA953X_TYPE | PCA_INT, },
 	{ "pca9505", 40 | PCA953X_TYPE | PCA_INT, },
 	{ "pca9506", 40 | PCA953X_TYPE | PCA_INT, },
@@ -1198,6 +1199,7 @@ static int pca953x_resume(struct device *dev)
 #define OF_957X(__nrgpio, __int) (void *)(__nrgpio | PCA957X_TYPE | __int)
 
 static const struct of_device_id pca953x_dt_ids[] = {
+	{ .compatible = "nxp,pca6408", .data = OF_953X(8, PCA_INT), },
 	{ .compatible = "nxp,pca6416", .data = OF_953X(16, PCA_INT), },
 	{ .compatible = "nxp,pca9505", .data = OF_953X(40, PCA_INT), },
 	{ .compatible = "nxp,pca9506", .data = OF_953X(40, PCA_INT), },
Signature · 1 line
2.7.4
#3 lore raw

PATCH v2 2/2 dt-bindings: gpio: pca95xx: add entry for pca6408

In reply to Justin Chen

The NXP PCA5608 is the 8-bit version of PCA5616.

---
 Documentation/devicetree/bindings/gpio/gpio-pca95xx.yaml | 1 +
 1 file changed, 1 insertion(+)
Documentation/devicetree/bindings/gpio/gpio-pca95xx.yaml +1 -0
index dc0fc8f..977b14d 100644
@@ -30,6 +30,7 @@ properties:
       - maxim,max7325
       - maxim,max7326
       - maxim,max7327
+      - nxp,pca6408
       - nxp,pca6416
       - nxp,pca9505
       - nxp,pca9506
Signature · 1 line
2.7.4
#6 lore raw
In reply to Justin Chen
Quoted 7 lines · Justin Chen

The NXP PCA6408 is the 8 bit/8 GPIO version of the NXP PCA6416.

Justin Chen (2):
gpio: pca953xx: Add support for pca6408
dt-bindings: gpio: pca95xx: add entry for pca6408

Quoted 7 lines
 Documentation/devicetree/bindings/gpio/gpio-pca95xx.yaml | 1 +
 drivers/gpio/gpio-pca953x.c                              | 2 ++
 2 files changed, 3 insertions(+)

--
2.7.4

Both applied, thanks!

Bart