pinctrl: aspeed: Allow changing SPI mode from hardware strap defaults
authorZev Weiss <zev@bewilderbeest.net>
Thu, 5 Oct 2023 03:08:50 +0000 (20:08 -0700)
committerLinus Walleij <linus.walleij@linaro.org>
Tue, 10 Oct 2023 12:01:30 +0000 (14:01 +0200)
commitd875d6ccd36f5eed25829d483b12df6ed826f9b5
tree9b015d7e269f3e9897157098e9761e5d21125a7b
parent54a33423f29b3a018cfcd831863c9b063c35d70f
pinctrl: aspeed: Allow changing SPI mode from hardware strap defaults

Some platforms unfortunately have their SPI mode selection bits
strapped incorrectly (such as being configured for passthrough mode
when master mode is in fact the only useful configuration for it) and
thus require correction in software.  Add the SPI mode bits to the
GPIO passthrough bits as the exceptions to the read-only rule for the
hardware strap register so that the pinctrl subsystem can be used for
such corrections.

Signed-off-by: Zev Weiss <zev@bewilderbeest.net>
Reviewed-by: Andrew Jeffery <andrew@codeconstruct.com.au>
Link: https://lore.kernel.org/r/20231005030849.11352-2-zev@bewilderbeest.net
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/pinctrl/aspeed/pinctrl-aspeed-g4.c
drivers/pinctrl/aspeed/pinctrl-aspeed-g5.c