/trunk/kernel/generic/include/config.h |
---|
40,11 → 40,14 |
#define STACK_SIZE PAGE_SIZE |
#define CONFIG_INIT_TASKS 32 |
#define CONFIG_INIT_TASKS 32 |
#define CONFIG_TASK_NAME_BUFLEN 32 |
typedef struct { |
uintptr_t addr; |
size_t size; |
char name[CONFIG_TASK_NAME_BUFLEN]; |
} init_task_t; |
typedef struct { |
/trunk/kernel/generic/src/main/kinit.c |
---|
174,9 → 174,12 |
printf("init[%" PRIc "].addr is not frame aligned\n", i); |
continue; |
} |
char *name = init.tasks[i].name; |
if (name[0] == '\0') name = "init-bin"; |
int rc = program_create_from_image((void *) init.tasks[i].addr, |
"init-bin", &programs[i]); |
name, &programs[i]); |
if ((rc == 0) && (programs[i].task != NULL)) { |
/* |
/trunk/kernel/generic/src/proc/task.c |
---|
396,13 → 396,13 |
order(task_get_accounting(t), &cycles, &suffix); |
#ifdef __32_BITS__ |
printf("%-6" PRIu64 " %-10s %-3" PRIu32 " %10p %10p %9" PRIu64 |
printf("%-6" PRIu64 " %-12s %-3" PRIu32 " %10p %10p %9" PRIu64 |
"%c %7ld %6ld", t->taskid, t->name, t->context, t, t->as, cycles, |
suffix, atomic_get(&t->refcount), atomic_get(&t->active_calls)); |
#endif |
#ifdef __64_BITS__ |
printf("%-6" PRIu64 " %-10s %-3" PRIu32 " %18p %18p %9" PRIu64 |
printf("%-6" PRIu64 " %-12s %-3" PRIu32 " %18p %18p %9" PRIu64 |
"%c %7ld %6ld", t->taskid, t->name, t->context, t, t->as, cycles, |
suffix, atomic_get(&t->refcount), atomic_get(&t->active_calls)); |
#endif |
429,7 → 429,7 |
#ifdef __32_BITS__ |
printf("taskid name ctx address as " |
"cycles threads calls callee\n"); |
printf("------ ---------- --- ---------- ---------- " |
printf("------ ------------ --- ---------- ---------- " |
"---------- ------- ------ ------>\n"); |
#endif |
436,7 → 436,7 |
#ifdef __64_BITS__ |
printf("taskid name ctx address as " |
"cycles threads calls callee\n"); |
printf("------ ---------- --- ------------------ ------------------ " |
printf("------ ------------ --- ------------------ ------------------ " |
"---------- ------- ------ ------>\n"); |
#endif |
/trunk/kernel/arch/amd64/src/boot/boot.S |
---|
223,7 → 223,7 |
movq %rdx, 16(%rdi) |
addl $16, %esi |
addq $16, %rdi |
addq $48, %rdi |
loop mods_loop |
/trunk/kernel/arch/ia32/src/boot/cboot.c |
---|
38,6 → 38,7 |
#include <arch/boot/memmap.h> |
#include <config.h> |
#include <memstr.h> |
#include <func.h> |
/* This is a symbol so the type is only dummy. Obtain the value using &. */ |
extern int _hardcoded_unmapped_size; |
68,6 → 69,16 |
for (i = 0; i < init.cnt; i++) { |
init.tasks[i].addr = mods[i].start + 0x80000000; |
init.tasks[i].size = mods[i].end - mods[i].start; |
/* Copy command line, if available. */ |
if (mods[i].string) { |
strncpy(init.tasks[i].name, mods[i].string, |
CONFIG_TASK_NAME_BUFLEN - 1); |
init.tasks[i].name[CONFIG_TASK_NAME_BUFLEN - 1] |
= '\0'; |
} else { |
init.tasks[i].name[0] = '\0'; |
} |
} |
} else { |
init.cnt = 0; |