From 11ad39ede24ee42909d58dc95031d96da46e33bd Mon Sep 17 00:00:00 2001 From: Tomasz Figa Date: Sat, 6 Apr 2013 02:40:36 +0200 Subject: pwm: Add new pwm-samsung driver This patch introduces new Samsung PWM driver, which is completely rewritten to be multiplatform- and DeviceTree-aware. In addition, remaining problems of old driver are fixed, such as: - proper handling of hardware variants, - synchronization on SMP systems, - handling of boundary parameter values, - hardware sharing with PWM clocksource driver, - undefined state of PWM output after stopping PWM channel. Signed-off-by: Tomasz Figa Reviewed-by: Sylwester Nawrocki Tested-by: Heiko Stuebner Tested-by: Mark Brown Tested-by: Sylwester Nawrocki Acked-by: Arnd Bergmann Acked-by: Thierry Reding --- include/clocksource/samsung_pwm.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'include/clocksource') diff --git a/include/clocksource/samsung_pwm.h b/include/clocksource/samsung_pwm.h index 5c449c8199e9..0c7d48b8b396 100644 --- a/include/clocksource/samsung_pwm.h +++ b/include/clocksource/samsung_pwm.h @@ -20,7 +20,14 @@ #define SAMSUNG_PWM_NUM 5 +/* + * Following declaration must be in an ifdef due to this symbol being static + * in pwm-samsung driver if the clocksource driver is not compiled in and the + * spinlock is not shared between both drivers. + */ +#ifdef CONFIG_CLKSRC_SAMSUNG_PWM extern spinlock_t samsung_pwm_lock; +#endif struct samsung_pwm_variant { u8 bits; -- cgit v1.2.3-59-g8ed1b