More system processes, this was not enough for the release script to run on some configurations

This commit is contained in:
Erik van der Kouwe
2010-05-20 08:05:07 +00:00
parent 456a125e00
commit 5f15ec05b2
20 changed files with 337 additions and 4 deletions

View File

@@ -20,11 +20,16 @@ PUBLIC int do_newmap(struct proc * caller, message * m_ptr)
struct mem_map *map_ptr; /* virtual address of map inside caller */
int proc_nr;
/*XXX*/vmmcall(0x12345604, 0, 100);
map_ptr = (struct mem_map *) m_ptr->PR_MEM_PTR;
/*XXX*/vmmcall(0x12345604, 0, 101);
if (! isokendpt(m_ptr->PR_ENDPT, &proc_nr)) return(EINVAL);
/*XXX*/vmmcall(0x12345604, 0, 102);
if (iskerneln(proc_nr)) return(EPERM);
/*XXX*/vmmcall(0x12345604, 0, 103);
rp = proc_addr(proc_nr);
/*XXX*/vmmcall(0x12345604, 0, 104);
return newmap(caller, rp, map_ptr);
}
@@ -36,13 +41,16 @@ PUBLIC int newmap(struct proc *caller, struct proc *rp, struct mem_map *map_ptr)
{
int r;
/* Fetch the memory map. */
/*XXX*/vmmcall(0x12345604, 0, 105);
if((r=data_copy(caller->p_endpoint, (vir_bytes) map_ptr,
KERNEL, (vir_bytes) rp->p_memmap, sizeof(rp->p_memmap))) != OK) {
printf("newmap: data_copy failed! (%d)\n", r);
return r;
}
/*XXX*/vmmcall(0x12345604, 0, 106);
alloc_segments(rp);
/*XXX*/vmmcall(0x12345604, 0, 107);
return(OK);
}

View File

@@ -18,7 +18,7 @@
*===========================================================================*/
PUBLIC int do_vmctl(struct proc * caller, message * m_ptr)
{
int proc_nr;
int proc_nr, r;
endpoint_t ep = m_ptr->SVMCTL_WHO;
struct proc *p, *rp, *target;
@@ -121,12 +121,18 @@ PUBLIC int do_vmctl(struct proc * caller, message * m_ptr)
return OK;
case VMCTL_ENABLE_PAGING:
vmmcall(0x12345605, vm_running, 1);
if(vm_running)
panic("do_vmctl: paging already enabled");
vmmcall(0x12345605, (unsigned) p, 2);
vm_init(p);
vmmcall(0x12345605, vm_running, 3);
if(!vm_running)
panic("do_vmctl: paging enabling failed");
return arch_enable_paging(caller, m_ptr);
vmmcall(0x12345605, (unsigned) caller, 4);
r = arch_enable_paging(caller, m_ptr);
vmmcall(0x12345605, r, 39);
return r;
case VMCTL_KERN_PHYSMAP:
{
int i = m_ptr->SVMCTL_VALUE;