Age | Commit message (Collapse) | Author | Files | Lines |
|
Currently, quite a few clockevent devices have cpumask set to
cpu_all_mask which should be fine. However, cpu_possible_mask is more
accurate and if there are any other clockevent devices in the system
which have cpumask set to cpu_possible_mask, then having cpu_all_mask
may result in issues (mostly boot hang with forever loops in
clockevents_notify_released).
So, lets replace all the clockevent device cpu_all_mask to
cpu_possible_mask in order to prevent above mentioned possible issue.
Cc: Daniel Lezcano <[email protected]>
Cc: Thomas Gleixner <[email protected]>
Cc: Thierry Reding <[email protected]>
Cc: Jonathan Hunter <[email protected]>
Cc: Santosh Shilimkar <[email protected]>
Signed-off-by: Sudeep Holla <[email protected]>
Signed-off-by: Daniel Lezcano <[email protected]>
|
|
The CLOCKSOURCE_OF_DECLARE macro is used widely for the timers to declare the
clocksource at early stage. However, this macro is also used to initialize
the clockevent if any, or the clockevent only.
It was originally suggested to declare another macro to initialize a
clockevent, so in order to separate the two entities even they belong to the
same IP. This was not accepted because of the impact on the DT where splitting
a clocksource/clockevent definition does not make sense as it is a Linux
concept not a hardware description.
On the other side, the clocksource has not interrupt declared while the
clockevent has, so it is easy from the driver to know if the description is
for a clockevent or a clocksource, IOW it could be implemented at the driver
level.
So instead of dealing with a named clocksource macro, let's use a more generic
one: TIMER_OF_DECLARE.
The patch has not functional changes.
Signed-off-by: Daniel Lezcano <[email protected]>
Acked-by: Heiko Stuebner <[email protected]>
Acked-by: Neil Armstrong <[email protected]>
Acked-by: Arnd Bergmann <[email protected]>
Acked-by: Matthias Brugger <[email protected]>
Reviewed-by: Linus Walleij <[email protected]>
|
|
All the clocksource drivers's init function are now converted to return
an error code. CLOCKSOURCE_OF_DECLARE is no longer used as well as the
clksrc-of table.
Let's convert back the names:
- CLOCKSOURCE_OF_DECLARE_RET => CLOCKSOURCE_OF_DECLARE
- clksrc-of-ret => clksrc-of
Signed-off-by: Daniel Lezcano <[email protected]>
For exynos_mct and samsung_pwm_timer:
Acked-by: Krzysztof Kozlowski <[email protected]>
For arch/arc:
Acked-by: Vineet Gupta <[email protected]>
For mediatek driver:
Acked-by: Matthias Brugger <[email protected]>
For the Rockchip-part
Acked-by: Heiko Stuebner <[email protected]>
For STi :
Acked-by: Patrice Chotard <[email protected]>
For the mps2-timer.c and versatile.c changes:
Acked-by: Liviu Dudau <[email protected]>
For the OXNAS part :
Acked-by: Neil Armstrong <[email protected]>
For LPC32xx driver:
Acked-by: Sylvain Lemieux <[email protected]>
For Broadcom Kona timer change:
Acked-by: Ray Jui <[email protected]>
For Sun4i and Sun5i:
Acked-by: Chen-Yu Tsai <[email protected]>
For Meson6:
Acked-by: Carlo Caione <[email protected]>
For Keystone:
Acked-by: Santosh Shilimkar <[email protected]>
For NPS:
Acked-by: Noam Camus <[email protected]>
For bcm2835:
Acked-by: Eric Anholt <[email protected]>
|
|
The init functions do not return any error. They behave as the following:
- panic, thus leading to a kernel crash while another timer may work and
make the system boot up correctly
or
- print an error and let the caller unaware if the state of the system
Change that by converting the init functions to return an error conforming
to the CLOCKSOURCE_OF_RET prototype.
Proper error handling (rollback, errno value) will be changed later case
by case, thus this change just return back an error or success in the init
function.
Signed-off-by: Daniel Lezcano <[email protected]>
Acked-by: Santosh Shilimkar <[email protected]>
|
|
The current code assumes the 'irq_of_parse_and_map' will return NO_IRQ in case
of failure. Unfortunately, the NO_IRQ is not consistent across the different
architectures and we must not rely on it.
NO_IRQ is equal to '-1' on ARM and 'irq_of_parse_and_map' returns '0' in case
of an error. Hence, the latter won't be detected and will lead to a crash.
Fix this by just checking 'irq' is different from zero.
Signed-off-by: Daniel Lezcano <[email protected]>
|
|
Migrate keystone driver to the new 'set-state' interface provided by
clockevents core, the earlier 'set-mode' interface is marked obsolete
now.
This also enables us to implement callbacks for new states of clockevent
devices, for example: ONESHOT_STOPPED.
Also pass the mode-mask to keystone_timer_config() instead of the mode
as mode macro's aren't valid anymore.
Cc: Santosh Shilimkar <[email protected]>
Signed-off-by: Viresh Kumar <[email protected]>
Signed-off-by: Daniel Lezcano <[email protected]>
|
|
Commit 438e0bff5257 added the timer-keystone device driver but make use
of an unnecessary variable in the init function. This patch deletes this
variable.
Signed-off-by: Matthias Brugger <[email protected]>
Signed-off-by: Daniel Lezcano <[email protected]>
|
|
Add broadcast clock-event device for the Keystone arch.
The timer can be configured as a general-purpose 64-bit timer,
dual general-purpose 32-bit timers. When configured as dual 32-bit
timers, each half can operate in conjunction (chain mode) or
independently (unchained mode) of each other.
Reviewed-by: Stephen Boyd <[email protected]>
Acked-by: Santosh shilimkar <[email protected]>
Signed-off-by: Ivan Khoronzhuk <[email protected]>
Signed-off-by: Daniel Lezcano <[email protected]>
|