mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-27 14:14:24 +08:00
aa172ba739
Currently, led pattern trigger uses timer_list to schedule brightness changing. As we know from timer_list API [1], it's not accurate to milliseconds and depends on HZ granularity. Example: "0 10 0 0 50 10 50 0 100 10 100 0 150 10 150 0 200 10 200 0 250 10 250 0", we expect it to be 60ms long, but it can actually be up to ~120ms (add ~10ms for each pattern when HZ == 100). But sometimes, userspace needs time accurate led patterns to make sure that pattern will be executed during expected time slot. To achieve this goal the patch introduces optional hrtimer usage for led trigger pattern, because hrtimer is microseconds accurate timer. [1]: kernel/time/timer.c#L104 Signed-off-by: Martin Kurbanov <mmkurbanov@salutedevices.com> Link: https://lore.kernel.org/r/20240416201847.357099-1-mmkurbanov@salutedevices.com Signed-off-by: Lee Jones <lee@kernel.org> |
||
---|---|---|
.. | ||
Kconfig | ||
ledtrig-activity.c | ||
ledtrig-backlight.c | ||
ledtrig-camera.c | ||
ledtrig-cpu.c | ||
ledtrig-default-on.c | ||
ledtrig-disk.c | ||
ledtrig-gpio.c | ||
ledtrig-heartbeat.c | ||
ledtrig-mtd.c | ||
ledtrig-netdev.c | ||
ledtrig-oneshot.c | ||
ledtrig-panic.c | ||
ledtrig-pattern.c | ||
ledtrig-timer.c | ||
ledtrig-transient.c | ||
ledtrig-tty.c | ||
Makefile |