00001 /* Declaration of the V1 inode as it is on the disk (not in core). */ 00002 typedef struct { /* V1.x disk inode */ 00003 u16_t d1_mode; /* file type, protection, etc. */ 00004 i16_t d1_uid; /* user id of the file's owner */ 00005 i32_t d1_size; /* current file size in bytes */ 00006 i32_t d1_mtime; /* when was file data last changed */ 00007 u8_t d1_gid; /* group number */ 00008 u8_t d1_nlinks; /* how many links to this file */ 00009 u16_t d1_zone[V1_NR_TZONES]; /* block nums for direct, ind, and dbl ind */ 00010 } d1_inode; 00011 00012 /* Declaration of the V2 inode as it is on the disk (not in core). */ 00013 typedef struct { /* V2.x disk inode */ 00014 u16_t d2_mode; /* file type, protection, etc. */ 00015 u16_t d2_nlinks; /* how many links to this file. HACK! */ 00016 i16_t d2_uid; /* user id of the file's owner. */ 00017 u16_t d2_gid; /* group number HACK! */ 00018 i32_t d2_size; /* current file size in bytes */ 00019 i32_t d2_atime; /* when was file data last accessed */ 00020 i32_t d2_mtime; /* when was file data last changed */ 00021 i32_t d2_ctime; /* when was inode data last changed */ 00022 zone_t d2_zone[V2_NR_TZONES]; /* block nums for direct, ind, and dbl ind */ 00023 } d2_inode; 00024 00025 struct buf { 00026 /* Data portion of the buffer. */ 00027 union fsdata_u *bp; 00028 00029 /* Header portion of the buffer. */ 00030 struct buf *b_next; /* used to link all free bufs in a chain */ 00031 struct buf *b_prev; /* used to link all free bufs the other way */ 00032 struct buf *b_hash; /* used to link bufs on hash chains */ 00033 block_t b_blocknr; /* block number of its (minor) device */ 00034 dev_t b_dev; /* major | minor device where block resides */ 00035 char b_dirt; /* CLEAN or DIRTY */ 00036 char b_count; /* number of users of this buffer */ 00037 int b_bytes; /* Number of bytes allocated in bp */ 00038 }; 00039
1.5.8