summaryrefslogtreecommitdiff
path: root/sys/kern/vfs_subr.c
AgeCommit message (Collapse)Author
2002-03-14First round of __P removal in sysTodd C. Miller
2002-02-04Cleanup mountroot-related definitions.Miod Vallat
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.
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-10No need to initialize the uobj on every getnewvnode. Just doArtur Grabowski
it when allocating. Add some improved diagnostics.
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-05Break out the part that lowers v_holdcnt in brelvp into an own functionArtur Grabowski
and make it and vhold into public interfaces.
2001-11-29Ooops. Revert part of the last commit that was completly wrong and wasn't ↵Artur Grabowski
supposed to be committed.
2001-11-29Correctly handle b_vp with bgetvp and brelvp in {get,put}pages.Artur Grabowski
Prevents panics caused by vnodes being recycled under our feet.
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-21Added vfs_isbusy. Useful for verifying that a mount point is lockedConstantine Sapuntzakis
Added vfs_mount_foreach_vnode. Several places in the code seem to want to traverse the mount list and they all seem to handle locking differently. Centralize traversing the mount list in one place so that we only need to get the locking right once.
2001-11-15Don't zero v_bioflag when recycling a vnode in getnewvnode.Artur Grabowski
Sometimes the vnode can be on the syncers list. While that is a bug, it's just a minor annoyance. A vnode on a syncer worklist without VBIOONSYNCLIST set is a disaster.
2001-11-12Remove unnecessary check for NULL vnode in reassignbuf.Artur Grabowski
2001-11-06Replace inclusion of <vm/foo.h> with the correct <uvm/bar.h> when necessary.Miod Vallat
(Look ma, I might have broken the tree)
2001-10-02Bounds check index into routing table. Thanks to Ken Ashcraft of StanfordConstantine Sapuntzakis
for finding this bug.
2001-09-19Get rid of B_VFLUSH. Not relevant after the end of the AGE queue.Constantine Sapuntzakis
2001-09-16Add some missing lengths checks when passing data from userland toTodd C. Miller
kernel. From based on NetBSD patches.
2001-08-02(vput): make panic strings actually say vput instead of vreleassar
2001-07-26Typo.Miod Vallat
2001-06-27remove old vmArtur Grabowski
2001-06-22KNFTheo de Raadt
2001-06-05send note_revoke to knotes when vnode goes away, okay art@Niels Provos
2001-05-16indentation nit.Artur Grabowski
2001-04-29cleanup, remove incorrect commentArtur Grabowski
2001-03-22Use pool for allocating vnodes.Artur Grabowski
Even though vnodes are never freed (could be) this gives us big memory and kmem_map savings.
2001-03-21uvm_vnp_terminate expect the vnode to be locked.Artur Grabowski
Why didn't LOCKDEBUG catch this?
2001-03-16Oops. fix thinko in last.Artur Grabowski
2001-03-16Use CIRCLEQ macros for mountlist.Artur Grabowski
2001-03-16Initialize the mountlist_slock.Artur Grabowski
2001-02-26Move v_writecount test back to it original placeConstantine Sapuntzakis
2001-02-26Make ref counts 32-bit unsigned ints as opposed to a potpourri of longs andConstantine Sapuntzakis
ints.
2001-02-24Cleanup of vnode interface continues. Get rid of VHOLD/HOLDRELE.Constantine Sapuntzakis
Change VM/UVM to use buf_replacevnode to change the vnode associated with a buffer. Addition v_bioflag for flags written in interrupt handlers (and read at splbio, though not strictly necessary) Add vwaitforio and use it instead of a while loop of v_numoutput. Fix race conditions when manipulation vnode free list
2001-02-23Remove the clustering fields from the vnodes and place them in theConstantine Sapuntzakis
file system inode instead
2001-02-21Latest soft updates from FreeBSD/Kirk McKusickConstantine Sapuntzakis
Snapshot-related code has been commented out.
2001-02-08do not print stuff when not verboseMichael Shalayeff
2000-09-27Minimal optimization.Artur Grabowski
2000-07-17Don't wait for B_READ buffers on shutdown.Artur Grabowski
From NetBSD.
2000-04-25Use CIRCLEQ_FOREACHConstantine Sapuntzakis
2000-04-21see if there is any meaning under curproc before using &proc0 in ↵Michael Shalayeff
vfs_syncwait(); from art@
1999-12-05With soft updates, some buffers will be remarked as dirty after being written.Artur Grabowski
Handle this when syncing filesystems when unmounting. From NetBSD.
1999-12-05Use VONSYNCLIST to see if we should remove a vnode from the sync list insteadArtur Grabowski
of looking at v_dirtyblkhd.
1999-08-20more paranoid check of the refcount in vfs_registerArtur Grabowski
1999-08-08From NetBSD; vdevgone, used for revoking access to device nodes when theyNiklas Hallqvist
disappear (detach is coming).
1999-05-31New struct statfs with mount options. NOTE: this replaces statfs(2),Todd C. Miller
fstatfs(2), and getfsstat(2) so you will need to build a new kernel before doing a "make build" or you will get "unimplemented syscall" errors. The new struct statfs has the following featuires: o Has a u_int32_t flags field--now softdep can have a real flag. o Uses u_int32_t instead of longs (nicer on the alpha). Note: the man page used to lie about setting invalid/unused fields to -1. SunOS does that but our code never has. o Gets rid of f_type completely. It hasn't been used since NetBSD 0.9 and having it there but always 0 is confusing. It is conceivable that this may cause some old code to not compile but that is better than silently breaking. o Adds a mount_info union that contains the FSTYPE_args struct. This means that "mount" can now tell you all the options a filesystem was mounted with. This is especially nice for NFS. Other changes: o The linux statfs emulation didn't convert between BSD fs names and linux f_type numbers. Now it does, since the BSD f_type number is useless to linux apps (and has been removed anyway) o FreeBSD's struct statfs is different from our (both old and new) and thus needs conversion. Previously, the OpenBSD syscalls were used without any real translation. o mount(8) will now show extra info when invoked with no arguments. However, to see *everything* you need to use the -v (verbose) flag.
1999-05-06factor out sync+wait code into vfa_syncwait() routine forMichael Shalayeff
applications in system like power management and such. art@ finally said `commit it'
1999-04-30in vput, simple_unlock the v_interlock before VOP_INACTIVE, not afterArtur Grabowski
1999-03-11backoutTheo de Raadt
1999-03-11back out unapproved changesTheo de Raadt
1999-03-11indentMichael Shalayeff