comparison uprogs/buf.h @ 0:ed10291ff195

first commit
author mir3636
date Sun, 06 Jan 2019 19:27:03 +0900
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:ed10291ff195
1 struct buf {
2 int flags;
3 uint dev;
4 uint sector;
5 struct buf *prev; // LRU cache list
6 struct buf *next;
7 struct buf *qnext; // disk queue
8 uchar data[512];
9 };
10 #define B_BUSY 0x1 // buffer is locked by some process
11 #define B_VALID 0x2 // buffer has been read from disk
12 #define B_DIRTY 0x4 // buffer needs to be written to disk
13