diff options
author | Graf Yang <graf.yang@analog.com> | 2009-01-07 10:14:39 -0500 |
---|---|---|
committer | Bryan Wu <cooloney@kernel.org> | 2009-01-07 10:14:39 -0500 |
commit | 6b3087c64a92a36ae20d33479b4df6d7afc910d4 (patch) | |
tree | 95984fc623658ebf150d0d912a7f6c5a0301a5a9 /arch/blackfin/mach-common/cache.S | |
parent | c51b4488cd5bff08ed5690a8f303ff7f0894da2a (diff) |
Blackfin arch: SMP supporting patchset: Blackfin header files and machine common code
Blackfin dual core BF561 processor can support SMP like features.
https://docs.blackfin.uclinux.org/doku.php?id=linux-kernel:smp-like
In this patch, we provide SMP extend to Blackfin header files
and machine common code
Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Diffstat (limited to 'arch/blackfin/mach-common/cache.S')
-rw-r--r-- | arch/blackfin/mach-common/cache.S | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/arch/blackfin/mach-common/cache.S b/arch/blackfin/mach-common/cache.S index 3c98dacbf289..118751287437 100644 --- a/arch/blackfin/mach-common/cache.S +++ b/arch/blackfin/mach-common/cache.S | |||
@@ -97,3 +97,39 @@ ENTRY(_blackfin_dflush_page) | |||
97 | P1 = 1 << (PAGE_SHIFT - L1_CACHE_SHIFT); | 97 | P1 = 1 << (PAGE_SHIFT - L1_CACHE_SHIFT); |
98 | jump .Ldfr; | 98 | jump .Ldfr; |
99 | ENDPROC(_blackfin_dflush_page) | 99 | ENDPROC(_blackfin_dflush_page) |
100 | |||
101 | /* Invalidate the Entire Data cache by | ||
102 | * clearing DMC[1:0] bits | ||
103 | */ | ||
104 | ENTRY(_blackfin_invalidate_entire_dcache) | ||
105 | [--SP] = ( R7:5); | ||
106 | |||
107 | P0.L = LO(DMEM_CONTROL); | ||
108 | P0.H = HI(DMEM_CONTROL); | ||
109 | R7 = [P0]; | ||
110 | R5 = R7; /* Save DMEM_CNTR */ | ||
111 | |||
112 | /* Clear the DMC[1:0] bits, All valid bits in the data | ||
113 | * cache are set to the invalid state | ||
114 | */ | ||
115 | BITCLR(R7,DMC0_P); | ||
116 | BITCLR(R7,DMC1_P); | ||
117 | CLI R6; | ||
118 | SSYNC; /* SSYNC required before writing to DMEM_CONTROL. */ | ||
119 | .align 8; | ||
120 | [P0] = R7; | ||
121 | SSYNC; | ||
122 | STI R6; | ||
123 | |||
124 | /* Configures the data cache again */ | ||
125 | |||
126 | CLI R6; | ||
127 | SSYNC; /* SSYNC required before writing to DMEM_CONTROL. */ | ||
128 | .align 8; | ||
129 | [P0] = R5; | ||
130 | SSYNC; | ||
131 | STI R6; | ||
132 | |||
133 | ( R7:5) = [SP++]; | ||
134 | RTS; | ||
135 | ENDPROC(_blackfin_invalidate_entire_dcache) | ||