Re: [PATCH v3 2/3] i3c: master: cdns: Use i3c_writel_fifo() and i3c_readl_fifo()

From: Wolfram Sang
Date: Wed Jun 25 2025 - 03:26:53 EST



> static void cdns_i3c_master_wr_to_tx_fifo(struct cdns_i3c_master *master,
> const u8 *bytes, int nbytes)
> {
> - writesl(master->regs + TX_FIFO, bytes, nbytes / 4);
> - if (nbytes & 3) {
> - u32 tmp = 0;
> -
> - memcpy(&tmp, bytes + (nbytes & ~3), nbytes & 3);
> - writesl(master->regs + TX_FIFO, &tmp, 1);
> - }
> + i3c_writel_fifo(master->regs + TX_FIFO, bytes, nbytes);
> }

What about getting rid of the surrounding function and use the helper
directly?

Attachment: signature.asc
Description: PGP signature