Changeset 407 for trunk/hal/tsar_mips32/core/hal_special.c
- Timestamp:
- Nov 7, 2017, 3:08:12 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/hal/tsar_mips32/core/hal_special.c
r406 r407 31 31 32 32 struct thread_s; 33 34 /////////////////////////////////35 void hal_set_ebase( reg_t base )36 {37 asm volatile ("mtc0 %0, $15, 1" : : "r" (base));38 }39 33 40 34 ////////////////////////// … … 200 194 void hal_fence() 201 195 { 202 asm volatile 203 ( "sync \n":: ); 196 asm volatile ("sync"); 204 197 } 205 198 … … 213 206 void hal_core_sleep() 214 207 { 215 asm volatile 216 ("wait \n"::); 208 asm volatile ("wait"); 217 209 } 218 210 … … 221 213 { 222 214 asm volatile 223 ( " 1:\n"215 ( ".set noreorder \n" 224 216 "or $27, %0, $0 \n" 217 "1: \n" 225 218 "addi $27, $27, -1 \n" 219 "nop \n" 226 220 "bne $27, $0, 1b \n" 227 221 "nop \n" 228 : : "r" (delay) : "$27" ); 222 ".set reorder \n" 223 : : "r" (delay>>2) : "$27" ); 229 224 } 230 225
Note: See TracChangeset
for help on using the changeset viewer.