Skip to contentSkip to conversation

clocksource/drivers/timer-ti-dm: Fix finding alwon timer

PATCH Applied Tony Lindgren 3 participants 3 messages Apr 12, 2023 – Apr 26, 2023 Clocksource, clockevent drivers

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 clocksource/drivers/timer-ti-dm: Fix finding alwon timer

Clean-up commit b6999fa1c847 ("clocksource/drivers/timer-ti-dm: Use of_address_to_resource()") caused a regression where pa is never set making all related SoCs fail to boot. Let's fix this by setting pa if found.

Fixes b6999fa1c847 ("clocksource/drivers/timer-ti-dm: Use of_address_to_resource()")
Cc Rob Herring <[email protected]>
---
 drivers/clocksource/timer-ti-dm-systimer.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/clocksource/timer-ti-dm-systimer.c +3 -1
@@ -261,8 +261,10 @@ static void __init dmtimer_systimer_assign_alwon(void)
 		if (of_address_to_resource(np, 0, &res))
 			continue;
 
+		pa = res.start;
+
 		/* Quirky omap3 boards must use dmtimer12 */
-		if (quirk_unreliable_oscillator && res.start == 0x48318000)
+		if (quirk_unreliable_oscillator && pa == 0x48318000)
 			continue;
 
 		of_node_put(np);
Signature · 6 lines
2.40.0

_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
#1 lore raw
Quoted 9 lines · Tony Lindgren

Clean-up commit b6999fa1c847 ("clocksource/drivers/timer-ti-dm: Use of_address_to_resource()") caused a regression where pa is never set making all related SoCs fail to boot. Let's fix this by setting pa if found.

Fixes b6999fa1c847 ("clocksource/drivers/timer-ti-dm: Use of_address_to_resource()")
Cc Rob Herring <[email protected]>

---

Applied, thanks

Signature · 11 lines
<http://www.linaro.org/> Linaro.org │ Open source software for ARM SoCs

Follow Linaro:  <http://www.facebook.com/pages/Linaro> Facebook |
<http://twitter.com/#!/linaroorg> Twitter |
<http://www.linaro.org/linaro-blog/> Blog


_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
merge bot Applied
#2 lore raw
In reply to Tony Lindgren
The following commit has been merged into the timers/core branch of tip:

The following commit has been merged into the timers/core branch of tip:

Commit-ID:     8d7aac5153f21108365137b76e395dcf9bb3a800
Gitweb:        https://git.kernel.org/tip/8d7aac5153f21108365137b76e395dcf9bb3a800
Author:        Tony Lindgren <[email protected]>
AuthorDate:    Wed, 12 Apr 2023 09:41:41 +03:00
Committer:     Daniel Lezcano <[email protected]>
CommitterDate: Mon, 24 Apr 2023 16:56:14 +02:00

clocksource/drivers/timer-ti-dm: Fix finding alwon timer

Clean-up commit b6999fa1c847 ("clocksource/drivers/timer-ti-dm: Use of_address_to_resource()") caused a regression where pa is never set making all related SoCs fail to boot. Let's fix this by setting pa if found.

Fixes b6999fa1c847 ("clocksource/drivers/timer-ti-dm: Use of_address_to_resource()")
Cc Rob Herring <[email protected]>
---
 drivers/clocksource/timer-ti-dm-systimer.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/clocksource/timer-ti-dm-systimer.c +3 -1
index 3b98a3c..4fa68f6 100644
@@ -261,8 +261,10 @@ static void __init dmtimer_systimer_assign_alwon(void)
 		if (of_address_to_resource(np, 0, &res))
 			continue;
 
+		pa = res.start;
+
 		/* Quirky omap3 boards must use dmtimer12 */
-		if (quirk_unreliable_oscillator && res.start == 0x48318000)
+		if (quirk_unreliable_oscillator && pa == 0x48318000)
 			continue;
 
 		of_node_put(np);