Download David Mazieres

Transcript
struct sfsro inode-reg {
uint32 nlink;
uint64 size;
uint64 used;
nfstime3 mtime;
nfstime3 ctime;
sfshash
sfs-hash
sfs_hash
sfs_hash
direct<SFSRONDIR>;
indirect;
doubleindirect;
triple-indirect;
union sfsro-inode switch (ftypero type) {
case SFSROLNK:
sfsroinodejlnk lnk;
default:
sfsro-inode.reg reg;
};
struct sfsroindirect {
sfshash handles<SFSRONFH>;
};
struct sfsro-dirent {
sfs_hash fh;
string name<>;
sfsrodirent *nextentry;
/* uint64 fileid; */
};
struct sfsro-directory {
nfspath3 path;
/* uint64 fileid; */
sfsrodirent *entries;
bool eof;
};
struct sfsrofhdbindir {
Invariant:
key[i] < key [j] for all i<j
keys in GETDATA(child[i]) are
<= key[i+1] <
keys in GETDATA(child[i+1])
sfs_hash key<SFSROFHDBKEYS>;
sfs.hash child<SFSROFHDBCHILDREN>;
98