diff options
Diffstat (limited to 'include/asm-mips/hazards.h')
-rw-r--r-- | include/asm-mips/hazards.h | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/include/asm-mips/hazards.h b/include/asm-mips/hazards.h index e50c77e69cb5..1542f23ab9d9 100644 --- a/include/asm-mips/hazards.h +++ b/include/asm-mips/hazards.h | |||
@@ -178,4 +178,36 @@ ASMMACRO(back_to_back_c0_hazard, | |||
178 | 178 | ||
179 | #endif | 179 | #endif |
180 | 180 | ||
181 | |||
182 | /* FPU hazards */ | ||
183 | |||
184 | #if defined(CONFIG_CPU_SB1) | ||
185 | ASMMACRO(enable_fpu_hazard, | ||
186 | .set push; | ||
187 | .set mips64; | ||
188 | .set noreorder; | ||
189 | _ssnop; | ||
190 | bnezl $0,.+4; | ||
191 | _ssnop | ||
192 | .set pop | ||
193 | ) | ||
194 | ASMMACRO(disable_fpu_hazard, | ||
195 | ) | ||
196 | |||
197 | #elif defined(CONFIG_CPU_MIPSR2) | ||
198 | ASMMACRO(enable_fpu_hazard, | ||
199 | _ehb | ||
200 | ) | ||
201 | ASMMACRO(disable_fpu_hazard, | ||
202 | _ehb | ||
203 | ) | ||
204 | #else | ||
205 | ASMMACRO(enable_fpu_hazard, | ||
206 | nop; nop; nop; nop | ||
207 | ) | ||
208 | ASMMACRO(disable_fpu_hazard, | ||
209 | _ehb | ||
210 | ) | ||
211 | #endif | ||
212 | |||
181 | #endif /* _ASM_HAZARDS_H */ | 213 | #endif /* _ASM_HAZARDS_H */ |