Skip to content

Commit b34b954

Browse files
xdarklightdlezcano
authored andcommitted
clocksource/drivers/arm_global_timer: Fix maximum prescaler value
The prescaler in the "Global Timer Control Register bit assignments" is documented to use bits [15:8], which means that the maximum prescaler register value is 0xff. Fixes: 171b45a ("clocksource/drivers/arm_global_timer: Implement rate compensation whenever source clock changes") Signed-off-by: Martin Blumenstingl <[email protected]> Signed-off-by: Daniel Lezcano <[email protected]> Link: https://lore.kernel.org/r/[email protected]
1 parent b67686e commit b34b954

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/clocksource/arm_global_timer.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
#define GT_CONTROL_IRQ_ENABLE BIT(2) /* banked */
3333
#define GT_CONTROL_AUTO_INC BIT(3) /* banked */
3434
#define GT_CONTROL_PRESCALER_SHIFT 8
35-
#define GT_CONTROL_PRESCALER_MAX 0xF
35+
#define GT_CONTROL_PRESCALER_MAX 0xFF
3636
#define GT_CONTROL_PRESCALER_MASK (GT_CONTROL_PRESCALER_MAX << \
3737
GT_CONTROL_PRESCALER_SHIFT)
3838

0 commit comments

Comments
 (0)