Changeset 973ef9fc in mainline for kernel/arch/mips32/src
- Timestamp:
- 2010-12-25T21:20:28Z (15 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 631ee0c
- Parents:
- 1bfd3d3 (diff), 09178b7f (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)links above to see all the changes relative to each parent. - Location:
- kernel/arch/mips32/src
- Files:
-
- 6 edited
-
cache.c (modified) (1 diff)
-
debugger.c (modified) (11 diffs)
-
exception.c (modified) (1 diff)
-
mips32.c (modified) (2 diffs)
-
mm/tlb.c (modified) (3 diffs)
-
smp/dorder.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
kernel/arch/mips32/src/cache.c
r1bfd3d3 r973ef9fc 39 39 void cache_error(istate_t *istate) 40 40 { 41 panic("cache_error exception (epc=%p).", istate->epc);41 panic("cache_error exception (epc=%p).", (void *) istate->epc); 42 42 } 43 43 -
kernel/arch/mips32/src/debugger.c
r1bfd3d3 r973ef9fc 134 134 * 135 135 */ 136 bool is_jump( unative_t instr)136 bool is_jump(sysarg_t instr) 137 137 { 138 138 unsigned int i; … … 166 166 return 0; 167 167 } else if ((breakpoints[i].address == (uintptr_t) argv->intval + 168 sizeof( unative_t)) || (breakpoints[i].address ==169 (uintptr_t) argv->intval - sizeof( unative_t))) {168 sizeof(sysarg_t)) || (breakpoints[i].address == 169 (uintptr_t) argv->intval - sizeof(sysarg_t))) { 170 170 printf("Adjacent breakpoints not supported, conflict " 171 171 "with %d.\n", i); … … 191 191 } 192 192 193 printf("Adding breakpoint on address %p\n", argv->intval);193 printf("Adding breakpoint on address %p\n", (void *) argv->intval); 194 194 195 195 cur->address = (uintptr_t) argv->intval; 196 cur->instruction = (( unative_t *) cur->address)[0];197 cur->nextinstruction = (( unative_t *) cur->address)[1];196 cur->instruction = ((sysarg_t *) cur->address)[0]; 197 cur->nextinstruction = ((sysarg_t *) cur->address)[1]; 198 198 if (argv == &add_argv) { 199 199 cur->flags = 0; … … 209 209 210 210 /* Set breakpoint */ 211 *(( unative_t *) cur->address) = 0x0d;211 *((sysarg_t *) cur->address) = 0x0d; 212 212 smc_coherence(cur->address); 213 213 … … 247 247 smc_coherence(((uint32_t *) cur->address)[1]); 248 248 249 cur->address = NULL;249 cur->address = (uintptr_t) NULL; 250 250 251 251 irq_spinlock_unlock(&bkpoint_lock, true); … … 267 267 breakpoints[i].address); 268 268 269 printf("%-4u %7 " PRIs "%p %-8s %-9s %-10s %s\n", i,270 breakpoints[i].counter, breakpoints[i].address,269 printf("%-4u %7zu %p %-8s %-9s %-10s %s\n", i, 270 breakpoints[i].counter, (void *) breakpoints[i].address, 271 271 ((breakpoints[i].flags & BKPOINT_INPROG) ? "true" : 272 272 "false"), ((breakpoints[i].flags & BKPOINT_ONESHOT) … … 289 289 290 290 for (i = 0; i < BKPOINTS_MAX; i++) 291 breakpoints[i].address = NULL;291 breakpoints[i].address = (uintptr_t) NULL; 292 292 293 293 #ifdef CONFIG_KCONSOLE … … 341 341 /* Reinst only breakpoint */ 342 342 if ((breakpoints[i].flags & BKPOINT_REINST) && 343 (fireaddr == breakpoints[i].address + sizeof( unative_t))) {343 (fireaddr == breakpoints[i].address + sizeof(sysarg_t))) { 344 344 cur = &breakpoints[i]; 345 345 break; … … 366 366 367 367 if (!(cur->flags & BKPOINT_FUNCCALL)) { 368 printf("***Breakpoint %u: %p in %s.\n", i, fireaddr, 368 printf("***Breakpoint %u: %p in %s.\n", i, 369 (void *) fireaddr, 369 370 symtab_fmt_name_lookup(fireaddr)); 370 371 } … … 381 382 cur->flags |= BKPOINT_INPROG; 382 383 } else { 383 printf("***Breakpoint %d: %p in %s.\n", i, fireaddr, 384 printf("***Breakpoint %d: %p in %s.\n", i, 385 (void *) fireaddr, 384 386 symtab_fmt_name_lookup(fireaddr)); 385 387 … … 417 419 /* Remove one-shot breakpoint */ 418 420 if ((cur->flags & BKPOINT_ONESHOT)) 419 cur->address = NULL;421 cur->address = (uintptr_t) NULL; 420 422 421 423 /* Remove in-progress flag */ -
kernel/arch/mips32/src/exception.c
r1bfd3d3 r973ef9fc 74 74 void istate_decode(istate_t *istate) 75 75 { 76 printf("epc=%p\tsta=%p\tlo =%p\thi =%p\n", 77 istate->epc, istate->status, istate->lo, istate->hi); 78 printf("a0 =%p\ta1 =%p\ta2 =%p\ta3 =%p\n", 76 printf("epc=%p\tsta=%#010" PRIx32 "\t" 77 "lo =%#010" PRIx32 "\thi =%#010" PRIx32 "\n", 78 (void *) istate->epc, istate->status, 79 istate->lo, istate->hi); 80 81 printf("a0 =%#010" PRIx32 "\ta1 =%#010" PRIx32 "\t" 82 "a2 =%#010" PRIx32 "\ta3 =%#010" PRIx32 "\n", 79 83 istate->a0, istate->a1, istate->a2, istate->a3); 80 printf("t0 =%p\tt1 =%p\tt2 =%p\tt3 =%p\n", 84 85 printf("t0 =%#010" PRIx32 "\tt1 =%#010" PRIx32 "\t" 86 "t2 =%#010" PRIx32 "\tt3 =%#010" PRIx32 "\n", 81 87 istate->t0, istate->t1, istate->t2, istate->t3); 82 printf("t4 =%p\tt5 =%p\tt6 =%p\tt7 =%p\n", 88 89 printf("t4 =%#010" PRIx32 "\tt5 =%#010" PRIx32 "\t" 90 "t6 =%#010" PRIx32 "\tt7 =%#010" PRIx32 "\n", 83 91 istate->t4, istate->t5, istate->t6, istate->t7); 84 printf("t8 =%p\tt9 =%p\tv0 =%p\tv1 =%p\n", 92 93 printf("t8 =%#010" PRIx32 "\tt9 =%#010" PRIx32 "\t" 94 "v0 =%#010" PRIx32 "\tv1 =%#010" PRIx32 "\n", 85 95 istate->t8, istate->t9, istate->v0, istate->v1); 86 printf("s0 =%p\ts1 =%p\ts2 =%p\ts3 =%p\n", 96 97 printf("s0 =%#010" PRIx32 "\ts1 =%#010" PRIx32 "\t" 98 "s2 =%#010" PRIx32 "\ts3 =%#010" PRIx32 "\n", 87 99 istate->s0, istate->s1, istate->s2, istate->s3); 88 printf("s4 =%p\ts5 =%p\ts6 =%p\ts7 =%p\n", 100 101 printf("s4 =%#010" PRIx32 "\ts5 =%#010" PRIx32 "\t" 102 "s6 =%#010" PRIx32 "\ts7 =%#010" PRIx32 "\n", 89 103 istate->s4, istate->s5, istate->s6, istate->s7); 90 printf("s8 =%p\tat =%p\tkt0=%p\tkt1=%p\n", 104 105 printf("s8 =%#010" PRIx32 "\tat =%#010" PRIx32 "\t" 106 "kt0=%#010" PRIx32 "\tkt1=%#010" PRIx32 "\n", 91 107 istate->s8, istate->at, istate->kt0, istate->kt1); 108 92 109 printf("sp =%p\tra =%p\tgp =%p\n", 93 istate->sp, istate->ra, istate->gp); 110 (void *) istate->sp, (void *) istate->ra, 111 (void *) istate->gp); 94 112 } 95 113 -
kernel/arch/mips32/src/mips32.c
r1bfd3d3 r973ef9fc 168 168 void arch_post_smp_init(void) 169 169 { 170 static const char *platform; 171 172 /* Set platform name. */ 173 #ifdef MACHINE_msim 174 platform = "msim"; 175 #endif 176 #ifdef MACHINE_bgxemul 177 platform = "gxemul"; 178 #endif 179 #ifdef MACHINE_lgxemul 180 platform = "gxemul"; 181 #endif 182 sysinfo_set_item_data("platform", NULL, (void *) platform, 183 str_size(platform)); 184 170 185 #ifdef CONFIG_MIPS_KBD 171 186 /* … … 233 248 * possible to have it separately in the future. 234 249 */ 235 unative_t sys_tls_set(unative_t addr)250 sysarg_t sys_tls_set(sysarg_t addr) 236 251 { 237 252 return 0; -
kernel/arch/mips32/src/mm/tlb.c
r1bfd3d3 r973ef9fc 323 323 uintptr_t va = cp0_badvaddr_read(); 324 324 325 fault_if_from_uspace(istate, "TLB Refill Exception on %p.", va); 325 fault_if_from_uspace(istate, "TLB Refill Exception on %p.", 326 (void *) va); 326 327 panic_memtrap(istate, PF_ACCESS_UNKNOWN, va, "TLB Refill Exception."); 327 328 } … … 332 333 uintptr_t va = cp0_badvaddr_read(); 333 334 334 fault_if_from_uspace(istate, "TLB Invalid Exception on %p.", va); 335 fault_if_from_uspace(istate, "TLB Invalid Exception on %p.", 336 (void *) va); 335 337 panic_memtrap(istate, PF_ACCESS_UNKNOWN, va, "TLB Invalid Exception."); 336 338 } … … 340 342 uintptr_t va = cp0_badvaddr_read(); 341 343 342 fault_if_from_uspace(istate, "TLB Modified Exception on %p.", va); 344 fault_if_from_uspace(istate, "TLB Modified Exception on %p.", 345 (void *) va); 343 346 panic_memtrap(istate, PF_ACCESS_WRITE, va, "TLB Modified Exception."); 344 347 } -
kernel/arch/mips32/src/smp/dorder.c
r1bfd3d3 r973ef9fc 37 37 #include <arch/smp/dorder.h> 38 38 39 #define MSIM_DORDER_ADDRESS 0xB0000 00439 #define MSIM_DORDER_ADDRESS 0xB0000100 40 40 41 41 #ifdef CONFIG_SMP
Note:
See TracChangeset
for help on using the changeset viewer.
