Changes in boot/arch/mips32/src/main.c [4646710:a35b458] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
boot/arch/mips32/src/main.c
r4646710 ra35b458 49 49 { 50 50 version_print(); 51 51 52 52 printf("\nMemory statistics\n"); 53 53 printf(" %p|%p: CPU map\n", (void *) PA2KA(CPUMAP_OFFSET), … … 61 61 printf(" %p|%p: bootloader entry point\n", 62 62 (void *) PA2KA(LOADER_OFFSET), (void *) LOADER_OFFSET); 63 63 64 64 size_t i; 65 65 for (i = 0; i < COMPONENTS; i++) … … 70 70 components[i].name, components[i].inflated, 71 71 components[i].size); 72 72 73 73 void *dest[COMPONENTS]; 74 74 size_t top = 0; … … 77 77 for (i = 0; i < min(COMPONENTS, TASKMAP_MAX_RECORDS); i++) { 78 78 top = ALIGN_UP(top, PAGE_SIZE); 79 79 80 80 if (i > 0) { 81 81 bootinfo->tasks[bootinfo->cnt].addr = TOP2ADDR(top); 82 82 bootinfo->tasks[bootinfo->cnt].size = components[i].inflated; 83 83 84 84 str_cpy(bootinfo->tasks[bootinfo->cnt].name, 85 85 BOOTINFO_TASK_NAME_BUFLEN, components[i].name); 86 86 87 87 bootinfo->cnt++; 88 88 } 89 89 90 90 dest[i] = TOP2ADDR(top); 91 91 top += components[i].inflated; 92 92 cnt++; 93 93 } 94 94 95 95 printf("\nInflating components ... "); 96 96 97 97 for (i = cnt; i > 0; i--) { 98 98 #ifdef MACHINE_msim … … 104 104 } 105 105 #endif 106 106 107 107 printf("%s ", components[i - 1].name); 108 108 109 109 int err = inflate(components[i - 1].addr, components[i - 1].size, 110 110 dest[i - 1], components[i - 1].inflated); 111 111 112 112 if (err != EOK) { 113 113 printf("\n%s: Inflating error %d, halting.\n", … … 116 116 } 117 117 } 118 118 119 119 printf(".\n"); 120 120 121 121 printf("Copying CPU map ... \n"); 122 122 123 123 bootinfo->cpumap = 0; 124 124 for (i = 0; i < CPUMAP_MAX_RECORDS; i++) { … … 126 126 bootinfo->cpumap |= (1 << i); 127 127 } 128 128 129 129 printf("Booting the kernel ... \n"); 130 130 jump_to_kernel((void *) PA2KA(BOOT_OFFSET), bootinfo);
Note:
See TracChangeset
for help on using the changeset viewer.