Skip to content

Commit 3db1200

Browse files
frowanddlezcano
authored andcommitted
clocksource/drivers/arm_arch_timer: Fix read and iounmap of incorrect variable
Fix boot warning 'Trying to vfree() nonexistent vm area' from arch_timer_mem_of_init(). Refactored code attempts to read and iounmap using address frame instead of address ioremap(frame->cntbase). Fixes: c389d70 ("clocksource: arm_arch_timer: split MMIO timer probing.") Signed-off-by: Frank Rowand <[email protected]> Reviewed-by: Fu Wei <[email protected]> Acked-by: Marc Zyngier <[email protected]> Signed-off-by: Daniel Lezcano <[email protected]>
1 parent ff86bf0 commit 3db1200

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/clocksource/arm_arch_timer.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1209,9 +1209,9 @@ arch_timer_mem_frame_get_cntfrq(struct arch_timer_mem_frame *frame)
12091209
return 0;
12101210
}
12111211

1212-
rate = readl_relaxed(frame + CNTFRQ);
1212+
rate = readl_relaxed(base + CNTFRQ);
12131213

1214-
iounmap(frame);
1214+
iounmap(base);
12151215

12161216
return rate;
12171217
}

0 commit comments

Comments
 (0)