summaryrefslogtreecommitdiffstats
path: root/sys/gnu/fs/ext2fs/fs.h
Commit message (Collapse)AuthorAgeFilesLines
* Bring in the ext2fs work done by Aditya Sarawgi during and after Google Summerlulf2010-01-141-170/+0
| | | | | | | | | | | | | | | of Code 2009: - BSDL block and inode allocation policies for ext2fs. This involves the use FFS1 style block and inode allocation for ext2fs. Preallocation was removed since it was GPL'd. - Make ext2fs MPSAFE by introducing locks to per-mount datastructures. - Fixes for kern/122047 PR. - Various small bugfixes. - Move out of gnu/ directory. Sponsored by: Google Inc. Submitted by: Aditya Sarawgi <sarawgi.aditya AT SPAMFREE gmail DOT com>
* VOP_LOCK1() (and so VOP_LOCK()) and VOP_UNLOCK() are only used inattilio2008-01-131-1/+1
| | | | | | | | | | | conjuction with 'thread' argument passing which is always curthread. Remove the unuseful extra-argument and pass explicitly curthread to lower layer functions, when necessary. KPI results broken by this change, which should affect several ports, so version bumping and manpage update will be further committed. Tested by: kris, pho, Diego Sardina <siarodx at gmail dot com>
* vn_lock() is currently only used with the 'curthread' passed as argument.attilio2008-01-101-1/+1
| | | | | | | | | | | | | | | | Remove this argument and pass curthread directly to underlying VOP_LOCK1() VFS method. This modify makes the code cleaner and in particular remove an annoying dependence helping next lockmgr() cleanup. KPI results, obviously, changed. Manpage and FreeBSD_version will be updated through further commits. As a side note, would be valuable to say that next commits will address a similar cleanup about VFS methods, in particular vop_lock1 and vop_unlock. Tested by: Diego Sardina <siarodx at gmail dot com>, Andrea Di Pasquale <whyx dot it at gmail dot com>
* Add a new struct buf flag bit, B_PERSISTENT, and use it to tagtruckman2005-09-081-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | struct bufs that are persistently held by ext2fs. Ignore any buffers with this flag in the code in boot() that counts "busy" and dirty buffers and attempts to sync the dirty buffers, which is done before attempting to unmount all the file systems during shutdown. This fixes the problem caused by any ext2fs file systems that are mounted at system shutdown time, which caused boot() to give up on a non-zero number of buffers and skip the call to vfs_unmountall(). This left all the mounted file systems in a dirty state and caused them to all require cleanup by fsck on reboot. Move the two separate copies of the "busy" buffer test in boot() to a separate function. Nuke the useless spl() stuff in the ext2fs ULCK_BUF() macro. Bring the PRINT_BUF_FLAGS definition in sys/buf.h up to date with this and previous flag changes. PR: kern/56675, kern/85163 Tested by: "Matthias Andree" matthias.andree at gmx.de Reviewed by: bde MFC after: 3 days
* /* -> /*- for copyright notices, minor format tweaks as necessaryimp2005-01-061-2/+2
|
* Remove advertising clause from University of California Regent'simp2004-04-071-4/+0
| | | | | | | license, per letter dated July 22, 1999 and email from Peter Wemm, Alan Cox and Robert Watson. Approved by: core, peter, alc, rwatson
* - Clean-up comments that refer to the use of B_LOCKED.jeff2003-08-281-2/+4
|
* - In LCK_BUF() simply change the owner of the buf to the kernel.jeff2003-08-281-10/+2
| | | | | | | | | | | | - In ULCK_BUF we no longer need to acquire the lock, just write the buf out. - The combination of these changes eliminates one more use of B_LOCKED which is in the way of making the buffer cache SMP safe. In the long term ext2fs should probably not try to optimize the use of their metadata bufs with a private cache. This will starve the rest of the system for buffers in the extreme case. Discussed with: bde (A long time ago..) Tested on: md disk/x86
* - Lock the buf before clearing flags.jeff2003-03-131-1/+1
|
* - Add an interlock argument to BUF_LOCK and BUF_TIMELOCK.jeff2003-02-251-1/+1
| | | | | | | | | | - Remove the buftimelock mutex and acquire the buf's interlock to protect these fields instead. - Hold the vnode interlock while locking bufs on the clean/dirty queues. This reduces some cases from one BUF_LOCK with a LK_NOWAIT and another BUF_LOCK with a LK_TIMEFAIL to a single lock. Reviewed by: arch, mckusick
* Complete the separation of ext2fs from ufs by copying the remainingiedowse2002-05-161-1/+1
| | | | | | | | | | shared code and converting all ufs references. Originally it may have made sense to share common features between the two filesystems, but recently it has only caused problems, the UFS2 work being the final straw. All UFS_* indirect calls are now direct calls to ext2_* functions, and ext2fs-specific mount and inode structures have been introduced.
* ARGH! SBLOCK is not unused. Try to get this right.phk2002-05-121-2/+1
| | | | | | | | BBSIZE belongs in <sys/disklabel.h> (but shouldn't be a constant). Define SBLOCK again, using the right math. Sponsored by: DARPA & NAI Labs.
* Remove #define for BBOFF, it is assumed == 0 so many places that we mightphk2002-05-121-2/+1
| | | | | | | as well forget about it. In fact the only thing which used it was the SBOFF macro. Sponsored by: DARPA & NAI Labs.
* Remove unused BBLOCK and SBLOCK #defines.phk2002-05-121-2/+0
| | | | Sponsored by: DARPA & NAI Labs.
* KSE Milestone 2julian2001-09-121-2/+2
| | | | | | | | | | | | | | Note ALL MODULES MUST BE RECOMPILED make the kernel aware that there are smaller units of scheduling than the process. (but only allow one thread per process at this time). This is functionally equivalent to teh previousl -current except that there is a thread associated with each process. Sorry john! (your next MFC will be a doosie!) Reviewed by: peter@freebsd.org, dillon@freebsd.org X-MFC after: ha ha ha ha
* Quick fix for not writing group descriptor group, inode bitmaps orbde2000-11-101-1/+2
| | | | | | | | | | | | | block bitmaps before unmount() completes. They were written using bdwrite(), so they were normally written less than 32 seconds after unmount(), but this is too late if the media is removed or the system is rebooted soon after unmount(). sync()ing before unmount() didn't help, because ext2fs uses buggy private caching for these blocks -- it doesn't even bdwrite() them until they are uncached or the filesystem is unmounted. sync()ing after unmount() didn't help, because sync() only applies to (vnodes for) mounted filesystems. PR: 22726
* Convert buffer locking from using the B_BUSY and B_WANTED flags to usingmckusick1999-06-261-1/+1
| | | | | | | lockmgr locks. This commit should be functionally equivalent to the old semantics. That is, all buffer locking is done with LK_EXCLUSIVE requests. Changes to take advantage of LK_SHARED and LK_RECURSIVE will be done in future commits.
* Quick fix for not being able to sync all the buffers in boot() ifbde1998-10-031-3/+9
| | | | | | | | | | | | | an ext2fs file system is mounted. The soft update changes added a check for B_DELWRI buffers. This exposed the complete brokenness of the previous quick fix for failing syncs (PR 3571, committed on 1997/08/04). Use a new buffer flag B_DIRTY and don't abuse B_DELWRI. B_DIRTY buffers are still written too late, as broken in the previous fix. This is fairly harmless, because B_DIRTY is only used for bitmap buffers and fsck.ext2 can fix up the bitmaps perfectly. Fixed a race in ULCK_BUF() (bremfree() was outside of the splbio() section).
* Fix a problem with ext2fs so that filesystems mounted at reboot don'tdyson1997-08-041-0/+20
| | | | | | | | | keep ahold of buffers, and therefore leave filesystems dirty. I haven't been able to test, but the code compiles. Those who run -current, please test and report back!!! (Sorry :-)). PR: kern/3571 Submitted by: Dirk Keunecke <dk@panda.rhein-main.de>
* This is the kernel Lite/2 commit. There are some requisite userlanddyson1997-02-101-2/+2
| | | | | | | | | | | | | | | changes, so don't expect to be able to run the kernel as-is (very well) without the appropriate Lite/2 userland changes. The system boots and can mount UFS filesystems. Untested: ext2fs, msdosfs, NFS Known problems: Incorrect Berkeley ID strings in some files. Mount_std mounts will not work until the getfsent library routine is changed. Reviewed by: various people Submitted by: Jeffery Hsu <hsu@freebsd.org>
* Main code for the ext2fs filesystem. Please refer to the COPYRIGHT.INFOdyson1995-11-051-0/+157
file for GPL restrictions. This code was ported to the BSD platform by Godmar Back <gback@facility.cs.utah.edu> and specifically to FreeBSD by John Dyson. This code is still green and should be used with caution. Additional changes to UFS necessary to make this code work will be commited seperately. Submitted by: Godmar Back <gback@facility.cs.utah.edu> Obtained from: Lites/Mach4
OpenPOWER on IntegriCloud