diff options
| author | Rosen Penev | 2025-04-26 22:44:00 +0000 |
|---|---|---|
| committer | Christian Marangi | 2025-05-01 23:34:20 +0000 |
| commit | 24d7b20cf54ce827f747dae1899875310506041c (patch) | |
| tree | c0b57256b45dcbeae50306c1102d00ee37c1f76f | |
| parent | 8316a3013f2402457dc2ab012f0b7e0833e43faf (diff) | |
| download | openwrt-24d7b20cf54ce827f747dae1899875310506041c.tar.gz | |
ramips: pwm: use remove_new
Easy way to add compatibility for kernel 6.12.
Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/18660
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
| -rw-r--r-- | target/linux/ramips/patches-6.6/845-pwm-add-mediatek-support.patch | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/target/linux/ramips/patches-6.6/845-pwm-add-mediatek-support.patch b/target/linux/ramips/patches-6.6/845-pwm-add-mediatek-support.patch index e7d11a0429..57e87e978c 100644 --- a/target/linux/ramips/patches-6.6/845-pwm-add-mediatek-support.patch +++ b/target/linux/ramips/patches-6.6/845-pwm-add-mediatek-support.patch @@ -41,7 +41,7 @@ Signed-off-by: John Crispin <blogic@openwrt.org> obj-$(CONFIG_PWM_MXS) += pwm-mxs.o --- /dev/null +++ b/drivers/pwm/pwm-mediatek-ramips.c -@@ -0,0 +1,187 @@ +@@ -0,0 +1,185 @@ +/* + * Mediatek Pulse Width Modulator driver + * @@ -197,15 +197,13 @@ Signed-off-by: John Crispin <blogic@openwrt.org> + return devm_pwmchip_add(&pdev->dev, &pc->chip); +} + -+static int mtk_pwm_remove(struct platform_device *pdev) ++static void mtk_pwm_remove(struct platform_device *pdev) +{ + struct mtk_pwm_chip *pc = platform_get_drvdata(pdev); + int i; + + for (i = 0; i < NUM_PWM; i++) + pwm_disable(&pc->chip.pwms[i]); -+ -+ return 0; +} + +static const struct of_device_id mtk_pwm_of_match[] = { @@ -221,7 +219,7 @@ Signed-off-by: John Crispin <blogic@openwrt.org> + .of_match_table = mtk_pwm_of_match, + }, + .probe = mtk_pwm_probe, -+ .remove = mtk_pwm_remove, ++ .remove_new = mtk_pwm_remove, +}; + +module_platform_driver(mtk_pwm_driver); |