diff --git a/src/sys/kernel/exec.c b/src/sys/kernel/exec.c index fa788e7..18fc798 100644 --- a/src/sys/kernel/exec.c +++ b/src/sys/kernel/exec.c @@ -191,50 +191,37 @@ fseek(tmpFd,binaryHeader->ePhoff,0); fread(programHeader,(sizeof(elfProgramheader)*binaryHeader->ePhnum),1,tmpFd); - kprintf("1"); - /* Loop Through The Header And Load Sections Which Need To Be Loaded */ for (i=0;iePhnum;i++) { - kprintf("."); if (programHeader[i].phType == 1) { - kprintf("z"); newLoc = (char *)programHeader[i].phVaddr; /* Allocate Memory Im Going To Have To Make This Load Memory With Correct Settings so it helps us in the future */ - kprintf("Q"); - for (x=0;x<=((programHeader[i].phMemsz+4095);x += 0x1000) { + for (x=0;x<=(programHeader[i].phMemsz+4095);x += 0x1000) { if (vmmRemapPage(vmmFindFreePage(_current->id),((programHeader[i].phVaddr & 0xFFFFF000) + x)) == 0x0) { kpanic("Error: vmmFindFreePage Failed\n"); } - kprintf("[0x%X]\n",programHeader[i].phVaddr + x); } - kprintf("W"); _current->oInfo.vmStart = ((programHeader[i].phVaddr & 0xFFFFF000) + 0x1900000); - kprintf("E"); /* Now Load Section To Memory */ fseek(tmpFd,programHeader[i].phOffset,0); - kprintf("R: [0x0%X]",newLoc); fread(newLoc,programHeader[i].phFilesz,1,tmpFd); - kprintf("T"); } else if (programHeader[i].phType == 2) { - kprintf("x"); newLoc = (char *)programHeader[i].phVaddr; //elfDynamicS = (elfDynamic *)programHeader[i].phVaddr; fseek(tmpFd,programHeader[i].phOffset,0); fread(newLoc,programHeader[i].phFilesz,1,tmpFd); } else if (programHeader[i].phType == 3) { - kprintf("c"); linker = (char *)kmalloc(programHeader[i].phMemsz); fseek(tmpFd,programHeader[i].phOffset,0); fread(linker,programHeader[i].phFilesz,1,tmpFd); } } - kprintf("2"); /* Set Virtual Memory Start */ _current->oInfo.vmStart = ((programHeader[i].phVaddr & 0xFFFFF000) + 0x1900000);