gpio: pca953x: Add support for PCAL6534
authorMartyn Welch <martyn.welch@collabora.com>
Wed, 14 Sep 2022 15:15:57 +0000 (16:15 +0100)
committerBartosz Golaszewski <brgl@bgdev.pl>
Thu, 15 Sep 2022 08:08:49 +0000 (10:08 +0200)
commit13c5d4ce806026a3d06efa2fcc1e5a0cb875df29
tree62ea9e21dffaf395fb61cd1b30e43a621f2ab15d
parent5faf9801d4be7a079062b2ece493ae6e9e38c828
gpio: pca953x: Add support for PCAL6534

Add support for the NXP PCAL6534. This device is broadly a 34-bit version
of the PCAL6524. However, whilst the registers are broadly what you'd
expect for a 34-bit version of the PCAL6524, the spacing of the registers
has been compacted. This has the unfortunate effect of breaking the bit
shift based mechanism that is employed to work out register locations used
by the other chips supported by this driver. To accommodate ths, callback
functions have been added to allow alterate implementations of
pca953x_recalc_addr() and pca953x_check_register() for the PCAL6534.

Datasheet: https://www.nxp.com/docs/en/data-sheet/PCAL6534.pdf
Datasheet: https://www.diodes.com/assets/Datasheets/PI4IOE5V6534Q.pdf
Signed-off-by: Martyn Welch <martyn.welch@collabora.com>
Signed-off-by: Bartosz Golaszewski <brgl@bgdev.pl>
drivers/gpio/gpio-pca953x.c