Skip to contentSkip to conversation

gpio: pca953x: add support for TCA9538

PATCH Applied Liam Beguin 4 participants 7 messages Aug 24, 2023 – Aug 25, 2023

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

cover gpio: pca953x: add support for TCA9538

The TCA9538 is an 8 bit version of the already supported TCA9539. This chip also has interrupt support.

---
Liam Beguin (2):
gpio: pca953x: add support for TCA9538
dt-bindings: gpio: pca95xx: document new tca9538 chip

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

---
base-commit: a5e505a99ca748583dbe558b691be1b26f05d678
change-id: 20230824-tca9538-4dbf8d93f1ba

Best regards,

Signature · 1 line
Liam Beguin <[email protected]>
#1 lore raw

PATCH 1/2 gpio: pca953x: add support for TCA9538

The TCA9538 is an 8 bit version of the already supported TCA9539. This chip also has interrupt support.

---
 drivers/gpio/gpio-pca953x.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/gpio/gpio-pca953x.c +2 -0
index a806a3c1b801..71a750363738 100644
@@ -108,6 +108,7 @@ static const struct i2c_device_id pca953x_id[] = {
 	{ "tca6408", 8  | PCA953X_TYPE | PCA_INT, },
 	{ "tca6416", 16 | PCA953X_TYPE | PCA_INT, },
 	{ "tca6424", 24 | PCA953X_TYPE | PCA_INT, },
+	{ "tca9538", 8  | PCA953X_TYPE | PCA_INT, },
 	{ "tca9539", 16 | PCA953X_TYPE | PCA_INT, },
 	{ "tca9554", 8  | PCA953X_TYPE | PCA_INT, },
 	{ "xra1202", 8  | PCA953X_TYPE },
@@ -1354,6 +1355,7 @@ static const struct of_device_id pca953x_dt_ids[] = {
 	{ .compatible = "ti,tca6408", .data = OF_953X( 8, PCA_INT), },
 	{ .compatible = "ti,tca6416", .data = OF_953X(16, PCA_INT), },
 	{ .compatible = "ti,tca6424", .data = OF_953X(24, PCA_INT), },
+	{ .compatible = "ti,tca9538", .data = OF_953X( 8, PCA_INT), },
 	{ .compatible = "ti,tca9539", .data = OF_953X(16, PCA_INT), },
 
 	{ .compatible = "onnn,cat9554", .data = OF_953X( 8, PCA_INT), },
Signature · 1 line
2.39.0
Reviewed-by on v1 1/2
#2 lore raw
Quoted 2 lines · Liam Beguin

The TCA9538 is an 8 bit version of the already supported TCA9539. This chip also has interrupt support.

Signature · 2 lines
With Best Regards,
Andy Shevchenko
#3 lore raw
In reply to Liam Beguin
Quoted 31 lines · Liam Beguin

The TCA9538 is an 8 bit version of the already supported TCA9539. This chip also has interrupt support.

---
 drivers/gpio/gpio-pca953x.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/gpio/gpio-pca953x.c +2 -1
index a806a3c1b801..71a750363738 100644
@@ -108,6 +108,7 @@ static const struct i2c_device_id pca953x_id[] = {
        { "tca6408", 8  | PCA953X_TYPE | PCA_INT, },
        { "tca6416", 16 | PCA953X_TYPE | PCA_INT, },
        { "tca6424", 24 | PCA953X_TYPE | PCA_INT, },
+       { "tca9538", 8  | PCA953X_TYPE | PCA_INT, },
        { "tca9539", 16 | PCA953X_TYPE | PCA_INT, },
        { "tca9554", 8  | PCA953X_TYPE | PCA_INT, },
        { "xra1202", 8  | PCA953X_TYPE },
@@ -1354,6 +1355,7 @@ static const struct of_device_id pca953x_dt_ids[] = {
        { .compatible = "ti,tca6408", .data = OF_953X( 8, PCA_INT), },
        { .compatible = "ti,tca6416", .data = OF_953X(16, PCA_INT), },
        { .compatible = "ti,tca6424", .data = OF_953X(24, PCA_INT), },
+       { .compatible = "ti,tca9538", .data = OF_953X( 8, PCA_INT), },
        { .compatible = "ti,tca9539", .data = OF_953X(16, PCA_INT), },
 
        { .compatible = "onnn,cat9554", .data = OF_953X( 8, PCA_INT), },
 
--
Quoted 2 lines

2.39.0

Applied, thanks!

Bart

#4 lore raw

PATCH 2/2 dt-bindings: gpio: pca95xx: document new tca9538 chip

In reply to Liam Beguin

The previous patch added support for this chip. Add its name to the list of allowed compatibles.

---
 Documentation/devicetree/bindings/gpio/gpio-pca95xx.yaml | 1 +
 1 file changed, 1 insertion(+)
Documentation/devicetree/bindings/gpio/gpio-pca95xx.yaml +1 -0
index fa116148ee90..99febb8ea1b6 100644
@@ -66,6 +66,7 @@ properties:
               - ti,tca6408
               - ti,tca6416
               - ti,tca6424
+              - ti,tca9538
               - ti,tca9539
               - ti,tca9554
 
Signature · 1 line
2.39.0
Acked-by on v1 2/2
#5 lore raw

Re: [PATCH 2/2] dt-bindings: gpio: pca95xx: document new tca9538 chip

Quoted 1 line · Liam Beguin

The previous patch added support for this chip.

This is not needed. If by any chance this would go via different trees, it would stop to make any sense.

Also, is wrong. Bindings come *always* before the users.

Best regards,
Krzysztof

#6 lore raw

Re: [PATCH 2/2] dt-bindings: gpio: pca95xx: document new tca9538 chip

In reply to Liam Beguin
Quoted 23 lines · Liam Beguin

The previous patch added support for this chip. Add its name to the list of allowed compatibles.

---
 Documentation/devicetree/bindings/gpio/gpio-pca95xx.yaml | 1 +
 1 file changed, 1 insertion(+)
Documentation/devicetree/bindings/gpio/gpio-pca95xx.yaml +1 -1
index fa116148ee90..99febb8ea1b6 100644
@@ -66,6 +66,7 @@ properties:
               - ti,tca6408
               - ti,tca6416
               - ti,tca6424
+              - ti,tca9538
               - ti,tca9539
               - ti,tca9554
 
 
--
Quoted 2 lines

2.39.0

Applied with commit message tweaked.

Bart