diff options
author | Frank Li <Frank.Li@nxp.com> | 2025-01-29 11:22:50 -0500 |
---|---|---|
committer | Alexandre Belloni <alexandre.belloni@bootlin.com> | 2025-02-20 23:20:28 +0100 |
commit | a892ee4cf22a50e1d6988d0464a9a421f3e5db2f (patch) | |
tree | 94e73bdbbce318cb4ebbf8ffb4e8259b7878cf1b /drivers/i3c | |
parent | effed5dac8f8b3db006c4971cdd592504afd1c5d (diff) |
i3c: master: svc: Flush FIFO before sending Dynamic Address Assignment(DAA)
Ensure the FIFO is empty before issuing the DAA command to prevent
incorrect command data from being sent. Align with other data transfers,
such as svc_i3c_master_start_xfer_locked(), which flushes the FIFO before
sending a command.
Signed-off-by: Frank Li <Frank.Li@nxp.com>
Reviewed-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/r/20250129162250.3629189-1-Frank.Li@nxp.com
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Diffstat (limited to 'drivers/i3c')
-rw-r--r-- | drivers/i3c/master/svc-i3c-master.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/i3c/master/svc-i3c-master.c b/drivers/i3c/master/svc-i3c-master.c index 413479b12ba6..98f800f99969 100644 --- a/drivers/i3c/master/svc-i3c-master.c +++ b/drivers/i3c/master/svc-i3c-master.c @@ -892,6 +892,8 @@ static int svc_i3c_master_do_daa_locked(struct svc_i3c_master *master, u32 reg; int ret, i; + svc_i3c_master_flush_fifo(master); + while (true) { /* clean SVC_I3C_MINT_IBIWON w1c bits */ writel(SVC_I3C_MINT_IBIWON, master->regs + SVC_I3C_MSTATUS); |