diff options
author | Alex Auvolat <alex.auvolat@ens.fr> | 2015-02-09 19:24:42 +0100 |
---|---|---|
committer | Alex Auvolat <alex.auvolat@ens.fr> | 2015-02-09 19:24:42 +0100 |
commit | 440d9dc470703d20a55365b3a560196e71d450d4 (patch) | |
tree | bcc864c7aeb0af7a81c4fcd7430fa8c3001f8383 /src/kernel/user/nullfs.c | |
parent | caf842864bdc0794e387f9580af96ab1036996f4 (diff) | |
download | kogata-440d9dc470703d20a55365b3a560196e71d450d4.tar.gz kogata-440d9dc470703d20a55365b3a560196e71d450d4.zip |
Start work on filesystems.
Diffstat (limited to 'src/kernel/user/nullfs.c')
-rw-r--r-- | src/kernel/user/nullfs.c | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/src/kernel/user/nullfs.c b/src/kernel/user/nullfs.c new file mode 100644 index 0000000..3c11198 --- /dev/null +++ b/src/kernel/user/nullfs.c @@ -0,0 +1,30 @@ +#include <nullfs.h> + +bool nullfs_i_make(fs_handle_t *source, char* opts, fs_t *d); + +fs_driver_ops_t nullfs_driver_ops = { + .make = nullfs_i_make, + .detect = 0, +}; + +fs_ops_t nullfs_ops = { + 0 //TODO +}; + +void register_nullfs_driver() { + register_fs_driver("nullfs", &nullfs_driver_ops); +} + +nullfs_t *make_nullfs(char* options) { + fs_t *it = make_fs("nullfs", 0, options); + if (it == 0) return 0; + if (it->ops != &nullfs_ops) return 0; + return (nullfs_t*)it->data; +} + +bool nullfs_i_make(fs_handle_t *source, char* opts, fs_t *d) { + // TODO + return false; +} + +/* vim: set ts=4 sw=4 tw=0 noet :*/ |