mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Nuno Sá" <nuno.sa@analog.com>
To: Jonathan Santos <Jonathan.Santos@analog.com>
Cc: linux-kernel@vger.kernel.org, linux-spi@vger.kernel.org,
	dlechner@baylibre.com, broonie@kernel.org,
	michael.hennerich@analog.com, jonath4nns@gmail.com,
	andriy.shevchenko@intel.com
Subject: Re: [PATCH v2 0/2] spi: axi-spi-engine: fix stale SYNC IRQ pending
Date: Wed, 30 Sep 2026 12:59:44 +0100	[thread overview]
Message-ID: <arz5m1reIpvQTAsA@nsa> (raw)
In-Reply-To: <cover.1790731588.git.Jonathan.Santos@analog.com>

On Tue, Sep 29, 2026 at 11:17:06PM -0300, Jonathan Santos wrote:
> Both spi_engine_setup() and spi_engine_trigger_enable() send a SYNC(1)
> command and poll SYNC_ID, but never clear INT_PENDING[SYNC] afterward.
> This leaves a stale pending bit that fires spuriously when INT_SYNC is
> enabled later by some driver, causing premature transfer completion at
> low SPI clock frequencies (more likely). Fix both functions by clearing
> the pending bit after polling.
> 
> v2 summary:
> * Replaced "Link" tag for "Closes" tag.
> * Included "Fixes" tag.
> * Added new patch applying similar fix for the spi_engine_trigger_enable(),
>   as pointed out by David.
> * While at it, replaced plain "1000" by "1 * USEC_PER_MSEC" for better
>   clarity.
> * Link to v1: https://lore.kernel.org/linux-spi/04d51e99b8cddce51113db933d806e83848f04f5.1788313558.git.Jonathan.Santos@analog.com/T/#t
> 
> Jonathan Santos (2):
>   spi: axi-spi-engine: fix stale SYNC IRQ pending
>   spi: axi-spi-engine: fix stale SYNC IRQ pending in trigger_enable
> 
>  drivers/spi/spi-axi-spi-engine.c | 16 +++++++++++++---
>  1 file changed, 13 insertions(+), 3 deletions(-)
> 
> 
> base-commit: a3b3580713f3ac5a32dc2874ee546828977a1d68
> -- 
> 2.34.1
> 

Reviewed-by: Nuno Sá <nuno.sa@analog.com>


      parent reply	other threads:[~2026-09-30 11:58 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-30  2:17 Jonathan Santos
2026-09-30  2:17 ` [PATCH v2 1/2] " Jonathan Santos
2026-09-30  2:17 ` [PATCH v2 2/2] spi: axi-spi-engine: fix stale SYNC IRQ pending in trigger_enable Jonathan Santos
2026-09-30 13:09   ` Mark Brown
2026-09-30 11:59 ` Nuno Sá [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=arz5m1reIpvQTAsA@nsa \
    --to=nuno.sa@analog.com \
    --cc=Jonathan.Santos@analog.com \
    --cc=andriy.shevchenko@intel.com \
    --cc=broonie@kernel.org \
    --cc=dlechner@baylibre.com \
    --cc=jonath4nns@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-spi@vger.kernel.org \
    --cc=michael.hennerich@analog.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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®