summaryrefslogtreecommitdiff
path: root/src/kernel/vfs/root.c
blob: c90557b6e70d7da8aad1876bb14c3a5c11a100d2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#include <kernel/vfs/root.h>
#include <kernel/util.h>
#include <kernel/panic.h>

int vfs_root_handler(struct vfs_op_request *req) {
	switch (req->op.type) {
		case VFSOP_OPEN:
			if (req->op.open.path_len == 4
					&& !memcmp(req->op.open.path, "/tty", 4)) {
				return 0;
			}
			return -1;
		default:
			panic();
	}
}