From: Greg Kroah-Hartman Date: Mon, 3 Feb 2025 14:37:58 +0000 (+0100) Subject: drop pwm-stm32-lp-add-check-for-clk_enable.patch from 5.4 and 5.10 X-Git-Tag: v6.6.76~59 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=9d2712241a8749164d1333f08dbc6e1717e91a21;p=thirdparty%2Fkernel%2Fstable-queue.git drop pwm-stm32-lp-add-check-for-clk_enable.patch from 5.4 and 5.10 Breaks the build --- diff --git a/queue-5.10/pwm-stm32-lp-add-check-for-clk_enable.patch b/queue-5.10/pwm-stm32-lp-add-check-for-clk_enable.patch deleted file mode 100644 index 86189f6a4f..0000000000 --- a/queue-5.10/pwm-stm32-lp-add-check-for-clk_enable.patch +++ /dev/null @@ -1,48 +0,0 @@ -From f90fc366b8a06acbffd51cb01af83bee75f60747 Mon Sep 17 00:00:00 2001 -From: Sasha Levin -Date: Fri, 6 Dec 2024 16:53:18 -0500 -Subject: pwm: stm32-lp: Add check for clk_enable() -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -From: Mingwei Zheng - -[ Upstream commit cce16e7f6216227964cda25f5f23634bce2c500f ] - -Add check for the return value of clk_enable() to catch the potential -error. -We used APP-Miner to find it. - -Fixes: e70a540b4e02 ("pwm: Add STM32 LPTimer PWM driver") -Signed-off-by: Mingwei Zheng -Signed-off-by: Jiasheng Jiang -Link: https://lore.kernel.org/r/20241206215318.3402860-1-zmw12306@gmail.com -Signed-off-by: Uwe Kleine-König -Signed-off-by: Sasha Levin ---- - drivers/pwm/pwm-stm32-lp.c | 8 ++++++-- - 1 file changed, 6 insertions(+), 2 deletions(-) - -diff --git a/drivers/pwm/pwm-stm32-lp.c b/drivers/pwm/pwm-stm32-lp.c -index c8a847fcb775b..6c77499c27211 100644 ---- a/drivers/pwm/pwm-stm32-lp.c -+++ b/drivers/pwm/pwm-stm32-lp.c -@@ -169,8 +169,12 @@ static void stm32_pwm_lp_get_state(struct pwm_chip *chip, - regmap_read(priv->regmap, STM32_LPTIM_CR, &val); - state->enabled = !!FIELD_GET(STM32_LPTIM_ENABLE, val); - /* Keep PWM counter clock refcount in sync with PWM initial state */ -- if (state->enabled) -- clk_enable(priv->clk); -+ if (state->enabled) { -+ int ret = clk_enable(priv->clk); -+ -+ if (ret) -+ return ret; -+ } - - regmap_read(priv->regmap, STM32_LPTIM_CFGR, &val); - presc = FIELD_GET(STM32_LPTIM_PRESC, val); --- -2.39.5 - diff --git a/queue-5.10/series b/queue-5.10/series index afe9e2a7e2..d4295c0d5c 100644 --- a/queue-5.10/series +++ b/queue-5.10/series @@ -27,7 +27,6 @@ wifi-rtlwifi-pci-wait-for-firmware-loading-before-re.patch acpi-fan-cleanup-resources-in-the-error-path-of-.pro.patch cpupower-fix-tsc-mhz-calculation.patch leds-netxbig-fix-an-of-node-reference-leak-in-netxbi.patch -pwm-stm32-lp-add-check-for-clk_enable.patch cpufreq-schedutil-simplify-sugov_update_next_freq.patch cpufreq-schedutil-fix-superfluous-updates-caused-by-.patch udp-deal-with-race-between-udp-socket-address-change.patch diff --git a/queue-5.4/pwm-stm32-lp-add-check-for-clk_enable.patch b/queue-5.4/pwm-stm32-lp-add-check-for-clk_enable.patch deleted file mode 100644 index 7889160986..0000000000 --- a/queue-5.4/pwm-stm32-lp-add-check-for-clk_enable.patch +++ /dev/null @@ -1,48 +0,0 @@ -From 8873787bf20051b878e24ef43eaf1a98d7829ee2 Mon Sep 17 00:00:00 2001 -From: Sasha Levin -Date: Fri, 6 Dec 2024 16:53:18 -0500 -Subject: pwm: stm32-lp: Add check for clk_enable() -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -From: Mingwei Zheng - -[ Upstream commit cce16e7f6216227964cda25f5f23634bce2c500f ] - -Add check for the return value of clk_enable() to catch the potential -error. -We used APP-Miner to find it. - -Fixes: e70a540b4e02 ("pwm: Add STM32 LPTimer PWM driver") -Signed-off-by: Mingwei Zheng -Signed-off-by: Jiasheng Jiang -Link: https://lore.kernel.org/r/20241206215318.3402860-1-zmw12306@gmail.com -Signed-off-by: Uwe Kleine-König -Signed-off-by: Sasha Levin ---- - drivers/pwm/pwm-stm32-lp.c | 8 ++++++-- - 1 file changed, 6 insertions(+), 2 deletions(-) - -diff --git a/drivers/pwm/pwm-stm32-lp.c b/drivers/pwm/pwm-stm32-lp.c -index 20657c649c65e..f03dd7799f864 100644 ---- a/drivers/pwm/pwm-stm32-lp.c -+++ b/drivers/pwm/pwm-stm32-lp.c -@@ -169,8 +169,12 @@ static void stm32_pwm_lp_get_state(struct pwm_chip *chip, - regmap_read(priv->regmap, STM32_LPTIM_CR, &val); - state->enabled = !!FIELD_GET(STM32_LPTIM_ENABLE, val); - /* Keep PWM counter clock refcount in sync with PWM initial state */ -- if (state->enabled) -- clk_enable(priv->clk); -+ if (state->enabled) { -+ int ret = clk_enable(priv->clk); -+ -+ if (ret) -+ return ret; -+ } - - regmap_read(priv->regmap, STM32_LPTIM_CFGR, &val); - presc = FIELD_GET(STM32_LPTIM_PRESC, val); --- -2.39.5 - diff --git a/queue-5.4/series b/queue-5.4/series index c35fa9f13d..bddb47df14 100644 --- a/queue-5.4/series +++ b/queue-5.4/series @@ -16,7 +16,6 @@ wifi-rtlwifi-remove-unused-check_buddy_priv.patch wifi-rtlwifi-fix-memory-leaks-and-invalid-access-at-.patch wifi-rtlwifi-pci-wait-for-firmware-loading-before-re.patch cpupower-fix-tsc-mhz-calculation.patch -pwm-stm32-lp-add-check-for-clk_enable.patch team-prevent-adding-a-device-which-is-already-a-team.patch regulator-of-implement-the-unwind-path-of-of_regulat.patch wifi-wlcore-fix-unbalanced-pm_runtime-calls.patch