gpio: pca953x: Add support for the PCAL9535
PATCH 1/1 gpio: pca953x: Add support for the PCAL9535
From: Jan Kiszka <[email protected]>
The PCAL9535 [1] is compatible to the PCA9535. Additionally, it comes with interrupt support and input latching. Other features are not supported by the GPIO subsystem.
[1] https://www.nxp.com/docs/en/data-sheet/PCAL9535A.pdf
--- drivers/gpio/gpio-pca953x.c | 1 + 1 file changed, 1 insertion(+)
drivers/gpio/gpio-pca953x.c +1 -0
@@ -1131,6 +1131,7 @@ static const struct of_device_id pca953x_dt_ids[] = { { .compatible = "nxp,pca9505", .data = OF_953X(40, PCA_INT), }, { .compatible = "nxp,pca9534", .data = OF_953X( 8, PCA_INT), }, { .compatible = "nxp,pca9535", .data = OF_953X(16, PCA_INT), }, + { .compatible = "nxp,pcal9535", .data = OF_953X(16, PCA_LATCH_INT), }, { .compatible = "nxp,pca9536", .data = OF_953X( 4, 0), }, { .compatible = "nxp,pca9537", .data = OF_953X( 4, PCA_INT), }, { .compatible = "nxp,pca9538", .data = OF_953X( 8, PCA_INT), },
--
2.26.2
sob., 13 cze 2020 o 16:44 Jan Kiszka <[email protected]> napisał(a):
Quoted 27 lines
From: Jan Kiszka <[email protected]>
The PCAL9535 [1] is compatible to the PCA9535. Additionally, it comes with interrupt support and input latching. Other features are not supported by the GPIO subsystem.
[1] https://www.nxp.com/docs/en/data-sheet/PCAL9535A.pdf
Signed-off-by Jan Kiszka <[email protected]>--- drivers/gpio/gpio-pca953x.c | 1 + 1 file changed, 1 insertion(+)drivers/gpio/gpio-pca953x.c +1
-1@@ -1131,6 +1131,7 @@ static const struct of_device_id pca953x_dt_ids[] = { { .compatible = "nxp,pca9505", .data = OF_953X(40, PCA_INT), }, { .compatible = "nxp,pca9534", .data = OF_953X( 8, PCA_INT), }, { .compatible = "nxp,pca9535", .data = OF_953X(16, PCA_INT), }, + { .compatible = "nxp,pcal9535", .data = OF_953X(16, PCA_LATCH_INT), }, { .compatible = "nxp,pca9536", .data = OF_953X( 4, 0), }, { .compatible = "nxp,pca9537", .data = OF_953X( 4, PCA_INT), }, { .compatible = "nxp,pca9538", .data = OF_953X( 8, PCA_INT), }, --
Quoted 2 lines
2.26.2
There should be a corresponding device-tree bindings change in the same series but in a separate patch.
Bartosz
Quoted 9 lines · Jan Kiszka
From: Jan Kiszka <[email protected]>
The PCAL9535 [1] is compatible to the PCA9535. Additionally, it comes with interrupt support and input latching. Other features are not supported by the GPIO subsystem.
Can we have this as a Datasheet: tag?
Review static const struct of_device_id pca953x_dt_ids[] = { · line 1132
Quoted 3 lines
(quoted diff) +1
-0@@ -1131,6 +1131,7 @@ static const struct of_device_id pca953x_dt_ids[] = { + { .compatible = "nxp,pcal9535", .data = OF_953X(16, PCA_LATCH_INT), },
Also, please update I²C ID table.
Signature · 2 lines
With Best Regards, Andy Shevchenko