Skip to contentSkip to conversation

FAILED: patch "[PATCH] spi: bcm63xx: disable clock on resume failure" failed to apply to 5.15-stable tree

PATCH New [email protected] 2 participants 2 messages Sep 8 – Sep 10

Subsystems (3)
lore
Share & tools
lore

[email protected]

author maintainer
#0 lore raw

The patch below does not apply to the 5.15-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.

To reproduce the conflict and resubmit, you may use the following commands:

git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-5.15.y
git checkout FETCH_HEAD
git cherry-pick -x 2b62c2c134fa32d9d3a9e7323c8ac74518eeb4ac
# <resolve conflicts, build, test, etc.>
git commit -s
git send-email --to '<[email protected]>' --in-reply-to '2026090843-affiliate-underfed-18c3@gregkh' --subject-prefix 'PATCH 5.15.y' 'HEAD^..'

Possible dependencies:

thanks,

greg k-h

------------------ original commit in Linus's tree ------------------

From 2b62c2c134fa32d9d3a9e7323c8ac74518eeb4ac Mon Sep 17 00:00:00 2001
From: Can Peng <[email protected]>
Date: Tue, 4 Aug 2026 15:18:31 +0800
Subject: [PATCH] spi: bcm63xx: disable clock on resume failure

bcm63xx_spi_resume() enables the controller clock before restarting the SPI controller queue.

If spi_controller_resume() fails, the function currently reports success and leaves the clock enabled. Propagate the error and disable the clock before returning.

Fixes b42dfed83d95 ("spi: add Broadcom BCM63xx SPI controller driver")
drivers/spi/spi-bcm63xx.c +5 -1
index 8cef725aab26..1d8e257bad30 100644
@@ -653,7 +653,11 @@ static int bcm63xx_spi_resume(struct device *dev)
 	if (ret)
 		return ret;
 
-	spi_controller_resume(host);
+	ret = spi_controller_resume(host);
+	if (ret) {
+		clk_disable_unprepare(bs->clk);
+		return ret;
+	}
 
 	return 0;
 }
maintainer
#1 lore raw

PATCH 1/1 spi: bcm63xx: disable clock on resume failure

From: Can Peng <[email protected]>

[ Upstream commit 2b62c2c134fa32d9d3a9e7323c8ac74518eeb4ac ]

bcm63xx_spi_resume() enables the controller clock before restarting the SPI controller queue.

If spi_controller_resume() fails, the function currently reports success and leaves the clock enabled. Propagate the error and disable the clock before returning.

Fixes b42dfed83d95 ("spi: add Broadcom BCM63xx SPI controller driver")
[ changed spi_controller_resume(host) to spi_master_resume(master) to match the older API and variable name. ]
---
 drivers/spi/spi-bcm63xx.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
drivers/spi/spi-bcm63xx.c +5 -1
index e57e1f75cd9f9..1dc579d9e3c4c 100644
@@ -669,7 +669,11 @@ static int bcm63xx_spi_resume(struct device *dev)
 	if (ret)
 		return ret;
 
-	spi_master_resume(master);
+	ret = spi_master_resume(master);
+	if (ret) {
+		clk_disable_unprepare(bs->clk);
+		return ret;
+	}
 
 	return 0;
 }
Signature · 1 line
2.53.0