blob: 01426f155af538286bde4984e8865c1cc1567ff0 [file] [log] [blame]
developer5c8aa182023-12-29 16:35:46 +08001From 102d3751ff3a46edf91c96490a9c7bd2d32e788a Mon Sep 17 00:00:00 2001
2From: Maso Huang <maso.huang@mediatek.com>
3Date: Fri, 29 Dec 2023 16:26:16 +0800
4Subject: [PATCH] add pwm-gpio support
5
6---
7 drivers/pwm/Kconfig | 10 ++++++++++
8 drivers/pwm/Makefile | 1 +
9 2 files changed, 11 insertions(+)
10
11diff --git a/drivers/pwm/Kconfig b/drivers/pwm/Kconfig
12index e3a2518..9b2200c 100644
13--- a/drivers/pwm/Kconfig
14+++ b/drivers/pwm/Kconfig
15@@ -171,6 +171,16 @@ config PWM_FSL_FTM
16 To compile this driver as a module, choose M here: the module
17 will be called pwm-fsl-ftm.
18
19+config PWM_GPIO
20+ tristate "GPIO PWM support"
21+ depends on OF && GPIOLIB
22+ help
23+ Generic PWM framework driver for a software PWM toggling a GPIO pin
24+ from kernel high-resolution timers.
25+
26+ To compile this driver as a module, choose M here: the module
27+ will be called pwm-gpio.
28+
29 config PWM_HIBVT
30 tristate "HiSilicon BVT PWM support"
31 depends on ARCH_HISI || COMPILE_TEST
32diff --git a/drivers/pwm/Makefile b/drivers/pwm/Makefile
33index 26326ad..034c1d0 100644
34--- a/drivers/pwm/Makefile
35+++ b/drivers/pwm/Makefile
36@@ -15,6 +15,7 @@ obj-$(CONFIG_PWM_CRC) += pwm-crc.o
37 obj-$(CONFIG_PWM_CROS_EC) += pwm-cros-ec.o
38 obj-$(CONFIG_PWM_EP93XX) += pwm-ep93xx.o
39 obj-$(CONFIG_PWM_FSL_FTM) += pwm-fsl-ftm.o
40+obj-$(CONFIG_PWM_GPIO) += pwm-gpio.o
41 obj-$(CONFIG_PWM_HIBVT) += pwm-hibvt.o
42 obj-$(CONFIG_PWM_IMG) += pwm-img.o
43 obj-$(CONFIG_PWM_IMX1) += pwm-imx1.o
44--
452.18.0
46