Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 226538
b: refs/heads/master
c: 11e0264
h: refs/heads/master
v: v3
  • Loading branch information
Mans Rullgard authored and Tony Lindgren committed Dec 18, 2010
1 parent ea9a739 commit 7838e32
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1773e60a816b28f4084810f96e9195aaaa7fb8c3
refs/heads/master: 11e0264046e00544eb044fafc27125babd105e41
17 changes: 11 additions & 6 deletions trunk/arch/arm/mach-omap2/omap4-common.c
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,6 @@ static int __init omap_l2_cache_init(void)
l2cache_base = ioremap(OMAP44XX_L2CACHE_BASE, SZ_4K);
BUG_ON(!l2cache_base);

/* Enable PL310 L2 Cache controller */
omap_smc1(0x102, 0x1);

/*
* 16-way associativity, parity disabled
* Way size - 32KB (es1.0)
Expand All @@ -79,10 +76,18 @@ static int __init omap_l2_cache_init(void)
(0x1 << L2X0_AUX_CTRL_NS_LOCKDOWN_SHIFT) |
(0x1 << L2X0_AUX_CTRL_NS_INT_CTRL_SHIFT));

if (omap_rev() == OMAP4430_REV_ES1_0)
if (omap_rev() == OMAP4430_REV_ES1_0) {
aux_ctrl |= 0x2 << L2X0_AUX_CTRL_WAY_SIZE_SHIFT;
else
aux_ctrl |= 0x3 << L2X0_AUX_CTRL_WAY_SIZE_SHIFT;
} else {
aux_ctrl |= ((0x3 << L2X0_AUX_CTRL_WAY_SIZE_SHIFT) |
(1 << L2X0_AUX_CTRL_DATA_PREFETCH_SHIFT) |
(1 << L2X0_AUX_CTRL_INSTR_PREFETCH_SHIFT));
}
if (omap_rev() != OMAP4430_REV_ES1_0)
omap_smc1(0x109, aux_ctrl);

/* Enable PL310 L2 Cache controller */
omap_smc1(0x102, 0x1);

l2x0_init(l2cache_base, aux_ctrl, L2X0_AUX_CTRL_MASK);

Expand Down

0 comments on commit 7838e32

Please sign in to comment.