Skip to content

Commit

Permalink
ARM: at91/clock: fix PLLA overclock warning
Browse files Browse the repository at this point in the history
Fix PLLA overclock warning in relation with datasheet numbers.
Add new > 240 MHz and > 210 MHz SoC categories.

Reported-by: Jiri Prchal <jiri.prchal@aksignal.cz>
Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
  • Loading branch information
Nicolas Ferre committed Aug 23, 2012
1 parent e402af6 commit 2ed1f58
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions arch/arm/mach-at91/clock.c
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,12 @@ EXPORT_SYMBOL_GPL(at91_pmc_base);

#define cpu_has_300M_plla() (cpu_is_at91sam9g10())

#define cpu_has_240M_plla() (cpu_is_at91sam9261() \
|| cpu_is_at91sam9263() \
|| cpu_is_at91sam9rl())

#define cpu_has_210M_plla() (cpu_is_at91sam9260())

#define cpu_has_pllb() (!(cpu_is_at91sam9rl() \
|| cpu_is_at91sam9g45() \
|| cpu_is_at91sam9x5() \
Expand Down Expand Up @@ -706,6 +712,12 @@ static int __init at91_pmc_init(unsigned long main_clock)
} else if (cpu_has_800M_plla()) {
if (plla.rate_hz > 800000000)
pll_overclock = true;
} else if (cpu_has_240M_plla()) {
if (plla.rate_hz > 240000000)
pll_overclock = true;
} else if (cpu_has_210M_plla()) {
if (plla.rate_hz > 210000000)
pll_overclock = true;
} else {
if (plla.rate_hz > 209000000)
pll_overclock = true;
Expand Down

0 comments on commit 2ed1f58

Please sign in to comment.