]> git.baikalelectronics.ru Git - kernel.git/commit
pinctrl: sh-pfc: r8a77990: Fix MOD_SEL0 SEL_I2C1 field width
authorGeert Uytterhoeven <geert+renesas@glider.be>
Thu, 13 Dec 2018 09:53:11 +0000 (10:53 +0100)
committerGeert Uytterhoeven <geert+renesas@glider.be>
Tue, 18 Dec 2018 10:25:56 +0000 (11:25 +0100)
commit3d33a4169f0463dc5c3dfeca038425925158723f
tree22bf502c548ebced4caec02a57d3ed759aa0fe10
parent5fcb3c4f9d5e2fb6a904985baebf196d74c7f771
pinctrl: sh-pfc: r8a77990: Fix MOD_SEL0 SEL_I2C1 field width

The SEL_I2C1 (MOD_SEL0[21:20]) field in Module Select Register 0 has a
width of 2 bits, i.e. it allows programming one out of 4 different
configurations.
However, the MOD_SEL0_21_20 macro contains 8 values instead of 4,
overflowing into the subsequent fields in the register, and thus breaking
the configuration of the latter.

Fix this by dropping the bogus last 4 values, including the non-existent
SEL_I2C1_4 configuration.

Fixes: 6baed73a6a480f34 ("pinctrl: sh-pfc: Initial R8A77990 PFC support")
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Simon Horman <horms+renesas@verge.net.au>
drivers/pinctrl/sh-pfc/pfc-r8a77990.c