summaryrefslogtreecommitdiff
path: root/fs/fd.h
diff options
context:
space:
mode:
Diffstat (limited to 'fs/fd.h')
-rw-r--r--fs/fd.h22
1 files changed, 4 insertions, 18 deletions
diff --git a/fs/fd.h b/fs/fd.h
index 35e28d9..c9b7fd8 100644
--- a/fs/fd.h
+++ b/fs/fd.h
@@ -9,27 +9,12 @@
#include "fifo.h"
#include "ringbuffer.h"
-/*
-typedef struct
-{
- int(* seek)(int offset, int whence);
-
- int(* read)(char *buf, int len);
- int(* wrtie)(char *buf, int len);
-
- int(* close)();
- int(* stat)(void *buf);
-
- void *data; //opaque
-
-}file;
-*/
-
enum FD_TYPE{
FD_TYPE_FIFO_BUFFERED=1,
FD_TYPE_EXT2_FILE=2,
FD_TYPE_EXT2_DIR=3,
- FD_TYPE_SYSFS=4
+ FD_TYPE_SYSFS=4,
+ FD_TYPE_PIPE=5
};
typedef struct fd_struct
@@ -52,5 +37,6 @@ bool fd_close(fd*);
fd fd_from_fifo(fifo* f);
fd fd_from_path(char *path);
-fd fd_from_sysfs(void(*g)(ringbuffer *r,void (*f)(ringbuffer *r,char *fmt, ...)));
+fd fd_from_sysfs(void(*g)(ringbuffer *r,void (*f)(ringbuffer *r,char *fmt, ...)),void(*h)(uint32_t in));
+
#endif