summaryrefslogtreecommitdiffstats
path: root/sys/nfsserver
Commit message (Collapse)AuthorAgeFilesLines
* Staticize.phk1995-12-177-55/+60
|
* Untangled the vm.h include file spaghetti.dg1995-12-072-2/+8
|
* Completed function declarations and/or added prototypes and/or movedbde1995-12-034-79/+112
| | | | prototypes to the right place.
* Completed function declarations, added prototypes and removed redundantbde1995-11-212-38/+96
| | | | declarations.
* Completed function declarations and/or added prototypes.bde1995-11-212-2/+8
|
* Included <sys/sysproto.h> to get central declarations for syscall argsbde1995-11-141-1/+6
| | | | | | | | | | structs and prototypes for syscalls. Ifdefed duplicated decentralized declarations of args structs. It's convenient to have this visible but they are hard to maintain. Some are already different from the central declarations. 4.4lite2 puts them in comments in the function headers but I wanted to avoid the large changes for that.
* Include a prerequisite header (so this is consistent again with thejoerg1995-10-312-2/+6
| | | | NFSv2 state).
* Second batch of cleanup changes.phk1995-10-296-35/+15
| | | | | This time mostly making a lot of things static and some unused variables here and there.
* Added NFS_ASYNC kernel option. It only has an effect for NFSv2.dg1995-08-241-1/+11
|
* Killed redundant declarations of nfsm_rpchead().dg1995-08-241-2/+1
|
* Some fixes found using gcc -Wall:dfr1995-08-242-5/+11
| | | | | | | | | | nfsm_rpchead() has been called with the wrong number of args and misplaced args since someone added new args in the middle for nfsv3. Here's another one that would be important on 64-bit systems. VOP_READDIR takes a `u_int **cookies' arg. Submitted by: Bruce Evans <bde@zeta.org.au>
* Add support for amd direct maps.dfr1995-08-241-2/+2
| | | | Reviewed by: Thomas Graichen <graichen@sirius.physik.fu-berlin.de>
* Fixed bug where vnode_pager_uncache() wasn't always called when it shoulddg1995-08-061-3/+2
| | | | | | | be. The result was that the file's space wouldn't be properly freed when it was deleted. Submitted by: John Dyson
* Slight changes to locking around VOP_READRIR.dfr1995-08-031-2/+18
| | | | | Detect in nfsrv_readdirplus when a filesystem soes not support VFS_VGET and return NFSERR_NOTSUPP so that the client will use ordinary readdir instead.
* Lock the directory vnode before VOP_READDIR in nfsrv_readdirplusdfr1995-08-021-1/+3
|
* Removed my special-case hack for VOP_LINK and fixed the problem with thedg1995-08-011-2/+2
| | | | | | | wrong vp's ops vector being used by changing the VOP_LINK's argument order. The special-case hack doesn't go far enough and breaks the generic bypass routine used in some non-leaf filesystems. Pointed out by Kirk McKusick.
* Eliminate sloppy common-style declarations. There should be none left forbde1995-07-293-13/+23
| | | | the LINT configuation.
* vnode_pager_alloc() never returns NULL, so don't check for it.dg1995-07-201-3/+2
|
* NOTE: libkvm, w, ps, 'top', and any other utility which depends on structdg1995-07-131-8/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | proc or any VM system structure will have to be rebuilt!!! Much needed overhaul of the VM system. Included in this first round of changes: 1) Improved pager interfaces: init, alloc, dealloc, getpages, putpages, haspage, and sync operations are supported. The haspage interface now provides information about clusterability. All pager routines now take struct vm_object's instead of "pagers". 2) Improved data structures. In the previous paradigm, there is constant confusion caused by pagers being both a data structure ("allocate a pager") and a collection of routines. The idea of a pager structure has escentially been eliminated. Objects now have types, and this type is used to index the appropriate pager. In most cases, items in the pager structure were duplicated in the object data structure and thus were unnecessary. In the few cases that remained, a un_pager structure union was created in the object to contain these items. 3) Because of the cleanup of #1 & #2, a lot of unnecessary layering can now be removed. For instance, vm_object_enter(), vm_object_lookup(), vm_object_remove(), and the associated object hash list were some of the things that were removed. 4) simple_lock's removed. Discussion with several people reveals that the SMP locking primitives used in the VM system aren't likely the mechanism that we'll be adopting. Even if it were, the locking that was in the code was very inadequate and would have to be mostly re-done anyway. The locking in a uni-processor kernel was a no-op but went a long way toward making the code difficult to read and debug. 5) Places that attempted to kludge-up the fact that we don't have kernel thread support have been fixed to reflect the reality that we are really dealing with processes, not threads. The VM system didn't have complete thread support, so the comments and mis-named routines were just wrong. We now use tsleep and wakeup directly in the lock routines, for instance. 6) Where appropriate, the pagers have been improved, especially in the pager_alloc routines. Most of the pager_allocs have been rewritten and are now faster and easier to maintain. 7) The pagedaemon pageout clustering algorithm has been rewritten and now tries harder to output an even number of pages before and after the requested page. This is sort of the reverse of the ideal pagein algorithm and should provide better overall performance. 8) Unnecessary (incorrect) casts to caddr_t in calls to tsleep & wakeup have been removed. Some other unnecessary casts have also been removed. 9) Some almost useless debugging code removed. 10) Terminology of shadow objects vs. backing objects straightened out. The fact that the vm_object data structure escentially had this backwards really confused things. The use of "shadow" and "backing object" throughout the code is now internally consistent and correct in the Mach terminology. 11) Several minor bug fixes, including one in the vm daemon that caused 0 RSS objects to not get purged as intended. 12) A "default pager" has now been created which cleans up the transition of objects to the "swap" type. The previous checks throughout the code for swp->pg_data != NULL were really ugly. This change also provides the rudiments for future backing of "anonymous" memory by something other than the swap pager (via the vnode pager, for example), and it allows the decision about which of these pagers to use to be made dynamically (although will need some additional decision code to do this, of course). 13) (dyson) MAP_COPY has been deprecated and the corresponding "copy object" code has been removed. MAP_COPY was undocumented and non- standard. It was furthermore broken in several ways which caused its behavior to degrade to MAP_PRIVATE. Binaries that use MAP_COPY will continue to work correctly, but via the slightly different semantics of MAP_PRIVATE. 14) (dyson) Sharing maps have been removed. It's marginal usefulness in a threads design can be worked around in other ways. Both #12 and #13 were done to simplify the code and improve readability and maintain- ability. (As were most all of these changes) TODO: 1) Rewrite most of the vnode pager to use VOP_GETPAGES/PUTPAGES. Doing this will reduce the vnode pager to a mere fraction of its current size. 2) Rewrite vm_fault and the swap/vnode pagers to use the clustering information provided by the new haspage pager interface. This will substantially reduce the overhead by eliminating a large number of VOP_BMAP() calls. The VOP_BMAP() filesystem interface should be improved to provide both a "behind" and "ahead" indication of contiguousness. 3) Implement the extended features of pager_haspage in swap_pager_haspage(). It currently just says 0 pages ahead/behind. 4) Re-implement the swap device (swstrategy) in a more elegant way, perhaps via a much more general mechanism that could also be used for disk striping of regular filesystems. 5) Do something to improve the architecture of vm_object_collapse(). The fact that it makes calls into the swap pager and knows too much about how the swap pager operates really bothers me. It also doesn't allow for collapsing of non-swap pager objects ("unnamed" objects backed by other pagers).
* Moved call to VOP_GETATTR() out of vnode_pager_alloc() and into the placesdg1995-07-091-3/+10
| | | | | | that call vnode_pager_alloc() so that a failure return can be dealt with. This fixes a panic seen on NFS clients when a file being opened is deleted on the server before the open completes.
* 1) Converted v_vmdata to v_object.dg1995-06-282-34/+30
| | | | | | | 2) Removed unnecessary vm_object_lookup()/pager_cache(object, TRUE) pairs after vnode_pager_alloc() calls - the object is already guaranteed to be persistent. 3) Removed some gratuitous casts.
* Fixed VOP_LINK argument order botch.dg1995-06-281-2/+2
|
* Changes to support version 3 of the NFS protocol.dfr1995-06-2710-1477/+4937
| | | | | | | | | | | | | | | | | | The version 2 support has been tested (client+server) against FreeBSD-2.0, IRIX 5.3 and FreeBSD-current (using a loopback mount). The version 2 support is stable AFAIK. The version 3 support has been tested with a loopback mount and minimally against an IRIX 5.3 server. It needs more testing and may have problems. I have patched amd to support the new variable length filehandles although it will still only use version 2 of the protocol. Before booting a kernel with these changes, nfs clients will need to at least build and install /usr/sbin/mount_nfs. Servers will need to build and install /usr/sbin/mountd. NFS diskless support is untested. Obtained from: Rick Macklem <rick@snowhite.cis.uoguelph.ca>
* The duplicate information returned in fa_type and fa_modejoerg1995-06-141-2/+21
| | | | | | | | | | | | | | | | | | | | | | | is an ambiguity in the NFS version 2 protocol. VREG should be taken literally as a regular file. If a server intents to return some type information differently in the upper bits of the mode field (e.g. for sockets, or FIFOs), NFSv2 mandates fa_type to be VNON. Anyway, we leave the examination of the mode bits even in the VREG case to avoid breakage for bogus servers, but we make sure that there are actually type bits set in the upper part of fa_mode (and failing that, trust the va_type field). NFSv3 cleared the issue, and requires fa_mode to not contain any type information (while also introduing sockets and FIFOs for fa_type). The fix has been tested against a variety of NFS servers. It fixes problems with the ``Tropic'' NFS server for Windows, while apparently not breaking anything. Pointed-out by: scott@zorch.sf-bay.org (Scott Hazen Mueller)
* Merge RELENG_2_0_5 into HEADrgrimes1995-06-111-6/+1
|
* Remove trailing whitespace.rgrimes1995-05-305-22/+22
|
* Fixed some serious bugs that resulted in object reference counts not beingdg1995-05-292-4/+36
| | | | | | | | handled correctly. This would manifest itself as "object deallocated too many times" panics and perhaps other strange inconsistencies on NFS servers. Reviewed by: me, of course Submitted by: John Dyson
* Slight re-ordering of the creation of a vmio object to fix a conditiondyson1995-04-211-2/+4
| | | | that can cause NFS I/O failures.
* Removed unnecessary call to vnode_pager_uncache(). We automatically cleardg1995-03-191-4/+3
| | | | the VTEXT flag after all mappers have finished with the object.
* Changed some (incorrect) nfsrv_vput()'s back into regular vput()'s. Thisdg1995-03-171-4/+4
| | | | fixes the last of the known NQNFS problems (until I find more, that is :-)).
* Add and move declarations to fix all of the warnings from `gcc -Wimplicit'bde1995-03-162-6/+2
| | | | | | (except in netccitt, netiso and netns) and most of the warnings from `gcc -Wnested-externs'. Fix all the bugs found. There were no serious ones.
* YF fix.phk1995-02-151-3/+4
|
* Fixed two more bugs related to the merged cache changes.dg1995-02-151-2/+2
| | | | Submitted by: John Dyson
* Woops, change a nfsrv_vput back into a nfsrv_vrele.dg1995-02-151-2/+2
| | | | Submitted by: John Dyson
* Fixed three bugs related to the merged cache changes. The bugs likely woulddg1995-02-151-4/+4
| | | | | | make NFS servers flakey - probably the cause of freefall's recent hangs. Submitted by: John Dyson
* YFfixphk1995-02-142-2/+10
| | | | | | +int nfsrv_vput __P(( struct vnode * )); +int nfsrv_vrele __P(( struct vnode * )); +int nfsrv_vmio __P(( struct vnode * ));
* Changed order of release of vnode/object to fix a problem where the vnodedg1995-02-061-4/+7
| | | | | | | is freed with an old object still attached (subsequently causing a panic). Fixes NFS server panic "object/pager mismatch". Submitted by: John Dyson
* These changes embody the support of the fully coherent merged VM buffer cache,dg1995-01-092-87/+140
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | much higher filesystem I/O performance, and much better paging performance. It represents the culmination of over 6 months of R&D. The majority of the merged VM/cache work is by John Dyson. The following highlights the most significant changes. Additionally, there are (mostly minor) changes to the various filesystem modules (nfs, msdosfs, etc) to support the new VM/buffer scheme. vfs_bio.c: Significant rewrite of most of vfs_bio to support the merged VM buffer cache scheme. The scheme is almost fully compatible with the old filesystem interface. Significant improvement in the number of opportunities for write clustering. vfs_cluster.c, vfs_subr.c Upgrade and performance enhancements in vfs layer code to support merged VM/buffer cache. Fixup of vfs_cluster to eliminate the bogus pagemove stuff. vm_object.c: Yet more improvements in the collapse code. Elimination of some windows that can cause list corruption. vm_pageout.c: Fixed it, it really works better now. Somehow in 2.0, some "enhancements" broke the code. This code has been reworked from the ground-up. vm_fault.c, vm_page.c, pmap.c, vm_object.c Support for small-block filesystems with merged VM/buffer cache scheme. pmap.c vm_map.c Dynamic kernel VM size, now we dont have to pre-allocate excessive numbers of kernel PTs. vm_glue.c Much simpler and more effective swapping code. No more gratuitous swapping. proc.h Fixed the problem that the p_lock flag was not being cleared on a fork. swap_pager.c, vnode_pager.c Removal of old vfs_bio cruft to support the past pseudo-coherency. Now the code doesn't need it anymore. machdep.c Changes to better support the parameter values for the merged VM/buffer cache scheme. machdep.c, kern_exec.c, vm_glue.c Implemented a seperate submap for temporary exec string space and another one to contain process upages. This eliminates all map fragmentation problems that previously existed. ffs_inode.c, ufs_inode.c, ufs_readwrite.c Changes for merged VM/buffer cache. Add "bypass" support for sneaking in on busy buffers. Submitted by: John Dyson and David Greenman
* Forward-declare a few structures to avoid warning messages.wollman1994-11-022-2/+8
|
* Implement fs.nfs MIB variables.wollman1994-10-232-4/+24
|
* This is a bunch of changes from NetBSD. There are a couple of bug-fixes.phk1994-10-178-240/+196
| | | | | | | But mostly it is changes to use the list-maintenance macros instead of doing the pointer-gymnastics by hand. Obtained from: NetBSD
* Prototyping and general gcc-shutting up. Gcc has one warning now which looksphk1994-10-028-128/+321
| | | | bad, I will get to it eventually, unless somebody beats me to it.
* Make NFS ask the filesystems for directory cookies instead of making themdfr1994-09-281-39/+65
| | | | itself.
* Make NFS loadable.wollman1994-09-221-0/+25
|
* More loadable VFS changes:wollman1994-09-222-12/+2
| | | | | | | | - Make a number of filesystems work again when they are statically compiled (blush) - FIFOs are no longer optional; ``options FIFO'' removed from distributed config files.
* "bogus" fixes from 1.1.5 to work around some cache coherency problems.dg1994-08-291-3/+2
|
* More idempotency....... this is fun :-)paul1994-08-214-4/+23
|
* Made NFS attribute cache timeouts kernel config file tunable viadg1994-08-042-2/+10
| | | | NFS_MINATTRTIMO and NFS_MAXATTRTIMO.
* Added $Id$dg1994-08-029-0/+9
|
* The big 4.4BSD Lite to FreeBSD 2.0.0 (Development) patch.rgrimes1994-05-255-9/+69
| | | | | Reviewed by: Rodney W. Grimes Submitted by: John Dyson and David Greenman
OpenPOWER on IntegriCloud