fs.h - vx32 - Local 9vx git repository for patches.
(HTM) git clone git://r-36.net/vx32
(DIR) Log
(DIR) Files
(DIR) Refs
---
fs.h (659B)
---
1 typedef struct File File;
2 typedef struct Fs Fs;
3
4 #include "dosfs.h"
5 #include "kfs.h"
6
7 struct File{
8 union{
9 Dosfile dos;
10 Kfsfile kfs;
11 int walked;
12 };
13 Fs *fs;
14 char *path;
15 };
16
17 struct Fs{
18 union {
19 Dos dos;
20 Kfs kfs;
21 };
22 int dev; /* device id */
23 long (*diskread)(Fs*, void*, long); /* disk read routine */
24 vlong (*diskseek)(Fs*, vlong); /* disk seek routine */
25 long (*read)(File*, void*, long);
26 int (*walk)(File*, char*);
27 File root;
28 };
29
30 /*
31 extern int chatty;
32 extern int dotini(Fs*);
33 extern int fswalk(Fs*, char*, File*);
34 extern int fsread(File*, void*, long);
35 extern int fsboot(Fs*, char*, Boot*);
36 */
37
38 #define BADPTR(x) ((ulong)x < 0x80000000)