summaryrefslogtreecommitdiff
path: root/sys/ufs
AgeCommit message (Collapse)Author
2023-06-15Undo unlock/relock for VOP_IOCTL().hannken
PR kern/57450 (unplugging hung USB disk triggers panic via _vstate_assert)
2023-06-05Make DEBUG_FFS_MOUNT compile again (with 64-bit ino_t).rin
2023-05-11ffs: apply the remaining ffs_snapshot.c part of this FreeBSD commit:chs
commit 364ed814e7285c8216d8a201d3ab3674eb34ce29 Author: Kirk McKusick <mckusick@FreeBSD.org> Date: Thu Dec 9 21:24:00 2004 +0000 Fixes a bug that caused UFS2 filesystems bigger than 2TB to prematurely report that they were full and/or to panic the kernel with the message ``ffs_clusteralloc: allocated out of group''. Submitted by: Henry Whincup <henry@jot.to> MFC after: 1 week all the other changes in that commit were applied previously by others: - sborrill commmitted ffs_alloc.c rev 1.123 in 2009 - simonb committed ffs_alloc.c rev 1.110 in 2008 - the ffs_clusteralloc() part is not needed because we no longer have that function. fixes PR 57307
2023-04-11lfs: Assert page identity doesn't change.riastradh
Forgot what I was debugging when I inserted a relookup in my local tree months or years ago, but whatever it was, if that solved a problem, this KDASSERT will make the problem more obvious.
2023-02-22ufs: Nix trailing whitespace and tidy up some other minor KNF.riastradh
2023-01-30s/isses/issues/andvar
2023-01-07ufs: fixed signed/unsigned bugs affecting large file systemschs
Apply these commits from FreeBSD: commit e870d1e6f97cc73308c11c40684b775bcfa906a2 Author: Kirk McKusick <mckusick@FreeBSD.org> Date: Wed Feb 10 20:10:35 2010 +0000 This fix corrects a problem in the file system that treats large inode numbers as negative rather than unsigned. For a default (16K block) file system, this bug began to show up at a file system size above about 16Tb. To fully handle this problem, newfs must be updated to ensure that it will never create a filesystem with more than 2^32 inodes. That patch will be forthcoming soon. Reported by: Scott Burns, John Kilburg, Bruce Evans Followup by: Jeff Roberson PR: 133980 MFC after: 2 weeks commit 81479e688b0f643ffacd3f335b4b4bba460b769d Author: Kirk McKusick <mckusick@FreeBSD.org> Date: Thu Feb 11 18:14:53 2010 +0000 One last pass to get all the unsigned comparisons correct. In additional to the changes from FreeBSD, this commit includes quite a few related changes to appease -Wsign-compare.
2022-12-30s/succes/success/ in comments.andvar
2022-12-21ffs: fail mounts requesting ACLs for non-ea UFS2 file systemschs
For non-ea UFS2 file system, fail mounts that request ACLs rather than letting the mount succeed only to reject all ACL operations later. Also fix the messages about the on-disk fs flags conflicting with the mount options for which type of ACLs to use, and about requesting both types of ACLs.
2022-11-28the UFS_EXTATTR option was supposed to affect only UFS1 file systems,chs
but when the UFS2 extattr code was merged, the UFS_EXTATTR option was mistakenly changed to affect UFS2 file systems as well. this commit changes UFS_EXTATTR back to affecting only UFS1 file systems as originally intended. in UFS2 (or rather UFS2ea in NetBSD), extattrs are a native feature and are always supported.
2022-11-17Restore backward compatibility of UFS2 with previous NetBSD releases bychs
disabling support in UFS2 for extended attributes (including ACLs). Add a new variant of UFS2 called "UFS2ea" that does support extended attributes. Add new fsck_ffs operations "-c ea" and "-c no-ea" to convert file systems from UFS2 to UFS2ea and vice-versa (both of which delete all existing extended attributes in the process).
2022-11-10Some changes to "fs->fs_fmod" and "fs->fs_clean":hannken
- clear "fs->fs_fmod" after reading the super block. - assert we don't write a super block when mounted read-only. - make sure "fs->fs_clean" is one of FS_ISCLEAN or FS_WASCLEAN. - print "file system not clean" on every mount. Should fix PR kern/57010: ffs: mounting unclean non-root fs read-only causes spurious write to superblock
2022-08-07If UFS or LFS dirhash is enabled in the kernel, set the dirhash cachesimonb
size dependant on memory size. If less than 128MB of memory, default to no cache. With 128MB of memory or more, use a maximum cache size of 1/64th of memory; cap maximum default cache size to 32MB (for systems with 2GB of memory or more). The dirhash cache sizes are still explicityly setable by sysctl(8) or by adding relevant entry(s) to sysctl.conf(5).
2022-08-06s/blity/bility/ in various words, mainly in comments.andvar
2022-05-28s/grabing/grabbing/ in comments.andvar
2022-05-24fix various typos in comments, docs and log messages.andvar
2022-05-22fix various small typos, mainly in comments.andvar
2022-05-13Fix typo dallocate -> deallocatereinoud
2022-05-04s/entires/entries/ in local variable definition.andvar
2022-04-26Keep flag "UFS_QUOTA" set until the last quota is closed.hannken
Prevents a live lock when dqrele() finds a struct with "dq_cnt == 1" and flag "DQ_MOD" and cannot sync as flag UFS_QUOTA is unset.
2022-04-24lfs: fix lint warning about empty declarationrillig
2022-04-23Need vnode locked fot VOP_FDISCARD().hannken
2022-04-16Unlock vnode for VOP_IOCTL() and wapbl_flush().hannken
2022-04-16Take the link count from the inode.hannken
2022-04-08s/postion/position/andvar
2022-03-27add a kauth vnode check for creating linkschristos
2022-03-23fix few typos for word "previous(ly)" in comments.andvar
2022-03-19Remove now unused VV_LOCKSWORK, all file systems support locking.hannken
Remove unused predicates vn_locked() and vn_anylocked(). Welcome to 9.99.95
2022-03-19Switch MFS device node to real vnode locking, VV_LOCKSWORK now.hannken
2022-03-12ffs: Fix 64-bit inode integer truncation.riastradh
Reported-by: syzbot+1ae93e092d532582b809@syzkaller.appspotmail.com
2022-02-21Fix wrong assertion, the negatiopn of "a && b" is "!a || !b" so wehannken
need "DIP(ip, blocks) != 0" here. Should fix PR kern/56725 (Panic when ls directory with device nodes on an older ffs)
2021-12-14ffs: fix the creation of device nodes on file systems with ACLs enabled.chs
2021-12-14ffs: support extattrs (and thus ACLs) on fifos.chs
2021-12-10s/occured/occurred/ in comments, log messages and man pages.andvar
2021-12-07fix typos in word "instead", mainly in log messages.andvar
2021-12-07fix various typos, mainly in comments.andvar
2021-12-05s/shapshot/snapshot/msaitoh
2021-11-26use MNT_NFS4ACLS instead of MNT_ACLS (which was changed before to meanchristos
MNT_POSIX1EACLS)
2021-10-20Overhaul of the EVFILT_VNODE kevent(2) filter:thorpej
- Centralize vnode kevent handling in the VOP_*() wrappers, rather than forcing each individual file system to deal with it (except VOP_RENAME(), because VOP_RENAME() is a mess and we currently have 2 different ways of handling it; at least it's reasonably well-centralized in the "new" way). - Add support for NOTE_OPEN, NOTE_CLOSE, NOTE_CLOSE_WRITE, and NOTE_READ, compatible with the same events in FreeBSD. - Track which kevent notifications clients are interested in receiving to avoid doing work for events no one cares about (avoiding, e.g. taking locks and traversing the klist to send a NOTE_WRITE when someone is merely watching for a file to be deleted, for example). In support of the above: - Add support in vnode_if.sh for specifying PRE- and POST-op handlers, to be invoked before and after vop_pre() and vop_post(), respectively. Basic idea from FreeBSD, but implemented differently. - Add support in vnode_if.sh for specifying CONTEXT fields in the vop_*_args structures. These context fields are used to convey information between the file system VOP function and the VOP wrapper, but do not occupy an argument slot in the VOP_*() call itself. These context fields are initialized and subsequently interpreted by PRE- and POST-op handlers. - Version VOP_REMOVE(), uses the a context field for the file system to report back the resulting link count of the target vnode. Return this in tmpfs, udf, nfs, chfs, ext2fs, lfs, and ufs. NetBSD 9.99.92.
2021-10-15fix typos in comments.andvar
2021-10-10Use VN_KNOTE() to send our NOTE_ATTRIB and NOTE_REVOKE events.thorpej
2021-09-18Change the default for ACLs to be posix1e instead of nfsv4 to match FreeBSD.christos
Requested by chuq.
2021-09-16fix typos in word "successfully", mainly s/succesfully/successfully/.andvar
2021-09-03fix typos in comments, mainly s/extention/extension/ and s/sufficent/sufficient/andvar
2021-08-19s/memry/memory+s/softare/software/+s/grapics/graphics+s/ouput/outputandvar
2021-08-17fix multiplei repetitive typos in comments, messages and documentation. ↵andvar
mainly because copy paste code big amount of files are affected.
2021-08-11s/enrty/entry/andvar
2021-08-09s/fist/first/andvar
2021-07-31s/threshhold/thresholdandvar
2021-07-25#include <sys/param.h> for COHERENCY_UNIT (and KNF)skrll