diff --git a/Makefile.inc b/Makefile.inc index 1d4091a..b4d86e6 100644 --- a/Makefile.inc +++ b/Makefile.inc @@ -1,8 +1,8 @@ # $Id$ # global 'sys' options -CC = gcc -C++ = g++ +CC = gcc34 +C++ = g++34 LD = ld AR = ar REMOVE = rm -fr diff --git a/init/main.c b/init/main.c index 9ca879b..dd0db38 100644 --- a/init/main.c +++ b/init/main.c @@ -94,7 +94,18 @@ * * \param rootdev address of root device structure */ -int kmain(u_intu_int32_t rootdev) { +typedef struct { + u_int32_t version; + char *kernel; + u_int32_t nfs; + u_int32_t bios_used; + u_int32_t bios_geom[8]; + u_int32_t bi_size; + u_int32_t mem_sizes; + u_int32_t bios_dev; + } bootinfo; + +int kmain(bootinfo *binfo) { /* Set up counter for startup routine */ int i = 0x0; u_int32_t *sysTask = 0x0; @@ -102,6 +113,8 @@ /* We preform a clearScreen to make the TEXT buffer nice and empty */ screenClear(); + kprintf("[0x%X][%s][0x%X][0x%X][0x%X]\n",binfo->version,binfo->kernel,binfo->bios_used,binfo->bi_size,binfo->bios_dev); + /* Modify src/sys/include/ubixos/init.h to add a startup routine */ for (i = 0x0;i < init_tasksTotal;i++) { if (init_tasks[i]() != 0x0) { @@ -112,7 +125,7 @@ /* New Root Mount Point */ //Old 2 new 10 //#ifdef DEBUG - kprintf("[0x%X][0x%X:0x%X:0x%X:0x%X:0x%X:0x%X]\n",rootdev,B_ADAPTOR(rootdev),B_CONTROLLER(rootdev),B_SLICE(rootdev),B_UNIT(rootdev),B_PARTITION(rootdev),B_TYPE(rootdev)); + //kprintf("[0x%X][0x%X:0x%X:0x%X:0x%X:0x%X:0x%X]\n",rootdev,B_ADAPTOR(rootdev),B_CONTROLLER(rootdev),B_SLICE(rootdev),B_UNIT(rootdev),B_PARTITION(rootdev),B_TYPE(rootdev)); //#endif //if (vfs_mount(0x1,B_PARTITION(rootdev)+2,0x0,0xAA,"sys","rw") != 0x0) { diff --git a/init/start.S b/init/start.S index 1ea5fe0..7303287 100644 --- a/init/start.S +++ b/init/start.S @@ -57,14 +57,16 @@ addl $0x2000,%eax mov %esp,%edx mov %eax,%esp - mov %eax,%ebp + //mov %eax,%ebp mov $0x18,%ax lldt %ax mov $0x20,%ax ltr %ax ljmp $0x08,$start_next start_next: - push 8(%edx) + //push 8(%edx) + movl 28(%ebp),%ebx + push %ebx call kmain .data