[PATCH] spi: cadence-qspi: Remove redundant pm_runtime_mark_last_busy call

Akif Ejaz posted 1 patch 2 weeks, 1 day ago
drivers/spi/spi-cadence-quadspi.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
[PATCH] spi: cadence-qspi: Remove redundant pm_runtime_mark_last_busy call
Posted by Akif Ejaz 2 weeks, 1 day ago
The pm_runtime_mark_last_busy() call is redundant in probe function
as pm_runtime_put_autosuspend() already calls pm_runtime_mark_last_busy()
internally to update the last access time of the device before queuing
autosuspend.

Remove the pm_runtime_mark_last_busy() call from the probe function.

Tested on StarFive VisionFive 2 v1.2A board.

Fixes: e1f2e77624db ("spi: cadence-qspi: Fix runtime PM imbalance in probe")

Signed-off-by: Akif Ejaz <akifejaz40@gmail.com>
---
 drivers/spi/spi-cadence-quadspi.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/spi/spi-cadence-quadspi.c b/drivers/spi/spi-cadence-quadspi.c
index 638edca3805a..bf0677949ba8 100644
--- a/drivers/spi/spi-cadence-quadspi.c
+++ b/drivers/spi/spi-cadence-quadspi.c
@@ -2011,10 +2011,8 @@ static int cqspi_probe(struct platform_device *pdev)
 		goto probe_setup_failed;
 	}
 
-	if (!(ddata && (ddata->quirks & CQSPI_DISABLE_RUNTIME_PM))) {
-		pm_runtime_mark_last_busy(dev);
+	if (!(ddata && (ddata->quirks & CQSPI_DISABLE_RUNTIME_PM)))
 		pm_runtime_put_autosuspend(dev);
-	}
 
 	return 0;
 probe_setup_failed:
-- 
2.34.1
Re: [PATCH] spi: cadence-qspi: Remove redundant pm_runtime_mark_last_busy call
Posted by Mark Brown 4 days, 3 hours ago
On Wed, 03 Dec 2025 23:19:21 +0500, Akif Ejaz wrote:
> The pm_runtime_mark_last_busy() call is redundant in probe function
> as pm_runtime_put_autosuspend() already calls pm_runtime_mark_last_busy()
> internally to update the last access time of the device before queuing
> autosuspend.
> 
> Remove the pm_runtime_mark_last_busy() call from the probe function.
> 
> [...]

Applied to

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

Thanks!

[1/1] spi: cadence-qspi: Remove redundant pm_runtime_mark_last_busy call
      commit: 28d21dfcea0121afec04451733a6c553fd319c8e

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