diff options
| author | Matthias Kaehlcke <[email protected]> | 2017-07-31 18:37:28 +0000 |
|---|---|---|
| committer | Daniel Lezcano <[email protected]> | 2017-08-10 12:48:17 +0000 |
| commit | d197f7988721221fac64f899efd7657c15281810 (patch) | |
| tree | 82d4093b5b9c6cda12750553442887be788f0f2a /tools/perf/python/tracepoint.py | |
| parent | timers: Fix overflow in get_next_timer_interrupt (diff) | |
| download | kernel-d197f7988721221fac64f899efd7657c15281810.tar.gz kernel-d197f7988721221fac64f899efd7657c15281810.zip | |
clocksource/drivers/arm_arch_timer: Fix mem frame loop initialization
The loop to find the best memory frame in arch_timer_mem_acpi_init()
initializes the loop counter with itself ('i = i'), which is suspicious
in the first place and pointed out by clang. The loop condition is
'i < timer_count' and a prior for loop exits when 'i' reaches
'timer_count', therefore the second loop is never executed.
Initialize the loop counter with 0 to iterate over all timers, which
supposedly was the intention before the typo monster attacked.
Fixes: c2743a36765d3 ("clocksource: arm_arch_timer: add GTDT support for memory-mapped timer")
Signed-off-by: Matthias Kaehlcke <[email protected]>
Reported-by: Ard Biesheuvel <[email protected]>
Acked-by: Mark Rutland <[email protected]>
Signed-off-by: Daniel Lezcano <[email protected]>
Diffstat (limited to 'tools/perf/python/tracepoint.py')
0 files changed, 0 insertions, 0 deletions
