summaryrefslogtreecommitdiffstats
path: root/sys/nfs/nfs_subs.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Store a unique ID, an interface index, rather than a pointer to thempi2015-06-161-2/+2
| | | | | | | | | | | | | | | receiving interface in the packet header of every mbuf. The interface pointer should now be retrieved when necessary with if_get(). If a NULL pointer is returned by if_get(), the interface has probably been destroy/removed and the mbuf should be freed. Such mechanism will simplify garbage collection of mbufs and limit problems with dangling ifp pointers. Tested by jmatthew@ and krw@, discussed with many. ok mikeb@, bluhm@, dlg@
* Tweaks utimensat/futimens handling to always update ctime, even when bothguenther2015-04-171-3/+26
| | | | | | | atime and mtime are UTIME_OMIT (at least for ufs, tmpfs, and ext2fs), and to correctly handle a timestamp of -1. ok millert@
* Remove some includes include-what-you-use claims don'tjsg2015-03-141-2/+1
| | | | | | | have any direct symbols used. Tested for indirect use by compiling amd64/i386/sparc64 kernels. ok tedu@ deraadt@
* First step towards making uiomove() take a size_t size argument:miod2015-02-101-2/+2
| | | | | | | - rename uiomove() to uiomovei() and update all its users. - introduce uiomove(), which is similar to uiomovei() but with a size_t. - rewrite uiomovei() as an uiomove() wrapper. ok kettenis@
* use NGROUPS_MAXderaadt2015-01-171-2/+2
|
* Explicitely include <uvm/uvm_extern.h> in order to build on variable page sizemiod2014-12-291-1/+2
| | | | architectures.
* change req pool alloc to null. add prwaitok here and nfs_node_pool whichtedu2014-12-231-4/+4
| | | | is also sleeping in all callers, but already used null
* convert one hot looking bcopy to memcpytedu2014-12-181-2/+2
|
* delete a whole mess of unnecessary caddr_t caststedu2014-12-181-3/+3
|
* move arc4random prototype to systm.h. more appropriate for most codetedu2014-11-181-2/+1
| | | | to include that than rdnvar.h. ok deraadt dlg
* bzero -> memsettedu2014-11-141-2/+2
|
* remove uneeded proc.h includesjsg2014-09-141-2/+1
| | | | ok mpi@ kspillner@
* decouple struct uvmexp into a new file, so that uvm_extern.h and sysctl.hderaadt2014-07-081-3/+1
| | | | | don't need to be married. ok guenther miod beck jsing kettenis
* If the v_type is going to change when loading the NFS attribute cache,jsing2013-11-271-1/+2
| | | | | | | | | purge the vnode from the namecache first. This prevents cache_purge() from later getting confused and trying to cache_zap() a namecache entry multiple times over, due to cache_zap() believing that the entry does not need to be removed from the vnode destinations queue. ok beck@
* Switch time_t, ino_t, clock_t, and struct kevent's ident and dataguenther2013-08-131-6/+4
| | | | | | | | | | | | | | | | | | | | members to 64bit types. Assign new syscall numbers for (almost all) the syscalls that involve the affected types, including anything with time_t, timeval, itimerval, timespec, rusage, dirent, stat, or kevent arguments. Add a d_off member to struct dirent and replace getdirentries() with getdents(), thus immensely simplifying and accelerating telldir/seekdir. Build perl with -DBIG_TIME. Bump the major on every single base library: the compat bits included here are only good enough to make the transition; the T32 compat option will be burned as soon as we've reached the new world are are happy with the snapshots for all architectures. DANGER: ABI incompatibility. Updating to this kernel requires extra work or you won't be able to login: install a snapshot instead. Much assistance in fixing userland issues from deraadt@ and tedu@ and build assistance from todd@ and otto@
* move the specfs code to a place people can see it; ok guenther thib krwderaadt2011-07-041-2/+2
|
* Bring back the "End the VOP experiment." diff, naddy's issues wherethib2010-12-211-6/+6
| | | | | | unrelated, and his alpha is much happier now. OK deraadt@
* Backout the VOP diff until the issues naddy was seeing on alpha (gcc3)thib2010-09-101-6/+6
| | | | have been resolved.
* Rename lookup/relookup to vfs_lookup/vfs_relookup.thib2010-09-091-2/+2
| | | | OK oga@, beck@, matthew@
* End the VOP experiment. Instead of the ridicolusly complicated operationthib2010-09-061-6/+6
| | | | | | | | | | | | | | | | | | | vector setup that has questionable features (that have, as far as I can tell never been used in practice, atleast not in OpenBSD), remove all the gunk and favor a simple struct full of function pointers that get set directly by each of the filesystems. Removes gobs of ugly code and makes things simpler by a magnitude. The only downside of this is that we loose the vnoperate feature so the spec/fifo operations of the filesystems need to be kept in sync with specfs and fifofs, this is no big deal as the API it self is pretty static. Many thanks to armani@ who pulled an earlier version of this diff to current after c2k10 and Gabriel Kihlman on tech@ for testing. Liked by many. "come on, find your balls" deraadt@.
* clean up a few things that where left to rot after bob's vfs cache work.thib2010-05-191-3/+1
| | | | | | | sync a few comments to reality (or remove them), remove the cn_hash member from struct componentname, spacing. ok beck@
* antsyjsg2009-10-191-85/+29
| | | | | | no binary change apart from nfsm_reqhead() which is clearly correct. ok thib@
* Backout the asyncio/aiod change, as it causes buf's to get hung.thib2009-09-021-4/+2
| | | | | | problem noticed by deraadt@ ok beck@
* move to having requests on a per nfsmount tailq instead of one global one.thib2009-08-251-11/+1
| | | | | | | | | | also make the rexmit timeout per nfsmount, and make sure to start/stop the timer appropriately. now the nfs_timer() only fires if there is work todo, not always at nfs_ticks (it did, even if there where no nfsmounts in the system!). OK blambert@
* Rework the way we do async I/O in nfs. Introduce separate buf queues forthib2009-08-201-2/+4
| | | | | | | | | | | | | | | | each mount, and when work is "found", peg an aiod to that mount todo the I/O. Make nfs_asyncio() a bit smarter when deciding when to do asyncio and when to force it sync, this is done by keeping the aiod's one two lists, an "idle" and an "all" list, so asyncio is only done when there are aiods hanging around todo it for us or are already pegged to the mount. Idea liked by at least beck@ (and I think art@). Extensive testing done by myself and jasper and a few others on various arch's. Ideas/Code from Net/Free. OK blambert@.
* Teach nfsm_fhtom about nfsm_info structsblambert2009-08-131-4/+4
| | | | ok thib@
* change version 3 post-operation attribute building function to notblambert2009-08-131-23/+12
| | | | | | use mbufs directly, but the shiny new nfsm_info struct ok thib@
* Use an RB tree instead of a hashtable for fh/node lookups.thib2009-08-101-4/+7
| | | | | | Idea from NetBSD. OK blambert@
* Remove the v2 writegather code. It did help alot back in the 80sthib2009-08-101-43/+1
| | | | | | | | | | but extensive performance benchmarking done by myself and jasper@ has shown that it doesn't help, at all - even on vaxens and in some cases it makes things significantly slower. "this excites me sexually" jetpack@ Tested by jasper@. OK blambert@
* group all of the on-stack variables that are uses by the nfsm_macrosthib2009-08-041-14/+7
| | | | | | | | | | | | | | to keep the data munging "state" into an nfsm_info structure. Each function now has this structure on its stack, and it and its members are now passed around so that the macros/functions can work there magic. this will make removing the nfsm_* macros way easier. Idea/code picked up from DragonflyBSD. Tested by krw@, jacekm@ and myself. OK blambert@.
* (struct foo *)0 -> NULL, every where I could find it.thib2009-07-201-4/+4
| | | | OK blambert@
* Remove the VREF() macro and replaces all instances with a call to verf(),thib2009-07-091-2/+2
| | | | | | | | | | | which is exactly what the macro does. Macro's that are nothing more then: #define FUNCTION(arg) function(arg) are almost always pointless and should go away. OK blambert@ Agreed by many.
* Remove unused procnums (NQNFS leftovers) and cleanup.thib2009-05-301-8/+2
| | | | OK blambert@ sometime ago
* retire the nfs rtt log code, this isnt really all thatthib2009-05-221-5/+1
| | | | | | | usefull, and has been disabled for a long long time. Cleans house a bit. OK blambert@
* Convert macros to functions to reduce kernel memory usage.blambert2009-04-131-1/+23
| | | | In snaps for a while (way too long, according to deraadt@)
* Convert a sizeable macro to a much-leaner function. Saves (IIRC) 5k on i386.blambert2009-03-301-1/+67
| | | | In snaps for a while.
* Use a timespec instead of a time_t for the clients nfsnodethib2009-01-241-3/+3
| | | | | | | | mtime, gives us better granularity, helps with cache consistency. Idea lifted from NetBSD. OK blambert@
* Start reworking NFS client mbuf handling by creating an interface whichblambert2009-01-201-8/+5
| | | | | | | | | | | | | requires well-formed mbuf chains to work. Existing function name is now a wrapper to this interface. Much, much more work to follow which will build on this. Truly change we can believe in. ok thib@, who would have preferred this in two commits, but I'm impatient :) testing on multiple arches (i386, arm, amd64, and sparc64 at least) by many, thanks to all who did so
* Trivial lvalue abuse fixes, no binary changes.grange2009-01-131-2/+3
| | | | ok millert@ tedu@
* fix a typo made in last commit, also slightly better wording forthib2008-12-241-3/+3
| | | | another comment.
* Replace the TRUE/FALSE defines with 1/0 respectively. This doesn'tthib2008-12-241-7/+6
| | | | | | | hurt readability and it was just plain annoying seeing them defined in every other .c file. OK blambert@
* use the shiny new nitems macrothib2008-11-241-2/+2
|
* Correctly invalidate attribute cache entries in case the vnode modepedro2008-08-251-3/+4
| | | | changes, okay beck@, tedu@ and thib@.
* After beck@ changed the way nfsiod's are notified of work, theblambert2008-08-081-7/+1
| | | | | | | nfs_iodwant array became unused. Garbage collect and free up a few bytes. ok thib@
* unroll the NFSMADV() macro and nuke itthib2008-06-151-2/+2
| | | | ok blambert@
* use nfsm_padlen() where appropriate;thib2008-06-141-3/+3
| | | | ok blambert@
* Kill one-liner macro which obfuscated mbuf pointer assignment.blambert2008-06-131-4/+2
| | | | | | | | Rescue nfsm_reqhead macro name and rename nfsm_reqh. End of one-liners from nfsm_subs.h. ok thib@
* remove rpc_auth_kerb variable, its now unused...thib2008-06-131-4/+2
|
* Replace one-line macro which only obfuscated the fact thatblambert2008-06-131-3/+3
| | | | | | the function it was named after took 4 arguments instead of 2. "get it in; get it in; get it in" thib@
* Remove now-vestigial bpos pointer from NFS. For building outgoingblambert2008-06-121-50/+33
| | | | | | | | | NFS mbufs, mbufs now contain all their internal buffer state internally, the way god intended. ok thib@ testing johan@ (and possibly merdely@; this diff's been around for a bit...)