diff mbox

clk2xxx.c doesn't compile if CPUFREQ is enabled

Message ID 1261784154-18550-1-git-send-email-felipe.balbi@nokia.com (mailing list archive)
State Not Applicable, archived
Delegated to: Tony Lindgren
Headers show

Commit Message

Felipe Balbi Dec. 25, 2009, 11:35 p.m. UTC
None
diff mbox

Patch

diff --git a/arch/arm/mach-omap2/clock2xxx.c b/arch/arm/mach-omap2/clock2xxx.c
index d0e3fb7..4e2bdfe 100644
--- a/arch/arm/mach-omap2/clock2xxx.c
+++ b/arch/arm/mach-omap2/clock2xxx.c
@@ -455,12 +455,15 @@  static struct cpufreq_frequency_table freq_table[ARRAY_SIZE(rate_table)];
 void omap2_clk_init_cpufreq_table(struct cpufreq_frequency_table **table)
 {
 	struct prcm_config *prcm;
+	long rate;
 	int i = 0;
 
+	rate = clk_get_rate(sclk);
+
 	for (prcm = rate_table; prcm->mpu_speed; prcm++) {
 		if (!(prcm->flags & cpu_mask))
 			continue;
-		if (prcm->xtal_speed != sys_ck.rate)
+		if (prcm->xtal_speed != rate)
 			continue;
 
 		/* don't put bypass rates in table */