mirror of
https://github.com/drasko/codezero.git
synced 2026-01-17 21:33:15 +01:00
Various changes to incorporate new utcb setup.
Issues with l4_return value not reaching client side modified: libs/c/include/stdio.h modified: src/arch/arm/exception.c modified: src/glue/arm/init.c modified: tasks/fs0/src/task.c modified: tasks/libl4/include/l4lib/arch-arm/utcb.h modified: tasks/libl4/src/arm/syscalls.S modified: tasks/libl4/src/init.c deleted: tasks/libl4/tagfilelist modified: tasks/libposix/open.c modified: tasks/mm0/include/utcb.h modified: tasks/mm0/include/vm_area.h modified: tasks/mm0/main.c modified: tasks/mm0/src/init.c modified: tasks/mm0/src/task.c modified: tasks/mm0/src/utcb.c modified: tasks/mm0/src/vm_object.c
This commit is contained in:
@@ -218,9 +218,6 @@ int start_boot_task(struct vm_file *file, struct task_ids *ids)
|
||||
task->tid = ids->tid;
|
||||
task->spid = ids->spid;
|
||||
|
||||
/* Allocate a utcb virtual address */
|
||||
task->utcb_address = (unsigned long)utcb_vaddr_new();
|
||||
|
||||
/* Prepare environment boundaries. */
|
||||
task->env_end = USER_AREA_END;
|
||||
task->env_start = task->env_end - DEFAULT_ENV_SIZE;
|
||||
@@ -280,16 +277,6 @@ int start_boot_task(struct vm_file *file, struct task_ids *ids)
|
||||
goto error;
|
||||
}
|
||||
|
||||
/* mmap each task's utcb as single page anonymous memory. */
|
||||
printf("%s: Mapping utcb for new task at: 0x%x\n", __TASKNAME__,
|
||||
task->utcb_address);
|
||||
if ((err = do_mmap(0, 0, task, task->utcb_address,
|
||||
VM_READ | VM_WRITE | VMA_SHARED | VMA_ANONYMOUS,
|
||||
__pfn(DEFAULT_UTCB_SIZE))) < 0) {
|
||||
printf("do_mmap: Mapping utcb failed with %d.\n", err);
|
||||
goto error;
|
||||
}
|
||||
|
||||
/* Add the task to the global task list */
|
||||
list_add(&task->list, &tcb_head.list);
|
||||
tcb_head.total++;
|
||||
@@ -440,7 +427,6 @@ void send_task_data(l4id_t requester)
|
||||
{
|
||||
int li, err;
|
||||
struct tcb *t, *vfs;
|
||||
struct utcb *vfs_utcb;
|
||||
struct task_data_head *tdata_head;
|
||||
|
||||
if (requester != VFS_TID) {
|
||||
@@ -451,16 +437,14 @@ void send_task_data(l4id_t requester)
|
||||
}
|
||||
|
||||
BUG_ON(!(vfs = find_task(requester)));
|
||||
BUG_ON(!vfs->utcb_address);
|
||||
|
||||
/* Map in vfs's utcb. FIXME: Whatif it is already mapped? */
|
||||
l4_map((void *)page_to_phys(task_virt_to_page(vfs, vfs->utcb_address)),
|
||||
(void *)vfs->utcb_address, 1, MAP_USR_RW_FLAGS, self_tid());
|
||||
|
||||
/* Get a handle on vfs utcb */
|
||||
vfs_utcb = (struct utcb *)vfs->utcb_address;
|
||||
|
||||
/* Write all requested task information to utcb's user buffer area */
|
||||
tdata_head = (struct task_data_head *)vfs_utcb->buf;
|
||||
tdata_head = (struct task_data_head *)vfs->utcb_address;
|
||||
|
||||
/* First word is total number of tcbs */
|
||||
tdata_head->total = tcb_head.total;
|
||||
|
||||
Reference in New Issue
Block a user