summaryrefslogtreecommitdiff
path: root/sys/ufs/ffs
AgeCommit message (Collapse)Author
2004-06-04rootvp is already externed in systm.h, no need for a local externTed Unangst
2004-05-07fatty softdep merge with freebsd. fixes a variety of possible issues.Ted Unangst
relevant changes to ffs_softdep.c were 1.95, 1.96, 1.97, 1.98, 1.103, and 1.107 in freebsd. testing marc and otto. ok deraadt
2004-03-02silly fifos aren't a real fs, so we have to be sure to call reclaimTed Unangst
in the host fs.
2004-01-25vref device vnodes early, so we don't get mismatched vrele calls.Ted Unangst
problem found, fix tested naddy@
2004-01-20some pieces of ufs2. help testing otto sturmTed Unangst
2004-01-07sysctls for dirhash variables. with a hint from miod. ok deraadtTed Unangst
2003-11-19undo boolshit unapproved changes the author does not even care about to fixMichael Shalayeff
2003-11-19MALLOC is not meant for variable size allocationsTed Unangst
2003-10-17Be sure i_ffs_gen is always positive.Mike Pechkin
millert@, beck@, tedu@, deraadt@ ok
2003-10-04vrele swap and/or root vnode should we fail during mountroot; found by ↵Michael Shalayeff
mpech@ and tedu@ ok
2003-09-23Replace select backends with poll backends. selscan() and pollscan()Todd C. Miller
now call the poll backend. With this change we implement greater poll(2) functionality instead of emulating it via the select backend. Adapted from NetBSD and including some changes from FreeBSD. Tested by many, deraadt@ OK
2003-08-26constify ffs_tablesMichael Shalayeff
2003-08-25rename struct dinode to ufs1_dinode. clears the namespace and makesTed Unangst
way for some future work. no function changes yet. few other little cleanups. help testing otto@ and markus@
2003-08-14constify vfsops; tedu@ okMichael Shalayeff
2003-08-02newline at end of printfTed Unangst
2003-07-10in statfs, cast disk size to int64_t to prevent overflow on large disks.Ted Unangst
from Peter Galbavy
2003-06-26add prototypes for userland code that reaches over. ok deraadt@Ted Unangst
2003-06-10o make mount(2) return EROFS, not EPERM if ffs is dirtyTodd C. Miller
o document EROFS in man page (2 possible causes) o recognize EROFS in mount_ffs and try to give a reasonable error message deraadt@ OK
2003-06-02Remove the advertising clause in the UCB license which BerkeleyTodd C. Miller
rescinded 22 July 1999. Proofed by myself and Theo.
2003-05-26fiddle with some type names. change most instances of ufs_daddr_t toTed Unangst
ufs1_daddr_t, a few to daddr_t. ufs_daddr_t typedef is retained, but consider it deprecated. no functional changes. inspired by freebsd. ok art@
2003-05-14remove the last of the MI commonsJason Wright
2002-11-08Implement simple vnodeop inheritance for specfs and fifofs.Artur Grabowski
The inheritace is implemented by setting the default vnodeop to a bypass op that repeats the operation on the spec/fifo vnodeop vector. The overhead of one extra indirect function call is worth the cleanup and improved correctness. This actually solves a few bugs where some vnode ops were missing from some vectors (like kqfilter or revoke). (and even more on the ubc branch). Inspired by the same thing done in FreeBSD.
2002-10-12Remove more '\n's from panic() statements. Both trailing and leading.Kenneth R Westerback
Diff generated by Chris Kuethe.
2002-08-01Limit max file size based on PAGE_SIZE. Even though ffs can handleTodd C. Miller
files up to 16TB, we do limit the max file to 2^31 pages to prevent overflow of a 32-bit unsigned int. The buffer cache has its own checks but a little added paranoia never hurts. Adapted from a patch in FreeBSD.
2002-07-16Fix typo which prevents diagnostic test from working; enami@netbsd.orgTodd C. Miller
Fix two problems with softdep_typenames (missing entry, wrong boundary check); wiz@netbsd.org art@ OK
2002-07-12Change the locking on the mountpoint slightly. Instead of using mnt_lockArtur Grabowski
to get shared locks for lookup and get the exclusive lock only with LK_DRAIN on unmount and do the real exclusive locking with flags in mnt_flags, we now use shared locks for lookup and an exclusive lock for unmount. This is accomplished by slightly changing the semantics of vfs_busy. Old vfs_busy behavior: - with LK_NOWAIT set in flags, a shared lock was obtained if the mountpoint wasn't being unmounted, otherwise we just returned an error. - with no flags, a shared lock was obtained if the mountpoint was being unmounted, otherwise we slept until the unmount was done and returned an error. LK_NOWAIT was used for sync(2) and some statistics code where it isn't really critical that we get the correct results. 0 was used in fchdir and lookup where it's critical that we get the right directory vnode for the filesystem root. After this change vfs_busy keeps the same behavior for no flags and LK_NOWAIT. But if some other flags are passed into it, they are passed directly into lockmgr (actually LK_SLEEPFAIL is always added to those flags because if we sleep for the lock, that means someone was holding the exclusive lock and the exclusive lock is only held when the filesystem is being unmounted. More changes: dounmount must now be called with the exclusive lock held. (before this the caller was supposed to hold the vfs_busy lock, but that wasn't always true). Zap some (now) unused mount flags. And the highlight of this change: Add some vfs_busy calls to match some vfs_unbusy calls, especially in sys_mount. (lockmgr doesn't detect the case where we release a lock noone holds (it will do that soon)). If you've seen hangs on reboot with mfs this should solve it (I repeat this for the fourth time now, but this time I spent two months fixing and redesigning this and reading the code so this time I must have gotten this right).
2002-06-23uid_t and gid_t are unsignedTheo de Raadt
2002-06-08Remove this horror DIAGNOSTIC define. It was just ugly when itArtur Grabowski
was introduced, but now it causes crashes when kernels are built without DIAGNOSTIC. Instead of trying to debug this incorrect code, I'm just removing this abomination.
2002-06-08Let this build when the internal DIAGNOSTIC define is removed.Artur Grabowski
2002-04-23In mount.h, rename field export -> export_info, to avoid collision with C++.Marc Espie
Synch files that use that field. (This argument is an internal interface specific to OpenBSD, so it won't cause compatibility problems.) (No bump, not an ABI change). ok art, millert...
2002-03-14Final __P removal plus some cosmetic fixupsTodd C. Miller
2002-03-14First round of __P removal in sysTodd C. Miller
2002-02-22Extended Attribute support from FreeBSD/TrustedBSD ok art@, deraadt@Dale Rahn
2002-01-29process the delayed-free queue more often; chs@netbsd.orgTodd C. Miller
2002-01-25Move softdep sysctls from debug to vfs.ffs; art@ OKTodd C. Miller
2002-01-24sigh, nobody compiles before commit anymoreMichael Shalayeff
2002-01-23Convert to pool; based on changes NetBSDTodd C. Miller
We no longer use the last arg to WORKITEM_FREE but I have not removed it from the calls in order to simplify these diffs and further softdep merges.
2002-01-23Pool deals fairly well with physical memory shortage, but it doesn't dealArtur Grabowski
well (not at all) with shortages of the vm_map where the pages are mapped (usually kmem_map). Try to deal with it: - group all information the backend allocator for a pool in a separate struct. The pool will only have a pointer to that struct. - change the pool_init API to reflect that. - link all pools allocating from the same allocator on a linked list. - Since an allocator is responsible to wait for physical memory it will only fail (waitok) when it runs out of its backing vm_map, carefully drain pools using the same allocator so that va space is freed. (see comments in code for caveats and details). - change pool_reclaim to return if it actually succeeded to free some memory, use that information to make draining easier and more efficient. - get rid of PR_URGENT, noone uses it.
2002-01-04Handle truncation to the middle of a file hole. deraadt@ okThomas Nordin
From FreeBSD
2001-12-19UBC was a disaster. It worked very good when it worked, but on someArtur Grabowski
machines or some configurations or in some phase of the moon (we actually don't know when or why) files disappeared. Since we've not been able to track down the problem in two weeks intense debugging and we need -current to be stable, back out everything to a state it had before UBC. We apologise for the inconvenience.
2001-12-10Big cleanup inspired by NetBSD with some parts of the code from NetBSD.Artur Grabowski
- get rid of VOP_BALLOCN and VOP_SIZE - move the generic getpages and putpages into miscfs/genfs - create a genfs_node which must be added to the top of the private portion of each vnode for filsystems that want to use genfs_{get,put}pages - rename genfs_mmap to vop_generic_mmap
2001-12-10Merge in struct uvm_vnode into struct vnode.Artur Grabowski
2001-12-05Make DEBUG not default, and make the default compileNiklas Hallqvist
2001-12-04Readd VOP_MMAP, will be used soon. Right now it's just a question toArtur Grabowski
the filesystem if we're allowed to mmap the file.
2001-12-04FREE_LOCK_INTERLOCKED drops the lock owner without changing lock "state".Artur Grabowski
ACQUIRE_LOCK_INTERLOCKED set the owner back without validating that the state is ok. This could lead to changed states and FREE_LOCK could set spl to any random value. Try to preserve the state of the lock. XXX - all this locking in the code is insane. all this debugging code breaks stuff.
2001-12-01KNFTheo de Raadt
2001-11-30Don't brelse a random pointer in ffs_realloccg when filesystem is fullArtur Grabowski
and bpp == NULL.
2001-11-28Bug fixes from NetBSD.Artur Grabowski
In flush_inodedep_deps - release the lock before sleep. When allocating a pagecache dependency buffer - make sure it's always correctly initialized.
2001-11-27Merge in the unified buffer cache code as found in NetBSD 2001/03/10. TheArtur Grabowski
code is written mostly by Chuck Silvers <chuq@chuq.com>/<chs@netbsd.org>. Tested for the past few weeks by many developers, should be in a pretty stable state, but will require optimizations and additional cleanups.
2001-11-21Use vfs_mount_foreach_vnodeConstantine Sapuntzakis