Skip to content

Commit 7edf736

Browse files
Benjamin-GaignardLee Jones
authored andcommitted
pwm: Add driver for STM32 plaftorm
This driver adds support for PWM driver on STM32 platform. The SoC have multiple instances of the hardware IP and each of them could have small differences: number of channels, complementary output, auto reload register size... version 9: - fix commit message header - remove one space MODULE_ALIAS version 8: - fix comments done by Thierry on version 7 version 6: - change st,breakinput parameter to make it usuable for stm32f7 too. version 4: - detect at probe time hardware capabilities - fix comments done on v2 and v3 - use PWM atomic ops version 2: - only keep one comptatible - use DT parameters to discover hardware block configuration Signed-off-by: Benjamin Gaignard <[email protected]> Acked-by: Thierry Reding <[email protected]> Signed-off-by: Lee Jones <[email protected]>
1 parent cd9a99c commit 7edf736

File tree

3 files changed

+407
-0
lines changed

3 files changed

+407
-0
lines changed

drivers/pwm/Kconfig

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -397,6 +397,15 @@ config PWM_STI
397397
To compile this driver as a module, choose M here: the module
398398
will be called pwm-sti.
399399

400+
config PWM_STM32
401+
tristate "STMicroelectronics STM32 PWM"
402+
depends on MFD_STM32_TIMERS || COMPILE_TEST
403+
help
404+
Generic PWM framework driver for STM32 SoCs.
405+
406+
To compile this driver as a module, choose M here: the module
407+
will be called pwm-stm32.
408+
400409
config PWM_STMPE
401410
bool "STMPE expander PWM export"
402411
depends on MFD_STMPE

drivers/pwm/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ obj-$(CONFIG_PWM_ROCKCHIP) += pwm-rockchip.o
3838
obj-$(CONFIG_PWM_SAMSUNG) += pwm-samsung.o
3939
obj-$(CONFIG_PWM_SPEAR) += pwm-spear.o
4040
obj-$(CONFIG_PWM_STI) += pwm-sti.o
41+
obj-$(CONFIG_PWM_STM32) += pwm-stm32.o
4142
obj-$(CONFIG_PWM_STMPE) += pwm-stmpe.o
4243
obj-$(CONFIG_PWM_SUN4I) += pwm-sun4i.o
4344
obj-$(CONFIG_PWM_TEGRA) += pwm-tegra.o

0 commit comments

Comments
 (0)