gjdwebserver-overlay/dev-embedded/u-boot-pinephone-pro/files/1007-Improve-Allwinner-A64-timer-workaround.patch
2022-07-09 19:38:06 +02:00

12 lines
500 B
Diff

--- u-boot-c784be467aa7d111f149c2a54557e8828bc5775a/arch/arm/cpu/armv8/generic_timer.c.orig 2021-03-10 18:44:07.000000000 +0100
+++ u-boot-c784be467aa7d111f149c2a54557e8828bc5775a/arch/arm/cpu/armv8/generic_timer.c 2021-05-22 21:36:48.565156255 +0200
@@ -69,7 +69,7 @@ unsigned long timer_read_counter(void)
isb();
do {
asm volatile("mrs %0, cntpct_el0" : "=r" (cntpct));
- } while (((cntpct + 1) & GENMASK(10, 0)) <= 1);
+ } while (((cntpct + 1) & GENMASK(8, 0)) <= 1);
return cntpct;
}