Changeset ad45bde9 in mainline
- Timestamp:
- 2006-04-23T14:17:44Z (19 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 1f41004e
- Parents:
- 6ecc8bce
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
arch/ia32/src/mm/frame.c
r6ecc8bce rad45bde9 92 92 else 93 93 name = "invalid"; 94 printf("%p %#llXB %s\n", 94 printf("%.*p %#.16llXB %s\n", 95 sizeof(__native) * 2, 95 96 (__native) e820table[i].base_address, 96 97 (__u64) e820table[i].size, -
arch/ia32/src/mm/memory_init.c
r6ecc8bce rad45bde9 46 46 47 47 for (i=0;i<e820counter;i++) { 48 printf("E820 base: %# llX size: %lldtype: ", e820table[i].base_address, e820table[i].size);48 printf("E820 base: %#.16llx size: %#.16llx type: ", e820table[i].base_address, e820table[i].size); 49 49 switch (e820table[i].type) { 50 50 case MEMMAP_MEMORY_AVAILABLE: -
generic/include/debug.h
r6ecc8bce rad45bde9 50 50 */ 51 51 #ifdef CONFIG_DEBUG 52 # define ASSERT(expr) if (!(expr)) { panic("assertion failed (%s), caller=% p\n", #expr, CALLER); }52 # define ASSERT(expr) if (!(expr)) { panic("assertion failed (%s), caller=%.*p\n", #expr, sizeof(__address) * 2, CALLER); } 53 53 #else 54 54 # define ASSERT(expr) -
generic/src/console/cmd.c
r6ecc8bce rad45bde9 459 459 } else { 460 460 symbol = get_symtab_entry(symaddr); 461 printf("Calling f(): % p: %s\n", symaddr, symbol);461 printf("Calling f(): %.*p: %s\n", sizeof(__address) * 2, symaddr, symbol); 462 462 f = (__native (*)(void)) symaddr; 463 printf("Result: % p\n", f());463 printf("Result: %#zx\n", f()); 464 464 } 465 465 … … 483 483 } else { 484 484 symbol = get_symtab_entry(symaddr); 485 printf("Calling f(0x%zX): % p: %s\n", arg1, symaddr, symbol);485 printf("Calling f(0x%zX): %.*p: %s\n", arg1, sizeof(__address) * 2, symaddr, symbol); 486 486 f = (__native (*)(__native,...)) symaddr; 487 printf("Result: % p\n", f(arg1));487 printf("Result: %#zx\n", f(arg1)); 488 488 } 489 489 … … 508 508 } else { 509 509 symbol = get_symtab_entry(symaddr); 510 printf("Calling f(0x%zx,0x%zx): % p: %s\n",511 arg1, arg2, s ymaddr, symbol);510 printf("Calling f(0x%zx,0x%zx): %.*p: %s\n", 511 arg1, arg2, sizeof(__address) * 2, symaddr, symbol); 512 512 f = (__native (*)(__native,__native,...)) symaddr; 513 printf("Result: % p\n", f(arg1, arg2));513 printf("Result: %#zx\n", f(arg1, arg2)); 514 514 } 515 515 … … 535 535 } else { 536 536 symbol = get_symtab_entry(symaddr); 537 printf("Calling f(0x%zx,0x%zx, 0x%zx): % p: %s\n",538 arg1, arg2, arg3, s ymaddr, symbol);537 printf("Calling f(0x%zx,0x%zx, 0x%zx): %.*p: %s\n", 538 arg1, arg2, arg3, sizeof(__address) * 2, symaddr, symbol); 539 539 f = (__native (*)(__native,__native,__native,...)) symaddr; 540 printf("Result: % p\n", f(arg1, arg2, arg3));540 printf("Result: %#zx\n", f(arg1, arg2, arg3)); 541 541 } 542 542 … … 599 599 if (pointer) 600 600 addr = (__u32 *)(*(__native *)addr); 601 printf("Writing 0x%x -> % p\n", arg1, addr);601 printf("Writing 0x%x -> %.*p\n", arg1, sizeof(__address) * 2, addr); 602 602 *addr = arg1; 603 603 -
generic/src/debug/print.c
r6ecc8bce rad45bde9 211 211 * be in range 2 .. 16). 212 212 * @param flags output modifiers 213 * @return number of written characters or negative value on fail.213 * @return number of written characters or EOF. 214 214 */ 215 215 static int print_number(__u64 num, int width, int precision, int base , __u64 flags) -
generic/src/debug/symtab.c
r6ecc8bce rad45bde9 133 133 addr = __u64_le2host(symbol_table[i].address_le); 134 134 realname = symbol_table[i].symbol_name; 135 printf("% p: %s\n", addr, realname);135 printf("%.*p: %s\n", sizeof(__address) * 2, addr, realname); 136 136 i++; 137 137 } -
generic/src/interrupt/interrupt.c
r6ecc8bce rad45bde9 97 97 if (!symbol) 98 98 symbol = "not found"; 99 printf("%d %s % p(%s)\n", i + IVT_FIRST, exc_table[i].name,100 exc_table[i].f,symbol);99 printf("%d %s %.*p(%s)\n", i + IVT_FIRST, exc_table[i].name, 100 sizeof(__address) * 2, exc_table[i].f,symbol); 101 101 if (!((i+1) % 20)) { 102 102 printf("Press any key to continue."); -
generic/src/main/main.c
r6ecc8bce rad45bde9 177 177 178 178 version_print(); 179 printf("% #zx: hardcoded_ktext_size=%zdK, hardcoded_kdata_size=%zdK\n", config.base, hardcoded_ktext_size / 1024, hardcoded_kdata_size / 1024);179 printf("%.*p: hardcoded_ktext_size=%zdK, hardcoded_kdata_size=%zdK\n", sizeof(__address) * 2, config.base, hardcoded_ktext_size / 1024, hardcoded_kdata_size / 1024); 180 180 181 181 arch_pre_smp_init(); … … 196 196 197 197 for (i = 0; i < init.cnt; i++) 198 printf("init[%zd].addr=% p, init[%zd].size=%zd\n", i, init.tasks[i].addr, i, init.tasks[i].size);198 printf("init[%zd].addr=%.*p, init[%zd].size=%zd\n", i, sizeof(__address)*2, init.tasks[i].addr, i, init.tasks[i].size); 199 199 200 200 ipc_init(); -
generic/src/mm/buddy.c
r6ecc8bce rad45bde9 292 292 } 293 293 294 printf("#%zd\t% zd\t%zdK\t\t%zdK\t\t%zd\t", i, cnt, (cnt * (1 << i) * elem_size) >> 10, ((1 << i) * elem_size) >> 10, 1 << i);294 printf("#%zd\t%5zd\t%7zdK\t%8zdK\t%6zd\t", i, cnt, (cnt * (1 << i) * elem_size) >> 10, ((1 << i) * elem_size) >> 10, 1 << i); 295 295 if (!list_empty(&b->order[i])) { 296 296 for (cur = b->order[i].next; cur != &b->order[i]; cur = cur->next) { -
generic/src/mm/frame.c
r6ecc8bce rad45bde9 1029 1029 zone = zones.info[i]; 1030 1030 spinlock_lock(&zone->lock); 1031 printf("%d: % #x \t%zd\t\t%zd\n", i, PFN2ADDR(zone->base), zone->free_count, zone->busy_count);1031 printf("%d: %.*p \t%10zd\t%10zd\n", i, sizeof(__address) * 2, PFN2ADDR(zone->base), zone->free_count, zone->busy_count); 1032 1032 spinlock_unlock(&zone->lock); 1033 1033 } … … 1061 1061 spinlock_lock(&zone->lock); 1062 1062 printf("Memory zone information\n"); 1063 printf("Zone base address: %# zX\n", PFN2ADDR(zone->base));1063 printf("Zone base address: %#.*p\n", sizeof(__address) * 2, PFN2ADDR(zone->base)); 1064 1064 printf("Zone size: %zd frames (%zdK)\n", zone->count, ((zone->count) * FRAME_SIZE) >> 10); 1065 1065 printf("Allocated space: %zd frames (%zdK)\n", zone->busy_count, (zone->busy_count * FRAME_SIZE) >> 10); -
generic/src/mm/slab.c
r6ecc8bce rad45bde9 790 790 ipl = interrupts_disable(); 791 791 spinlock_lock(&slab_cache_lock); 792 printf("SLAB name\t Osize\tPages\tObj/pg\tSlabs\tCached\tAllocobjs\tCtl\n");792 printf("SLAB name\t Osize\t Pages\t Obj/pg\t Slabs\t Cached\tAllocobjs\tCtl\n"); 793 793 for (cur = slab_cache_list.next;cur!=&slab_cache_list; cur=cur->next) { 794 794 cache = list_get_instance(cur, slab_cache_t, link); 795 printf("%s\t% zd\t%zd\t%zd\t%zd\t%zd\t%zd\t\t%s\n", cache->name, cache->size,795 printf("%s\t%7zd\t%7zd\t%7zd\t%7zd\t%7zd\t%7zd\t\t%s\n", cache->name, cache->size, 796 796 (1 << cache->order), cache->objects, 797 797 atomic_get(&cache->allocated_slabs), -
generic/src/synch/spinlock.c
r6ecc8bce rad45bde9 70 70 while (test_and_set(&sl->val)) { 71 71 if (i++ > 300000 && sl!=&printflock) { 72 printf("cpu%d: looping on spinlock % p:%s, caller=%p",73 CPU->id, s l, sl->name, CALLER);72 printf("cpu%d: looping on spinlock %.*p:%s, caller=%.*p", 73 CPU->id, sizeof(__address) * 2, sl, sl->name, sizeof(__address) * 2, CALLER); 74 74 symbol = get_symtab_entry(CALLER); 75 75 if (symbol)
Note:
See TracChangeset
for help on using the changeset viewer.