Skip to content

Commit

Permalink
[ARM] pxa/cpufreq: fix index assignments for end marker
Browse files Browse the repository at this point in the history
I stumbled over two small things regarding the .index field assignment
in the dynamically created cpu frequency tables for pxa2xx and pxa3xx.

Even though that doesn't currently cause any problem, it should still be
fixed in case the logic in the CPUFREQ core changes.

Signed-off-by: Daniel Mack <daniel@caiaq.de>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
  • Loading branch information
Daniel Mack authored and Eric Miao committed Nov 20, 2009
1 parent 648f4e3 commit 68a31de
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions arch/arm/mach-pxa/cpufreq-pxa2xx.c
Original file line number Diff line number Diff line change
Expand Up @@ -447,6 +447,7 @@ static __init int pxa_cpufreq_init(struct cpufreq_policy *policy)
pxa27x_freq_table[i].frequency = freq;
pxa27x_freq_table[i].index = i;
}
pxa27x_freq_table[i].index = i;
pxa27x_freq_table[i].frequency = CPUFREQ_TABLE_END;

/*
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mach-pxa/cpufreq-pxa3xx.c
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ static int setup_freqs_table(struct cpufreq_policy *policy,
table[i].index = i;
table[i].frequency = freqs[i].cpufreq_mhz * 1000;
}
table[num].frequency = i;
table[num].index = i;
table[num].frequency = CPUFREQ_TABLE_END;

pxa3xx_freqs = freqs;
Expand Down

0 comments on commit 68a31de

Please sign in to comment.