mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] spi: xlp: reinitialize completion before each transfer block
@ 2026-11-03 12:00 Felix Gu
  2026-11-03 18:37 ` Mark Brown
  0 siblings, 1 reply; 2+ messages in thread
From: Felix Gu @ 2026-11-03 12:00 UTC (permalink / raw)
  To: Mark Brown, Kamlakant Patel; +Cc: linux-spi, linux-kernel, Felix Gu

Reinitialize the completion before each transfer block to prevent
wait_for_completion_timeout() from returning immediately on a stale
completion count left by a prior transfer block.

Fixes: d8c80d49cfa0 ("spi/xlp: SPI controller driver for Netlogic XLP SoCs")
Signed-off-by: Felix Gu <ustc.gu@gmail.com>
---
 drivers/spi/spi-xlp.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/spi/spi-xlp.c b/drivers/spi/spi-xlp.c
index d014955e6d4b..fce8f50cd2a5 100644
--- a/drivers/spi/spi-xlp.c
+++ b/drivers/spi/spi-xlp.c
@@ -279,6 +279,8 @@ static int xlp_spi_xfer_block(struct  xlp_spi_priv *xs,
 	xs->rx_len = (xs->rx_buf == NULL) ? 0 : xfer_len;
 	xs->txerrors = xs->rxerrors = 0;
 
+	reinit_completion(&xs->done);
+
 	/* fill TXDATA_FIFO, then send the CMD */
 	if (xs->tx_len)
 		xlp_spi_fill_txfifo(xs);

---
base-commit: a39c950806213f6861d00f90729acaaa21f2d95a
change-id: 20261103-xlp-4ee821c8a89d

Best regards,
--  
Felix Gu <ustc.gu@gmail.com>


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] spi: xlp: reinitialize completion before each transfer block
  2026-11-03 12:00 [PATCH] spi: xlp: reinitialize completion before each transfer block Felix Gu
@ 2026-11-03 18:37 ` Mark Brown
  0 siblings, 0 replies; 2+ messages in thread
From: Mark Brown @ 2026-11-03 18:37 UTC (permalink / raw)
  To: Kamlakant Patel, Felix Gu; +Cc: linux-spi, linux-kernel

On Tue, 03 Nov 2026 20:00:22 +0800, Felix Gu wrote:
> spi: xlp: reinitialize completion before each transfer block

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git for-7.5

Thanks!

[1/1] spi: xlp: reinitialize completion before each transfer block
      https://git.kernel.org/broonie/spi/c/bf0507562dd0

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2026-11-04  0:01 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-03 12:00 [PATCH] spi: xlp: reinitialize completion before each transfer block Felix Gu
2026-11-03 18:37 ` Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®