diff options
Diffstat (limited to 'sys/ufs/ffs/fs.h')
-rw-r--r-- | sys/ufs/ffs/fs.h | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/sys/ufs/ffs/fs.h b/sys/ufs/ffs/fs.h index 6086da88456..ae9a58dc7f3 100644 --- a/sys/ufs/ffs/fs.h +++ b/sys/ufs/ffs/fs.h @@ -1,4 +1,4 @@ -/* $OpenBSD: fs.h,v 1.6 1997/10/06 20:21:39 deraadt Exp $ */ +/* $OpenBSD: fs.h,v 1.7 1997/11/06 05:59:21 csapuntz Exp $ */ /* $NetBSD: fs.h,v 1.6 1995/04/12 21:21:02 mycroft Exp $ */ /* @@ -221,7 +221,7 @@ struct fs { int8_t fs_fmod; /* super block modified flag */ int8_t fs_clean; /* file system is clean flag */ int8_t fs_ronly; /* mounted read-only flag */ - int8_t fs_flags; /* currently unused flag */ + int8_t fs_flags; /* see FS_ below */ u_char fs_fsmnt[MAXMNTLEN]; /* name mounted on */ /* these fields retain the current block allocation info */ int32_t fs_cgrotor; /* last cg searched */ @@ -267,6 +267,12 @@ struct fs { #define FS_OPTTIME 0 /* minimize allocation time */ #define FS_OPTSPACE 1 /* minimize disk fragmentation */ +/* + * Filesystem falgs. + */ +#define FS_UNCLEAN 0x01 /* filesystem not clean at mount */ +#define FS_DOSOFTDEP 0x02 /* filesystem using soft dependencies */ + /* * Rotational layout table format types */ @@ -490,6 +496,12 @@ struct ocg { ? (fs)->fs_bsize \ : (fragroundup(fs, blkoff(fs, (dip)->di_size)))) +#define sblksize(fs, size, lbn) \ + (((lbn) >= NDADDR || (size) >= ((lbn) + 1) << (fs)->fs_bshift) \ + ? (fs)->fs_bsize \ + : (fragroundup(fs, blkoff(fs, (size))))) + + /* * Number of disk sectors per block/fragment; assumes DEV_BSIZE byte * sector size. |