Add stuff to struct lfs that it needs to initialize.
Clear these fields in mount as there's no on-disk support for quota2;
but this increases the chances of being able to add it (or something
like it) in the future.
struct lfs.
Put them inside #ifdef _KERNEL there. They are not the only such
members, gross as that is. Unfortunately, moving struct lfs to
lfs_kernel.h does not work.
lfs currently has the following headers:
lfs.h - on-disk structures and stuff needed for userlevel tools
lfs_inode.h - additional restricted materials for userlevel tools
that operate the fs (newfs_lfs, fsck_lfs, lfs_cleanerd)
lfs_kernel.h - stuff needed only in the kernel
and the following legacy headers that are expected to be mopped up and
folded into one of the above:
lfs_extern.h - function prototypes
ulfs_bswap.h - endian-independent support
ulfs_dinode.h - now contains very little
ulfs_dirhash.h - dirhash support
ulfs_extattr.h - extattr support
ulfs_extern.h - more function prototypes
ulfs_inode.h - assorted kernel-only declarations
ulfs_quota.h - quota support
ulfs_quota1.h - more quota support
ulfs_quota2.h - more quota support
ulfs_quotacommon.h - more quota support
ulfsmount.h - legacy copy of ufsmount material
fragstoblks()
blkstofrags()
fragnum()
blknum()
to finish the job of distinguishing them from the lfs versions, which
Christos renamed the other day.
I believe this is the last of the overtly ambiguous exported symbols
from ffs... or at least, the last of the ones that conflicted with lfs.
ffs still pollutes the C namespace very broadly (as does ufs) and this
needs quite a bit more cleanup.
XXX: boo on macros with lowercase names. But I'm not tackling that just yet.
MAXDIRSIZE -> UFS_MAXDIRSIZE or LFS_MAXDIRSIZE
NINDIR -> FFS_NINDIR, EXT2_NINDIR, LFS_NINDIR, or MFS_NINDIR
INOPB -> FFS_INOPB, LFS_INOPB
INOPF -> FFS_INOPF, LFS_INOPF
blksize -> ffs_blksize, ext2_blksize, or lfs_blksize
sblksize -> ffs_blksize
These are not the only ambiguously defined filesystem macros, of
course, there's a pile more. I may not have found all the ambiguous
definitions of blksize(), too, as there are a lot of other things
called 'blksize' in the system.
maximum size of short symlinks one byte less than one would think it
should be. Caution against changing it; that would break compatibility
with existing disk images. Behavior noticed by qjsgkem on freenode.
If my analysis is wrong, please correct...
Committed By: kardel
Date: Sat Jun 8 05:47:02 UTC 2013
fix clearing of system-flags (schg, sappnd). clearing system flags is
possible again at securelevel < 1.
reviewed by christos@