]> git.baikalelectronics.ru Git - kernel.git/commit
clocksource/drivers/dw_apb_timer_of: Add error handling if no clock available
authorDinh Nguyen <dinguyen@kernel.org>
Sat, 5 Dec 2020 10:52:23 +0000 (04:52 -0600)
committerDaniel Lezcano <daniel.lezcano@linaro.org>
Sat, 5 Dec 2020 18:33:55 +0000 (19:33 +0100)
commitb9d582f0c9ab28bc43aaa42205fe587e10e113e0
tree507e92555147562b03cfdff83ee06eefd35d4162
parent1ccc1ea7e8614ab1b932a810b912dfeb2162c7fc
clocksource/drivers/dw_apb_timer_of: Add error handling if no clock available

commit ("fab44257ee47 arm64: berlin: Select DW_APB_TIMER_OF") added the
support for the dw_apb_timer into the arm64 defconfig. However, for some
platforms like the Intel Stratix10 and Agilex, the clock manager doesn't
get loaded until after the timer driver get loaded. Thus, the driver hits
the panic "No clock nor clock-frequency property for" because it cannot
properly get the clock.

This patch adds the error handling needed for the timer driver so that
the kernel can continue booting instead of just hitting the panic.

Signed-off-by: Dinh Nguyen <dinguyen@kernel.org>
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
Link: https://lore.kernel.org/r/20201205105223.208604-1-dinguyen@kernel.org
drivers/clocksource/dw_apb_timer_of.c