OSDN Git Service

fsi: aspeed: Support cabled FSI
authorJoel Stanley <joel@jms.id.au>
Tue, 28 Jul 2020 02:55:24 +0000 (12:25 +0930)
committerJoel Stanley <joel@jms.id.au>
Thu, 10 Sep 2020 02:53:14 +0000 (12:23 +0930)
commitf369a29bdde9f14040e9f0cc4ac610cdb216e93c
tree571fbb99ce93f64973f3ef6f5c71112387040b56
parent4d4905f6cc5b6534e9a3b6a3c75bcee840a27751
fsi: aspeed: Support cabled FSI

Some FSI capable systems have internal FSI signals, and some have
external cabled FSI. Software can detect which machine this is by
reading a jumper GPIO, and also control which pins the signals are
routed to through a mux GPIO.

This attempts to find the GPIOs at probe time. If they are not present
in the device tree the driver will not error and continue as before.

The mux GPIO is owned by the FSI driver to ensure it is not modified at
runtime. The routing jumper obtained as non-exclusive to allow other
software to inspect it's state.

Reviewed-by: Andrew Jeffery <andrew@aj.id.au>
Link: https://lore.kernel.org/r/20200728025527.174503-3-joel@jms.id.au
Signed-off-by: Joel Stanley <joel@jms.id.au>
drivers/fsi/fsi-master-aspeed.c