Skip to content

Commit

Permalink
clock-imx35: fix divider if ahb is source for ipg_per
Browse files Browse the repository at this point in the history
According to the Datasheet:
"i.MX35 (MCIMX35) Multimedia Applications Processor Reference Manual,
Rev. 2" "Table 14-6. PDR0 Field Descriptions" the divider is
CCM_PER_AHB[3:0] + 1.

This patch adds the missing + 1.

Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Signed-off-by: Michael Grzeschik <m.grzeschik@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
  • Loading branch information
Marc Kleine-Budde authored and Sascha Hauer committed Aug 17, 2010
1 parent 9a6f17f commit c96c1e3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/arm/mach-mx3/clock-imx35.c
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@ static unsigned long get_rate_ipg_per(struct clk *clk)
return get_rate_arm() / (div + 1);
} else {
div = (pdr0 >> 12) & 0x7;
return get_rate_ahb(NULL) / div;
return get_rate_ahb(NULL) / (div + 1);
}
}

Expand Down

0 comments on commit c96c1e3

Please sign in to comment.