summaryrefslogtreecommitdiffstats
path: root/sys/fs
Commit message (Collapse)AuthorAgeFilesLines
* KNFize rev.1.31.bde1997-10-271-4/+6
|
* Use unique sleep message strings.bde1997-10-271-4/+3
|
* Use bread() instead of cluster_read() for reading the last blockbde1997-10-271-2/+2
| | | | | | | | | | in a file. There was a (harmless, I think) off-by-1 error. This was fixed in ufs long ago (rev.1.21 of ufs_readwrite.c) but not in cd9660. cd9660_read() has stagnated in many other ways. It is closer to the Net/2 ufs_read() (which is was cloned from) than ufs_read() itself is.
* Removed unused #includes. The need for most of them went away withbde1997-10-277-14/+7
| | | | recent changes (docluster* and vfs improvements).
* VFS interior redecoration.phk1997-10-269-71/+38
| | | | | | | | | | | | | Rename vn_default_error to vop_defaultop all over the place. Move vn_bwrite from vfs_bio.c to vfs_default.c and call it vop_stdbwrite. Use vop_null instead of nullop. Move vop_nopoll from vfs_subr.c to vfs_default.c Move vop_sharedlock from vfs_subr.c to vfs_default.c Move vop_nolock from vfs_subr.c to vfs_default.c Move vop_nounlock from vfs_subr.c to vfs_default.c Move vop_noislocked from vfs_subr.c to vfs_default.c Use vop_ebadf instead of *_ebadf. Add vop_defaultop for getpages on master vnode in MFS.
* Fix the same leak as in nullfs. Now the lowervp is properly marked inactive.roberto1997-10-211-1/+5
| | | | Reviewed by: phk
* Fix the file leak bug. The lower layer wasn't informed the vnode was inactiveroberto1997-10-211-2/+8
| | | | | | | | and kept a reference, preventing the blocks to be reclaimed. Changed the comment in null_inactive to reflect the current situation. Reviewed by: phk
* Make a set of VOP standard lock, unlock & islocked VOP operators, whichphk1997-10-174-109/+18
| | | | | depend on the lock being located at vp->v_data. Saves 3x3 identical vop procs, more as the other filesystems becomes lock aware.
* VFS clean up "hekto commit"phk1997-10-166-23/+6
| | | | | | | | | | 1. Add defaults for more VOPs VOP_LOCK vop_nolock VOP_ISLOCKED vop_noislocked VOP_UNLOCK vop_nounlock and remove direct reference in filesystems. 2. Rename the nfsv2 vnop tables to improve sorting order.
* Another VFS cleanup "kilo commit"phk1997-10-169-475/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1. Remove VOP_UPDATE, it is (also) an UFS/{FFS,LFS,EXT2FS,MFS} intereface function, and now lives in the ufsmount structure. 2. Remove VOP_SEEK, it was unused. 3. Add mode default vops: VOP_ADVLOCK vop_einval VOP_CLOSE vop_null VOP_FSYNC vop_null VOP_IOCTL vop_enotty VOP_MMAP vop_einval VOP_OPEN vop_null VOP_PATHCONF vop_einval VOP_READLINK vop_einval VOP_REALLOCBLKS vop_eopnotsupp And remove identical functionality from filesystems 4. Add vop_stdpathconf, which returns the canonical stuff. Use it in the filesystems. (XXX: It's probably wrong that specfs and fifofs sets this vop, shouldn't it come from the "host" filesystem, for instance ufs or cd9660 ?) 5. Try to make system wide VOP functions have vop_* names. 6. Initialize the um_* vectors in LFS. (Recompile your LKMS!!!)
* VFS mega cleanup commit (x/N)phk1997-10-1612-413/+93
| | | | | | | | | | | | | | | | | | | | | | | 1. Add new file "sys/kern/vfs_default.c" where default actions for VOPs go. Implement proper defaults for ABORTOP, BWRITE, LEASE, POLL, REVOKE and STRATEGY. Various stuff spread over the entire tree belongs here. 2. Change VOP_BLKATOFF to a normal function in cd9660. 3. Kill VOP_BLKATOFF, VOP_TRUNCATE, VOP_VFREE, VOP_VALLOC. These are private interface functions between UFS and the underlying storage manager layer (FFS/LFS/MFS/EXT2FS). The functions now live in struct ufsmount instead. 4. Remove a kludge of VOP_ functions in all filesystems, that did nothing but obscure the simplicity and break the expandability. If a filesystem doesn't implement VOP_FOO, it shouldn't have an entry for it in its vnops table. The system will try to DTRT if it is not implemented. There are still some cruft left, but the bulk of it is done. 5. Fix another VCALL in vfs_cache.c (thanks Bruce!)
* vnops megacommitphk1997-10-154-197/+145
| | | | | | | | | | 1. Use the default function to access all the specfs operations. 2. Use the default function to access all the fifofs operations. 3. Use the default function to access all the ufs operations. 4. Fix VCALL usage in vfs_cache.c 5. Use VOCALL to access specfs functions in devfs_vnops.c 6. Staticize most of the spec and fifofs vnops functions. 7. Make UFS panic if it lacks bits of the underlying storage handling.
* Hmm, realign the vnops into two columns.phk1997-10-1511-91/+91
|
* Stylistic overhaul of vnops tables.phk1997-10-1511-567/+493
| | | | | | | 1. Remove comment stating the blatantly obvious. 2. Align in two columns. 3. Sort all but the default element alphabetically. 4. Remove XXX comments pointing out entries not needed.
* Last major round (Unless Bruce thinks of somthing :-) of malloc changes.phk1997-10-1211-29/+51
| | | | | | | | Distribute all but the most fundamental malloc types. This time I also remembered the trick to making things static: Put "static" in front of them. A couple of finer points by: bde
* Distribute and statizice a lot of the malloc M_* types.phk1997-10-112-2/+6
| | | | Substantial input from: bde
* Clustered read and write are switched at mount-option level.kato1997-09-274-28/+28
| | | | | | | | | | | | | | | | 1. Clustered I/O is switched by the MNT_NOCLUSTERR and MNT_NOCLUSTERW bits of the mnt_flag. The sysctl variables, vfs.foo.doclusterread and vfs.foo.doclusterwrite are deleted. Only mount option can control clustered I/O from userland. 2. When foofs_mount mounts block device, foofs_mount checks D_CLUSTERR and D_CLUSTERW bits of the d_flags member in the block device switch table. If D_NOCLUSTERR / D_NOCLUSTERW are set, MNT_NOCLUSTERR / MNT_NOCLUSTERW bits will be set. In this case, MNT_NOCLUSTERR and MNT_NOCLUSTERW cannot be cleared from userland. 3. Vnode driver disables both clustered read and write. 4. Union filesystem disables clutered write. Reviewed by: bde
* Change the M_NAMEI allocations to use the zone allocator. This changedyson1997-09-214-21/+21
| | | | | | | | plus the previous changes to use the zone allocator decrease the useage of malloc by half. The Zone allocator will be upgradeable to be able to use per CPU-pools, and has more intelligent usage of SPLs. Additionally, it has reasonable stats gathering capabilities, while making most calls inline.
* Executing binaries on a nullfs (or nullfs-based) filesystem results inphk1997-09-182-5/+7
| | | | | | | a trap. PR: 3104 Reviewed by: phk Submitted by: Dan Walters hannibal@cyberstation.net
* Convert select -> poll.peter1997-09-1410-106/+127
| | | | | Delete 'always succeed' select/poll handlers, replaced with generic call. Flag missing vnode op table entries.
* Fix a type in a comment and remove some checks now done centrally.phk1997-09-101-10/+2
|
* This stuff is now done centrally.phk1997-09-101-15/+1
|
* Removed yet more vestiges of config-time swap configuration and/orbde1997-09-071-8/+3
| | | | cleaned up nearby cruft.
* Staticized.bde1997-09-071-3/+3
|
* Some staticized variables were still declared to be extern.bde1997-09-076-13/+8
|
* Support read-only mount.kato1997-09-041-1/+39
|
* Removed unused #includes.bde1997-09-028-32/+8
|
* Include "opt_ddb.h" only when NULLFS_DIAGNOSTIC is defined.kato1997-08-281-3/+3
|
* Fixed NULLFS_DIAGNOSTIC stuff.kato1997-08-271-2/+11
|
* Uncut&paste cache_lookup().phk1997-08-266-119/+14
| | | | | | | | | | | | | | | This unifies several times in theory indentical 50 lines of code. The filesystems have a new method: vop_cachedlookup, which is the meat of the lookup, and use vfs_cache_lookup() for their vop_lookup method. vfs_cache_lookup() will check the namecache and pass on to the vop_cachedlookup method in case of a miss. It's still the task of the individual filesystems to populate the namecache with cache_enter(). Filesystems that do not use the namecache will just provide the vop_lookup method as usual.
* Back out some incorrect changes that was worse than the original bug.dyson1997-08-261-3/+1
|
* Added a sysctl arg, vfs.cd9660.doclusterread. Deleted debug andkato1997-08-251-16/+18
| | | | !FreeBSD code arround cluster read stuff.
* This is a trial improvement for the vnode reference count while on the vnodedyson1997-08-221-2/+4
| | | | | | free list problem. Also, the vnode age flag is no longer used by the vnode pager. (It is actually incorrect to use then.) Constructive feedback welcome -- just be kind.
* Fix all areas of the system (or at least all those in LINT) to avoid storingwollman1997-08-1610-31/+32
| | | | | | | | socket addresses in mbufs. (Socket buffers are the one exception.) A number of kernel APIs needed to get fixed in order to make this happen. Also, fix three protocol families which kept PCBs in mbufs to not malloc them instead. Delete some old compatibility cruft while we're at it, and add some new routines in the in_cksum family.
* Added DIAGNOSTIC routine to test inconsistency of vnode when cnpkato1997-08-151-1/+9
| | | | | | points `.'. Obtained from: NetBSD
* Deleted unused code which adjust UN_UNLOCK flag.kato1997-08-151-17/+5
|
* If the user doesn't have read permission, union_copyup should not copykato1997-08-141-1/+11
| | | | | | a file to upper layer. Reviewed by: Naofumi Honda <honda@Kururu.math.sci.hokudai.ac.jp>
* Backed out part of previous change. The example of -b mount inkato1997-08-141-4/+2
| | | | manpage works again.
* Fixed vnode corruption by undefined case in union_lookup(). Whenkato1997-08-121-3/+7
| | | | | | | | | | | uerror == 0 && lerror == EACCES, lowervp == NULLVP and union_allocvp doesn't find existing union node and new union node is created. Sicne it is dificult to cover all the case, union_lookup always returns when union_lookup1() returns EACCES. Submitted by: Naofumi Honda <honda@Kururu.math.sci.hokudai.ac.jp> Obtained from: NetBSD/pc98
* Check permissions for fp regs as well as normal regs.sef1997-08-121-1/+3
|
* Fix procfs security hole -- check permissions on meaningful I/Os (namely,sef1997-08-124-8/+43
| | | | | | | reading/writing of mem and regs). Also have to check for the requesting process being group KMEM -- this is a bit of a hack, but ps et al need it. Reviewed by: davidg
* Removed unused #includes.bde1997-08-0227-124/+28
|
* More comment cleanup.alex1997-06-261-5/+5
|
* Typo police.alex1997-06-261-3/+3
|
* Style fix my previous commit.alex1997-06-261-2/+2
|
* Block all write operations to /proc/1/* when securelevel > 0.alex1997-06-211-1/+3
| | | | | | | The additional check in procfs_ctl.c could be backed out, but I'm leaving it in for good measure. Reviewed by: Theo de Raadt <deraadt@OpenBSD.org>
* Don't remove the controlling tty from the session if the vnode is beingtegge1997-05-291-1/+2
| | | | cleaned. This should help for PR kern/3581.
* Fix some warnings (missing prototypes, wrong "generic" args etc)peter1997-05-253-9/+11
| | | | umapfs uses one of nullfs's functions...
* Remove redundant check for vp == dvp (done in VFS before calling).phk1997-05-171-10/+1
|
* 1. Added cast and parenthesis in block size calculaion inkato1997-05-072-78/+78
| | | | | | | union_statfs(). 2. staticized union vops. Submitted by: Doug Rabson <dfr@nlsystems.com>
OpenPOWER on IntegriCloud