diff options
author | Alex AUVOLAT <alexis211@gmail.com> | 2012-05-17 17:56:23 +0200 |
---|---|---|
committer | Alex AUVOLAT <alexis211@gmail.com> | 2012-05-17 17:56:23 +0200 |
commit | 593bf4df3d8db49286c1a7ae4ef75c887b629930 (patch) | |
tree | 988a104c9611d72e1252282789688586efd9a394 /src/kernel/vfs/node.h | |
parent | 7c9a48b4e6d66cf4f62e7bad9e22ab06923e47ef (diff) | |
download | TCE-593bf4df3d8db49286c1a7ae4ef75c887b629930.tar.gz TCE-593bf4df3d8db49286c1a7ae4ef75c887b629930.zip |
Devices using the VFS structure. Basic keyboard handler.
Diffstat (limited to 'src/kernel/vfs/node.h')
-rw-r--r-- | src/kernel/vfs/node.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/kernel/vfs/node.h b/src/kernel/vfs/node.h index 2d16dab..9005d55 100644 --- a/src/kernel/vfs/node.h +++ b/src/kernel/vfs/node.h @@ -6,6 +6,8 @@ #include <task/task.h> +class display; + class node { public: node* parent; @@ -13,6 +15,7 @@ class node { int mode, uid, gid; node(node* p, int t) : parent(p), type(t) {} + virtual ~node() {} virtual int open(process *proc, int mode); virtual void close(process *proc) {} @@ -22,11 +25,16 @@ class node { virtual node* get_child(char* name) { return 0; } virtual int add_child(char* name, node *child) { return E_NOT_IMPLEMENTED; } virtual size_t get_size() { return 0; } + + // kind of like dynamic_cast'int these things + virtual display *as_display() { return 0; } }; void vfs_setup(); node* vfs_find(node* root, char* filename); +extern node *root, *dot_dev, *dot_ui; + // syscall interface FILE open(char* filename, int mode); FILE open_relative(FILE root, char* filename, int mode); |