From dadd5202a3ccfd8c03fb9eb60e6a15b0fb987672 Mon Sep 17 00:00:00 2001 From: Michal Idziorek Date: Sat, 23 May 2015 21:39:42 +0200 Subject: filesystem stuff and experimenting with userspace tasks --- fs/mount.h | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) (limited to 'fs/mount.h') diff --git a/fs/mount.h b/fs/mount.h index beece3c..372e051 100644 --- a/fs/mount.h +++ b/fs/mount.h @@ -3,15 +3,23 @@ #define MOUNT_MAX_MOUNTS 10 -typedef struct mount_strutc +#include +#include "file.h" +#include "fs.h" + +typedef struct mount_struct { char path[256]; // where are we mounted - int (*getdents)(mount_struct*, uint32_t file_desciptor, fs_dirent *entries, uint32_t max_count); - file (*open)ByName(mount_struct*,char *path); + int (*getdents)(struct mount_struct*, uint32_t file_desciptor, fs_dirent *entries, uint32_t max_count); + file (*open)(struct mount_struct*,char *path); void *data //opaque }mount; mount *mounts_get(); +void mount_add(char *path, void *data,file (*open)(struct mount_struct*,char *path),int (*getdents)(struct mount_struct*, uint32_t file_desciptor, fs_dirent *entries, uint32_t max_count)); + + + // #endif -- cgit v1.2.3