Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

clocksource/drivers/samsung_pwm: Minor whitespace cleanup

Cleanup the code to be slightly more readable and follow coding
convention - only whitespace. This fixes checkpatch warnings:

WARNING: Block comments should align the * on each line
WARNING: please, no space before tabs
WARNING: Missing a blank line after declarations
CHECK: Alignment should match open parenthesis

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
Link: https://lore.kernel.org/r/20210506202729.157260-1-krzysztof.kozlowski@canonical.com

authored by

Krzysztof Kozlowski and committed by
Daniel Lezcano
a0143f5a 4f9f4f0f

+13 -9
+11 -8
drivers/clocksource/samsung_pwm_timer.c
··· 4 4 * http://www.samsung.com/ 5 5 * 6 6 * samsung - Common hr-timer support (s3c and s5p) 7 - */ 7 + */ 8 8 9 9 #include <linux/interrupt.h> 10 10 #include <linux/irq.h> ··· 22 22 23 23 #include <clocksource/samsung_pwm.h> 24 24 25 - 26 25 /* 27 26 * Clocksource driver 28 27 */ ··· 37 38 #define TCFG0_PRESCALER_MASK 0xff 38 39 #define TCFG0_PRESCALER1_SHIFT 8 39 40 40 - #define TCFG1_SHIFT(x) ((x) * 4) 41 - #define TCFG1_MUX_MASK 0xf 41 + #define TCFG1_SHIFT(x) ((x) * 4) 42 + #define TCFG1_MUX_MASK 0xf 42 43 43 44 /* 44 45 * Each channel occupies 4 bits in TCON register, but there is a gap of 4 ··· 182 183 } 183 184 184 185 static int samsung_set_next_event(unsigned long cycles, 185 - struct clock_event_device *evt) 186 + struct clock_event_device *evt) 186 187 { 187 188 /* 188 189 * This check is needed to account for internal rounding ··· 224 225 225 226 if (pwm.variant.has_tint_cstat) { 226 227 u32 mask = (1 << pwm.event_id); 228 + 227 229 writel(mask | (mask << 5), pwm.base + REG_TINT_CSTAT); 228 230 } 229 231 } ··· 248 248 249 249 if (pwm.variant.has_tint_cstat) { 250 250 u32 mask = (1 << pwm.event_id); 251 + 251 252 writel(mask | (mask << 5), pwm.base + REG_TINT_CSTAT); 252 253 } 253 254 ··· 273 272 274 273 time_event_device.cpumask = cpumask_of(0); 275 274 clockevents_config_and_register(&time_event_device, 276 - clock_rate, 1, pwm.tcnt_max); 275 + clock_rate, 1, pwm.tcnt_max); 277 276 278 277 irq_number = pwm.irq[pwm.event_id]; 279 278 if (request_irq(irq_number, samsung_clock_event_isr, ··· 283 282 284 283 if (pwm.variant.has_tint_cstat) { 285 284 u32 mask = (1 << pwm.event_id); 285 + 286 286 writel(mask | (mask << 5), pwm.base + REG_TINT_CSTAT); 287 287 } 288 288 } ··· 349 347 pwm.source_reg = pwm.base + pwm.source_id * 0x0c + 0x14; 350 348 351 349 sched_clock_register(samsung_read_sched_clock, 352 - pwm.variant.bits, clock_rate); 350 + pwm.variant.bits, clock_rate); 353 351 354 352 samsung_clocksource.mask = CLOCKSOURCE_MASK(pwm.variant.bits); 355 353 return clocksource_register_hz(&samsung_clocksource, clock_rate); ··· 400 398 } 401 399 402 400 void __init samsung_pwm_clocksource_init(void __iomem *base, 403 - unsigned int *irqs, struct samsung_pwm_variant *variant) 401 + unsigned int *irqs, 402 + struct samsung_pwm_variant *variant) 404 403 { 405 404 pwm.base = base; 406 405 memcpy(&pwm.variant, variant, sizeof(pwm.variant));
+2 -1
include/clocksource/samsung_pwm.h
··· 27 27 }; 28 28 29 29 void samsung_pwm_clocksource_init(void __iomem *base, 30 - unsigned int *irqs, struct samsung_pwm_variant *variant); 30 + unsigned int *irqs, 31 + struct samsung_pwm_variant *variant); 31 32 32 33 #endif /* __CLOCKSOURCE_SAMSUNG_PWM_H */