]> git.baikalelectronics.ru Git - kernel.git/commit
gpio: pca953x: Fix AI overflow on PCAL6524
authorMarek Vasut <marek.vasut@gmail.com>
Wed, 12 Dec 2018 01:39:50 +0000 (02:39 +0100)
committerLinus Walleij <linus.walleij@linaro.org>
Fri, 14 Dec 2018 14:18:47 +0000 (15:18 +0100)
commit07c35116977d7efdca17bb17e3c58120aad9777f
tree28214d0c88609d65d3943b6e41d13ba5040f6219
parent2a1aa6bccc9fb24fb6ec01d8a5f8aad1f1b42553
gpio: pca953x: Fix AI overflow on PCAL6524

The PCAL_PINCTRL_MASK is too large. The extended register block on
PCAL6524, which is the largest chip with this block, has the block
limited to address range 0x40..0x7f. This is because the bit 7 in
the command register is used for the Address Increment functionality.

Trim the mask to 0x60 to match the datasheet and to prevent accidental
overwrite of the AI bit.

Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Reviewed-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/gpio/gpio-pca953x.c