summaryrefslogtreecommitdiff
path: root/fs.h
diff options
context:
space:
mode:
Diffstat (limited to 'fs.h')
-rw-r--r--fs.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/fs.h b/fs.h
index 2112c25..de81e81 100644
--- a/fs.h
+++ b/fs.h
@@ -9,7 +9,11 @@ struct superblock{
uint ninodes;
};
-#define NDIRECT 13
+#define NADDRS NDIRECT+1
+#define NDIRECT 12
+#define INDIRECT 12
+#define NINDIRECT (BSIZE / sizeof(uint))
+#define MAXFILE (NDIRECT + NINDIRECT)
struct dinode {
short type;
@@ -17,7 +21,7 @@ struct dinode {
short minor;
short nlink;
uint size;
- uint addrs[NDIRECT];
+ uint addrs[NADDRS];
};
#define T_DIR 1