diff options
author | Alex Auvolat <alex.auvolat@ens.fr> | 2015-02-09 21:28:11 +0100 |
---|---|---|
committer | Alex Auvolat <alex.auvolat@ens.fr> | 2015-02-09 21:28:11 +0100 |
commit | 8bfbc4b05b219950e3eb8ac377b8cb3020ddb9ab (patch) | |
tree | d6dc0ff3158e2531820d323ceb925c79b5d99425 /src/kernel/core/kmain.c | |
parent | f90436dd7415354105a27846e587adefaea7ef63 (diff) | |
download | kogata-8bfbc4b05b219950e3eb8ac377b8cb3020ddb9ab.tar.gz kogata-8bfbc4b05b219950e3eb8ac377b8cb3020ddb9ab.zip |
Work on nullfs
Diffstat (limited to 'src/kernel/core/kmain.c')
-rw-r--r-- | src/kernel/core/kmain.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/src/kernel/core/kmain.c b/src/kernel/core/kmain.c index 9ad8178..4ced0da 100644 --- a/src/kernel/core/kmain.c +++ b/src/kernel/core/kmain.c @@ -124,7 +124,7 @@ void test_hashtbl_1() { dbg_printf("ht[test1] = %s\n", hashtbl_find(ht, "test1")); dbg_printf("ht[test] = %s\n", hashtbl_find(ht, "test")); dbg_printf("ht[test2] = %s\n", hashtbl_find(ht, "test2")); - delete_hashtbl(ht); + delete_hashtbl(ht, 0); } void test_hashtbl_2() { @@ -144,7 +144,7 @@ void test_hashtbl_2() { dbg_printf("ht[12] = %s\n", hashtbl_find(ht, (void*)12)); dbg_printf("ht[144] = %s\n", hashtbl_find(ht, (void*)144)); dbg_printf("ht[777] = %s\n", hashtbl_find(ht, (void*)777)); - delete_hashtbl(ht); + delete_hashtbl(ht, 0); } void test_thread(void* a) { @@ -254,14 +254,17 @@ void kernel_init_stage2(void* data) { strcpy(name, "/mod/"); strcpy(name+5, modname); - nullfs_add_ram_file(devfs, name, + dbg_printf("Adding model to VFS: %s\n", name); + + ASSERT(nullfs_add_ram_file(devfs, name, (void*)mods[i].mod_start, mods[i].mod_end - mods[i].mod_start, - FM_READ); + false, + FM_READ)); } //TODO : - // - populate devfs with information regarding kernel command line & modules + // - (OK) populate devfs with information regarding kernel command line & modules // - create user process with init module provided on command line // - give it rights to devfs // - launch it |