Modified the kernel and all tasks with well-formatted printout messages.

This commit is contained in:
Bahadir Balban
2009-05-12 11:25:14 +03:00
parent db0d756dfa
commit 8528e2e1ba
28 changed files with 237 additions and 285 deletions

View File

@@ -43,7 +43,7 @@
void wait_pager(l4id_t partner)
{
l4_send(partner, L4_IPC_TAG_SYNC);
printf("%s: Pager synced with us.\n", __TASKNAME__);
// printf("%s: Pager synced with us.\n", __TASKNAME__);
}
void handle_fs_requests(void)
@@ -135,13 +135,13 @@ void handle_fs_requests(void)
void main(void)
{
printf("\n%s: Started with tid: %d\n", __TASKNAME__, self_tid());
printf("\n%s: Started with thread id: %d\n", __TASKNAME__, self_tid());
initialise();
wait_pager(PAGER_TID);
printf("%s: Listening requests.\n", __TASKNAME__);
printf("%s: VFS service initialized. Listening requests.\n", __TASKNAME__);
while (1) {
handle_fs_requests();
}

View File

@@ -78,6 +78,8 @@ int initialise(void)
/* Mount the filesystem on the root device */
vfs_mount_root(root_sb);
printf("%s: Mounted memfs root filesystem.\n", __TASKNAME__);
/* Learn about what tasks are running */
init_task_data();

View File

@@ -185,7 +185,7 @@ struct superblock *memfs_get_superblock(void *block)
struct memfs_superblock *sb = block;
struct superblock *vfs_sb;
printf("%s: %s: Reading superblock.\n", __TASKNAME__, __FUNCTION__);
// printf("%s: %s: Reading superblock.\n", __TASKNAME__, __FUNCTION__);
/* We don't do sanity checks here, just confirm id. */
if (strcmp(sb->name, "memfs")) {
printf("%s: Name does not match: %s\n", __FUNCTION__, sb->name);

View File

@@ -416,8 +416,8 @@ int pager_sys_write(struct tcb *pager, unsigned long vnum, unsigned long f_offse
if (vfs_isdir(v))
return -EISDIR;
printf("%s/%s: Writing to vnode %lu, at pgoff 0x%x, %d pages, buf at 0x%x\n",
__TASKNAME__, __FUNCTION__, vnum, f_offset, npages, pagebuf);
//printf("%s/%s: Writing to vnode %lu, at pgoff 0x%x, %d pages, buf at 0x%x\n",
// __TASKNAME__, __FUNCTION__, vnum, f_offset, npages, pagebuf);
if ((ret = v->fops.write(v, f_offset, npages, pagebuf)) < 0)
return ret;