2 * Copyright 2012 Actions Semi Inc.
3 * Author: Actions Semi, Inc.
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License as published by the
7 * Free Software Foundation; either version 2 of the License, or (at your
8 * option) any later version.
11 #include <linux/linkage.h>
12 #include <linux/init.h>
14 ENTRY(owl_v7_invalidate_l1)
16 mcr p15, 0, r0, c7, c5, 0 @ invalidate I cache
17 mcr p15, 2, r0, c0, c0, 0
18 mrc p15, 1, r0, c0, c0, 0
21 and r2, r1, r0, lsr #13
25 and r3, r1, r0, lsr #3 @ NumWays - 1
26 add r2, r2, #1 @ NumSets
29 add r0, r0, #4 @ SetShift
32 add r4, r3, #1 @ NumWays
33 1: sub r2, r2, #1 @ NumSets--
34 mov r3, r4 @ Temp = NumWays
35 2: subs r3, r3, #1 @ Temp--
38 orr r5, r5, r6 @ Reg = (Temp<<WayShift)|(NumSets<<SetShift)
39 mcr p15, 0, r5, c7, c6, 2
46 ENDPROC(owl_v7_invalidate_l1)
48 ENTRY(owl_secondary_startup)
49 mrc p15, 0, r0, c0, c0, 5
61 * we've been released from the holding pen: secondary_stack
62 * should now contain the SVC stack for this core
64 bl owl_v7_invalidate_l1