summaryrefslogtreecommitdiff
path: root/board
diff options
context:
space:
mode:
authorTom Rini <trini@ti.com>2014-06-05 11:15:27 -0400
committerTom Rini <trini@ti.com>2014-06-06 17:46:16 -0400
commitfeca6e676e99102d2044b4baea433b7e6784189f (patch)
tree62045f95b2ac6a04dfe041044a44e551a2a26d3c /board
parent1ab6f61a1afb71708f254ec9150067f47c218ba7 (diff)
am43xx: Only read the MPU frequency bits of CTRL_DEV_ATTR
Signed-off-by: Tom Rini <trini@ti.com>
Diffstat (limited to 'board')
-rw-r--r--board/ti/am43xx/board.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/board/ti/am43xx/board.c b/board/ti/am43xx/board.c
index 587fd76859a..b635d691bfb 100644
--- a/board/ti/am43xx/board.c
+++ b/board/ti/am43xx/board.c
@@ -302,7 +302,10 @@ static u32 get_sys_clk_index(void)
static int get_opp_offset(int max_off, int min_off)
{
struct ctrl_stat *ctrl = (struct ctrl_stat *)CTRL_BASE;
- int opp = readl(&ctrl->dev_attr), offset, i;
+ int opp, offset, i;
+
+ /* Bits 0:11 are defined to be the MPU_MAX_FREQ */
+ opp = readl(&ctrl->dev_attr) & ~0xFFFFF000;
for (i = max_off; i >= min_off; i--) {
offset = opp & (1 << i);