soc: imx: gpcv2: wait for ADB400 handshake
authorLucas Stach <l.stach@pengutronix.de>
Mon, 10 May 2021 04:00:37 +0000 (12:00 +0800)
committerShawn Guo <shawnguo@kernel.org>
Sun, 23 May 2021 02:58:04 +0000 (10:58 +0800)
commit58d268619aa941c39056f2c7464edb52d6b6b811
tree4eb9f915d62065d7eca728cba534e0b426a2b3e4
parent256f07edbdd27d4eb0088eb895669e04f4012f9c
soc: imx: gpcv2: wait for ADB400 handshake

New reference manuals show that there is actually a status bit for
the ADB400 handshake. Add a poll loop to wait for the ADB400 to
acknowledge our request.

[Peng Fan: i.MX8MM has blk ctl module, the handshake can only finish
 after setting blk ctl. The blk ctl driver will set the bus clk bit and
 the handshake will finish there. we just add a delay and suppose the
 handshake will finish after that.]

Tested-by: Frieder Schrempf <frieder.schrempf@kontron.de>
Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
drivers/soc/imx/gpcv2.c