OpenBSD CVS

CVS log for src/sys/nfs/nfs_subs.c


[BACK] Up to [local] / src / sys / nfs

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.149 / (download) - annotate - [select for diffs], Wed May 1 13:15:59 2024 UTC (4 weeks, 4 days ago) by jsg
Branch: MAIN
CVS Tags: HEAD
Changes since 1.148: +1 -3 lines
Diff to previous 1.148 (colored)

remove unneeded includes
ok miod@ mpi@

Revision 1.148 / (download) - annotate - [select for diffs], Tue Apr 30 17:05:20 2024 UTC (4 weeks, 4 days ago) by miod
Branch: MAIN
Changes since 1.147: +36 -34 lines
Diff to previous 1.147 (colored)

Constify NFS data whenever possible. Also make a few more const data static.

ok jsg@ semarie@

Revision 1.147 / (download) - annotate - [select for diffs], Tue Apr 30 17:04:23 2024 UTC (4 weeks, 4 days ago) by miod
Branch: MAIN
Changes since 1.146: +56 -42 lines
Diff to previous 1.146 (colored)

Convert all the NFS macros (in nfsm_subs.h) into inline functions with the
appropriate extra arguments.

This (hopefully) completes the unmessyfication work started by thib@ a long,
long time ago (in a galaxy far away).

The conversion logic has been:
- nfsm_dissect has been turned into an rvalue expression, leaving the
  cast operation up to its caller.
- macros which had three different exit paths (return, goto nfsmout or
  fallthrough) have been split so that no macros have more than two exit paths.
- then they have been modified to return a value, which lets the caller
  figure out what exit path is needed.
- local variables abused by the macros are now local variables of the new
  inline functions.

This single commit is the sum of 25 intermediate diffs, which have all been
carefully reviewed by (at least) jsg@ and semarie@.

Tested with v2 and v3 servers and clients.

ok jsg@ semarie@

Revision 1.146 / (download) - annotate - [select for diffs], Wed Jan 12 20:17:08 2022 UTC (2 years, 4 months ago) by mbuhl
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE, OPENBSD_7_5, OPENBSD_7_4_BASE, OPENBSD_7_4, OPENBSD_7_3_BASE, OPENBSD_7_3, OPENBSD_7_2_BASE, OPENBSD_7_2, OPENBSD_7_1_BASE, OPENBSD_7_1
Changes since 1.145: +2 -1 lines
Diff to previous 1.145 (colored)

fixup previous refactoring
OK stsp@ (without assuming any responsibility for NFS)

Revision 1.145 / (download) - annotate - [select for diffs], Tue Jan 11 03:13:59 2022 UTC (2 years, 4 months ago) by jsg
Branch: MAIN
Changes since 1.144: +2 -2 lines
Diff to previous 1.144 (colored)

spelling
ok jmc@

Revision 1.144 / (download) - annotate - [select for diffs], Wed Jun 24 22:03:44 2020 UTC (3 years, 11 months ago) by cheloha
Branch: MAIN
CVS Tags: OPENBSD_7_0_BASE, OPENBSD_7_0, OPENBSD_6_9_BASE, OPENBSD_6_9, OPENBSD_6_8_BASE, OPENBSD_6_8
Changes since 1.143: +6 -6 lines
Diff to previous 1.143 (colored)

kernel: use gettime(9)/getuptime(9) in lieu of time_second(9)/time_uptime(9)

time_second(9) and time_uptime(9) are widely used in the kernel to
quickly get the system UTC or system uptime as a time_t.  However,
time_t is 64-bit everywhere, so it is not generally safe to use them
on 32-bit platforms: you have a split-read problem if your hardware
cannot perform atomic 64-bit reads.

This patch replaces time_second(9) with gettime(9), a safer successor
interface, throughout the kernel.  Similarly, time_uptime(9) is replaced
with getuptime(9).

There is a performance cost on 32-bit platforms in exchange for
eliminating the split-read problem: instead of two register reads you
now have a lockless read loop to pull the values from the timehands.
This is really not *too* bad in the grand scheme of things, but
compared to what we were doing before it is several times slower.

There is no performance cost on 64-bit (__LP64__) platforms.

With input from visa@, dlg@, and tedu@.

Several bugs squashed by visa@.

ok kettenis@

Revision 1.143 / (download) - annotate - [select for diffs], Mon Jan 20 23:21:56 2020 UTC (4 years, 4 months ago) by claudio
Branch: MAIN
CVS Tags: OPENBSD_6_7_BASE, OPENBSD_6_7
Changes since 1.142: +3 -3 lines
Diff to previous 1.142 (colored)

struct vops is not modified during runtime so use const which moves each
into read-only data segment.
OK deraadt@ tedu@

Revision 1.142 / (download) - annotate - [select for diffs], Tue Jan 14 21:38:02 2020 UTC (4 years, 4 months ago) by bluhm
Branch: MAIN
Changes since 1.141: +5 -5 lines
Diff to previous 1.141 (colored)

In nfs_clearcommit() the loops over mnt_vnodelist and v_dirtyblkhd
do not delete anything.  So the safe variant of foreach is not
necessary.
OK mpi@ millert@ tedu@

Revision 1.141 / (download) - annotate - [select for diffs], Fri Jan 10 10:33:35 2020 UTC (4 years, 4 months ago) by bluhm
Branch: MAIN
Changes since 1.140: +2 -2 lines
Diff to previous 1.140 (colored)

Convert the vnode list at the mount point into a tailq.  During
unmount this list is traversed and the dirty vnodes are flushed to
disk.  Forced unmount expects that the list is empty after flushing,
otherwise the kernel panics with "dangling vnode".  As the write
to disk can sleep, new vnodes may be inserted.  If softdep is
enabled, resolving the dependencies creates new dirty vnodes and
inserts them to the list.  To fix the panic, let insmntque() insert
new vnodes at the tail of the list.  Then vflush() will still catch
them while traversing the list in forward direction.
OK tedu@ millert@ visa@

Revision 1.140 / (download) - annotate - [select for diffs], Wed Dec 25 12:31:12 2019 UTC (4 years, 5 months ago) by bluhm
Branch: MAIN
Changes since 1.139: +2 -3 lines
Diff to previous 1.139 (colored)

Use FOREACH macro to iterate over mnt_vnodelist.
OK millert@ visa@ benno@

Revision 1.139 / (download) - annotate - [select for diffs], Fri Nov 30 09:24:57 2018 UTC (5 years, 6 months ago) by claudio
Branch: MAIN
CVS Tags: OPENBSD_6_6_BASE, OPENBSD_6_6, OPENBSD_6_5_BASE, OPENBSD_6_5
Changes since 1.138: +2 -2 lines
Diff to previous 1.138 (colored)

Switch MH_ALIGN to m_align which is the same.
OK bluhm@

Revision 1.138 / (download) - annotate - [select for diffs], Fri Nov 9 14:14:32 2018 UTC (5 years, 6 months ago) by claudio
Branch: MAIN
Changes since 1.137: +4 -4 lines
Diff to previous 1.137 (colored)

M_LEADINGSPACE() and M_TRAILINGSPACE() are just wrappers for
m_leadingspace() and m_trailingspace(). Convert all callers to call
directly the functions and remove the defines.
OK krw@, mpi@

Revision 1.137 / (download) - annotate - [select for diffs], Mon Jul 2 20:56:22 2018 UTC (5 years, 11 months ago) by bluhm
Branch: MAIN
CVS Tags: OPENBSD_6_4_BASE, OPENBSD_6_4
Changes since 1.136: +3 -4 lines
Diff to previous 1.136 (colored)

Use more list macros for v_dirtyblkhd.
OK mpi@

Revision 1.136 / (download) - annotate - [select for diffs], Sat Apr 28 03:13:05 2018 UTC (6 years, 1 month ago) by visa
Branch: MAIN
Changes since 1.135: +2 -3 lines
Diff to previous 1.135 (colored)

Clean up the parameters of VOP_LOCK() and VOP_UNLOCK(). It is always
curproc that does the locking or unlocking, so the proc parameter
is pointless and can be dropped.

OK mpi@, deraadt@

Revision 1.135 / (download) - annotate - [select for diffs], Tue Aug 29 02:51:27 2017 UTC (6 years, 9 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_6_3_BASE, OPENBSD_6_3, OPENBSD_6_2_BASE, OPENBSD_6_2
Changes since 1.134: +1 -7 lines
Diff to previous 1.134 (colored)

Remove old deactivated pledge path code.  A replacement mechanism is
being brewed.
ok beck

Revision 1.134 / (download) - annotate - [select for diffs], Wed Feb 22 11:42:46 2017 UTC (7 years, 3 months ago) by mpi
Branch: MAIN
CVS Tags: OPENBSD_6_1_BASE, OPENBSD_6_1
Changes since 1.133: +2 -1 lines
Diff to previous 1.133 (colored)

Keep local definitions local.

"good work" deraadt@, ok visa@

Revision 1.133 / (download) - annotate - [select for diffs], Thu Sep 15 02:00:18 2016 UTC (7 years, 8 months ago) by dlg
Branch: MAIN
Changes since 1.132: +4 -6 lines
Diff to previous 1.132 (colored)

all pools have their ipl set via pool_setipl, so fold it into pool_init.

the ioff argument to pool_init() is unused and has been for many
years, so this replaces it with an ipl argument. because the ipl
will be set on init we no longer need pool_setipl.

most of these changes have been done with coccinelle using the spatch
below. cocci sucks at formatting code though, so i fixed that by hand.

the manpage and subr_pool.c bits i did myself.

ok tedu@ jmatthew@

@ipl@
expression pp;
expression ipl;
expression s, a, o, f, m, p;
@@
-pool_init(pp, s, a, o, f, m, p);
-pool_setipl(pp, ipl);
+pool_init(pp, s, a, ipl, f, m, p);

Revision 1.132 / (download) - annotate - [select for diffs], Tue Aug 30 07:12:49 2016 UTC (7 years, 9 months ago) by dlg
Branch: MAIN
Changes since 1.131: +3 -1 lines
Diff to previous 1.131 (colored)

pool_setipl for nfs pools

ok natano@

Revision 1.131 / (download) - annotate - [select for diffs], Fri Apr 29 14:40:36 2016 UTC (8 years, 1 month ago) by beck
Branch: MAIN
CVS Tags: OPENBSD_6_0_BASE, OPENBSD_6_0
Changes since 1.130: +8 -1 lines
Diff to previous 1.130 (colored)

Fix some gibbering horrors due to uninitialized struct nameidata's

1) turn NDINITAT into a function and make the macros point to it
with the later goal of getting rid of them.

2) Sweep the kernel for places where people make a struct nameidata manually
on the stack and fill in what they hope are the required fields and count
on prayer and clean living to always get them right. Instead use NDINIT
everywhere. NFS was especially bad for this and there have likely
been things lurking there for a while.

3) Add a couple of strategic KASSERT's to catch future offenders.

ok krw@ sthen@ deraadt@

Revision 1.130 / (download) - annotate - [select for diffs], Sat Mar 19 12:04:16 2016 UTC (8 years, 2 months ago) by natano
Branch: MAIN
Changes since 1.129: +2 -2 lines
Diff to previous 1.129 (colored)

Remove the unused flags argument from VOP_UNLOCK().

torture tested on amd64, i386 and macppc
ok beck mpi stefan
"the change looks right" deraadt

Revision 1.129 / (download) - annotate - [select for diffs], Sat Feb 13 15:45:05 2016 UTC (8 years, 3 months ago) by stefan
Branch: MAIN
CVS Tags: OPENBSD_5_9_BASE, OPENBSD_5_9
Changes since 1.128: +3 -3 lines
Diff to previous 1.128 (colored)

Convert to uiomove. From Martin Natano.

Revision 1.128 / (download) - annotate - [select for diffs], Tue Jun 16 11:09:40 2015 UTC (8 years, 11 months ago) by mpi
Branch: MAIN
CVS Tags: OPENBSD_5_8_BASE, OPENBSD_5_8
Changes since 1.127: +2 -2 lines
Diff to previous 1.127 (colored)

Store a unique ID, an interface index, rather than a pointer to the
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@

Revision 1.127 / (download) - annotate - [select for diffs], Fri Apr 17 04:43:21 2015 UTC (9 years, 1 month ago) by guenther
Branch: MAIN
Changes since 1.126: +26 -3 lines
Diff to previous 1.126 (colored)

Tweaks utimensat/futimens handling to always update ctime, even when both
atime and mtime are UTIME_OMIT (at least for ufs, tmpfs, and ext2fs), and
to correctly handle a timestamp of -1.

ok millert@

Revision 1.126 / (download) - annotate - [select for diffs], Sat Mar 14 03:38:52 2015 UTC (9 years, 2 months ago) by jsg
Branch: MAIN
Changes since 1.125: +1 -2 lines
Diff to previous 1.125 (colored)

Remove some includes include-what-you-use claims don't
have any direct symbols used.  Tested for indirect use by compiling
amd64/i386/sparc64 kernels.

ok tedu@ deraadt@

Revision 1.125 / (download) - annotate - [select for diffs], Tue Feb 10 21:56:10 2015 UTC (9 years, 3 months ago) by miod
Branch: MAIN
CVS Tags: OPENBSD_5_7_BASE, OPENBSD_5_7
Changes since 1.124: +2 -2 lines
Diff to previous 1.124 (colored)

First step towards making uiomove() take a size_t size argument:
- 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@

Revision 1.124 / (download) - annotate - [select for diffs], Sat Jan 17 17:49:27 2015 UTC (9 years, 4 months ago) by deraadt
Branch: MAIN
Changes since 1.123: +2 -2 lines
Diff to previous 1.123 (colored)

use NGROUPS_MAX

Revision 1.123 / (download) - annotate - [select for diffs], Mon Dec 29 05:29:28 2014 UTC (9 years, 5 months ago) by miod
Branch: MAIN
Changes since 1.122: +2 -1 lines
Diff to previous 1.122 (colored)

Explicitely include <uvm/uvm_extern.h> in order to build on variable page size
architectures.

Revision 1.122 / (download) - annotate - [select for diffs], Tue Dec 23 01:55:03 2014 UTC (9 years, 5 months ago) by tedu
Branch: MAIN
Changes since 1.121: +4 -4 lines
Diff to previous 1.121 (colored)

change req pool alloc to null. add prwaitok here and nfs_node_pool which
is also sleeping in all callers, but already used null

Revision 1.121 / (download) - annotate - [select for diffs], Thu Dec 18 21:00:12 2014 UTC (9 years, 5 months ago) by tedu
Branch: MAIN
Changes since 1.120: +2 -2 lines
Diff to previous 1.120 (colored)

convert one hot looking bcopy to memcpy

Revision 1.120 / (download) - annotate - [select for diffs], Thu Dec 18 20:59:21 2014 UTC (9 years, 5 months ago) by tedu
Branch: MAIN
Changes since 1.119: +3 -3 lines
Diff to previous 1.119 (colored)

delete a whole mess of unnecessary caddr_t casts

Revision 1.119 / (download) - annotate - [select for diffs], Tue Nov 18 02:37:31 2014 UTC (9 years, 6 months ago) by tedu
Branch: MAIN
Changes since 1.118: +1 -2 lines
Diff to previous 1.118 (colored)

move arc4random prototype to systm.h. more appropriate for most code
to include that than rdnvar.h. ok deraadt dlg

Revision 1.118 / (download) - annotate - [select for diffs], Fri Nov 14 23:01:44 2014 UTC (9 years, 6 months ago) by tedu
Branch: MAIN
Changes since 1.117: +2 -2 lines
Diff to previous 1.117 (colored)

bzero -> memset

Revision 1.117 / (download) - annotate - [select for diffs], Sun Sep 14 14:17:26 2014 UTC (9 years, 8 months ago) by jsg
Branch: MAIN
Changes since 1.116: +1 -2 lines
Diff to previous 1.116 (colored)

remove uneeded proc.h includes
ok mpi@ kspillner@

Revision 1.116 / (download) - annotate - [select for diffs], Tue Jul 8 17:19:26 2014 UTC (9 years, 10 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_5_6_BASE, OPENBSD_5_6
Changes since 1.115: +1 -3 lines
Diff to previous 1.115 (colored)

decouple struct uvmexp into a new file, so that uvm_extern.h and sysctl.h
don't need to be married.
ok guenther miod beck jsing kettenis

Revision 1.115 / (download) - annotate - [select for diffs], Wed Nov 27 16:02:54 2013 UTC (10 years, 6 months ago) by jsing
Branch: MAIN
CVS Tags: OPENBSD_5_5_BASE, OPENBSD_5_5
Changes since 1.114: +2 -1 lines
Diff to previous 1.114 (colored)

If the v_type is going to change when loading the NFS attribute cache,
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@

Revision 1.114 / (download) - annotate - [select for diffs], Tue Aug 13 05:52:25 2013 UTC (10 years, 9 months ago) by guenther
Branch: MAIN
Changes since 1.113: +4 -6 lines
Diff to previous 1.113 (colored)

Switch time_t, ino_t, clock_t, and struct kevent's ident and data
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@

Revision 1.113 / (download) - annotate - [select for diffs], Mon Jul 4 21:00:10 2011 UTC (12 years, 11 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_5_4_BASE, OPENBSD_5_4, OPENBSD_5_3_BASE, OPENBSD_5_3, OPENBSD_5_2_BASE, OPENBSD_5_2, OPENBSD_5_1_BASE, OPENBSD_5_1, OPENBSD_5_0_BASE, OPENBSD_5_0
Changes since 1.112: +2 -2 lines
Diff to previous 1.112 (colored)

move the specfs code to a place people can see it; ok guenther thib krw

Revision 1.112 / (download) - annotate - [select for diffs], Tue Dec 21 20:14:43 2010 UTC (13 years, 5 months ago) by thib
Branch: MAIN
CVS Tags: OPENBSD_4_9_BASE, OPENBSD_4_9
Changes since 1.111: +6 -6 lines
Diff to previous 1.111 (colored)

Bring back the "End the VOP experiment." diff, naddy's issues where
unrelated, and his alpha is much happier now.

OK deraadt@

Revision 1.111 / (download) - annotate - [select for diffs], Fri Sep 10 16:34:09 2010 UTC (13 years, 8 months ago) by thib
Branch: MAIN
Changes since 1.110: +6 -6 lines
Diff to previous 1.110 (colored)

Backout the VOP diff until the issues naddy was seeing on alpha (gcc3)
have been resolved.

Revision 1.110 / (download) - annotate - [select for diffs], Thu Sep 9 10:37:04 2010 UTC (13 years, 8 months ago) by thib
Branch: MAIN
Changes since 1.109: +2 -2 lines
Diff to previous 1.109 (colored)

Rename lookup/relookup to vfs_lookup/vfs_relookup.

OK oga@, beck@, matthew@

Revision 1.109 / (download) - annotate - [select for diffs], Mon Sep 6 23:44:10 2010 UTC (13 years, 8 months ago) by thib
Branch: MAIN
Changes since 1.108: +6 -6 lines
Diff to previous 1.108 (colored)

End the VOP experiment. Instead of the ridicolusly complicated operation
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@.

Revision 1.108 / (download) - annotate - [select for diffs], Wed May 19 08:31:23 2010 UTC (14 years ago) by thib
Branch: MAIN
CVS Tags: OPENBSD_4_8_BASE, OPENBSD_4_8
Changes since 1.107: +1 -3 lines
Diff to previous 1.107 (colored)

clean up a few things that where left to rot after bob's vfs cache work.
sync a few comments to reality (or remove them), remove the cn_hash member
from struct componentname, spacing.

ok beck@

Revision 1.107 / (download) - annotate - [select for diffs], Mon Oct 19 22:24:18 2009 UTC (14 years, 7 months ago) by jsg
Branch: MAIN
CVS Tags: OPENBSD_4_7_BASE, OPENBSD_4_7
Changes since 1.106: +29 -85 lines
Diff to previous 1.106 (colored)

antsy
no binary change apart from nfsm_reqhead() which is clearly correct.

ok thib@

Revision 1.106 / (download) - annotate - [select for diffs], Wed Sep 2 18:20:54 2009 UTC (14 years, 9 months ago) by thib
Branch: MAIN
Changes since 1.105: +1 -3 lines
Diff to previous 1.105 (colored)

Backout the asyncio/aiod change, as it causes buf's to get hung.
problem noticed by deraadt@

ok beck@

Revision 1.105 / (download) - annotate - [select for diffs], Tue Aug 25 13:41:29 2009 UTC (14 years, 9 months ago) by thib
Branch: MAIN
Changes since 1.104: +0 -10 lines
Diff to previous 1.104 (colored)

move to having requests on a per nfsmount tailq instead of one global one.
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@

Revision 1.104 / (download) - annotate - [select for diffs], Thu Aug 20 15:04:24 2009 UTC (14 years, 9 months ago) by thib
Branch: MAIN
Changes since 1.103: +3 -1 lines
Diff to previous 1.103 (colored)

Rework the way we do async I/O in nfs. Introduce separate buf queues for
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@.

Revision 1.103 / (download) - annotate - [select for diffs], Thu Aug 13 15:18:16 2009 UTC (14 years, 9 months ago) by blambert
Branch: MAIN
Changes since 1.102: +4 -4 lines
Diff to previous 1.102 (colored)

Teach nfsm_fhtom about nfsm_info structs

ok thib@

Revision 1.102 / (download) - annotate - [select for diffs], Thu Aug 13 15:03:19 2009 UTC (14 years, 9 months ago) by blambert
Branch: MAIN
Changes since 1.101: +12 -23 lines
Diff to previous 1.101 (colored)

change version 3 post-operation attribute building function to not
use mbufs directly, but the shiny new nfsm_info struct

ok thib@

Revision 1.101 / (download) - annotate - [select for diffs], Mon Aug 10 10:59:12 2009 UTC (14 years, 9 months ago) by thib
Branch: MAIN
Changes since 1.100: +7 -4 lines
Diff to previous 1.100 (colored)

Use an RB tree instead of a hashtable for fh/node lookups.

Idea from NetBSD.

OK blambert@

Revision 1.100 / (download) - annotate - [select for diffs], Mon Aug 10 09:38:44 2009 UTC (14 years, 9 months ago) by thib
Branch: MAIN
Changes since 1.99: +0 -42 lines
Diff to previous 1.99 (colored)

Remove the v2 writegather code. It did help alot back in the 80s
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@

Revision 1.99 / (download) - annotate - [select for diffs], Tue Aug 4 17:12:39 2009 UTC (14 years, 10 months ago) by thib
Branch: MAIN
Changes since 1.98: +6 -13 lines
Diff to previous 1.98 (colored)

group all of the on-stack variables that are uses by the nfsm_macros
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@.

Revision 1.98 / (download) - annotate - [select for diffs], Mon Jul 20 16:49:40 2009 UTC (14 years, 10 months ago) by thib
Branch: MAIN
Changes since 1.97: +3 -3 lines
Diff to previous 1.97 (colored)

(struct foo *)0 -> NULL, every where I could find it.

OK blambert@

Revision 1.97 / (download) - annotate - [select for diffs], Thu Jul 9 22:29:56 2009 UTC (14 years, 10 months ago) by thib
Branch: MAIN
Changes since 1.96: +1 -1 lines
Diff to previous 1.96 (colored)

Remove the VREF() macro and replaces all instances with a call to verf(),
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.

Revision 1.96 / (download) - annotate - [select for diffs], Sat May 30 17:20:29 2009 UTC (15 years ago) by thib
Branch: MAIN
CVS Tags: OPENBSD_4_6_BASE, OPENBSD_4_6
Changes since 1.95: +1 -7 lines
Diff to previous 1.95 (colored)

Remove unused procnums (NQNFS leftovers) and cleanup.

OK blambert@ sometime ago

Revision 1.95 / (download) - annotate - [select for diffs], Fri May 22 00:19:25 2009 UTC (15 years ago) by thib
Branch: MAIN
Changes since 1.94: +0 -4 lines
Diff to previous 1.94 (colored)

retire the nfs rtt log code, this isnt really all that
usefull, and has been disabled for a long long time.
Cleans house a bit.

OK blambert@

Revision 1.94 / (download) - annotate - [select for diffs], Mon Apr 13 17:51:57 2009 UTC (15 years, 1 month ago) by blambert
Branch: MAIN
Changes since 1.93: +23 -1 lines
Diff to previous 1.93 (colored)

Convert macros to functions to reduce kernel memory usage.

In snaps for a while (way too long, according to deraadt@)

Revision 1.93 / (download) - annotate - [select for diffs], Mon Mar 30 19:58:50 2009 UTC (15 years, 2 months ago) by blambert
Branch: MAIN
Changes since 1.92: +67 -1 lines
Diff to previous 1.92 (colored)

Convert a sizeable macro to a much-leaner function. Saves (IIRC) 5k on i386.

In snaps for a while.

Revision 1.92 / (download) - annotate - [select for diffs], Sat Jan 24 23:30:42 2009 UTC (15 years, 4 months ago) by thib
Branch: MAIN
CVS Tags: OPENBSD_4_5_BASE, OPENBSD_4_5
Changes since 1.91: +3 -3 lines
Diff to previous 1.91 (colored)

Use a timespec instead of a time_t for the clients nfsnode
mtime, gives us better granularity, helps with cache consistency.

Idea lifted from NetBSD.

OK blambert@

Revision 1.91 / (download) - annotate - [select for diffs], Tue Jan 20 18:03:33 2009 UTC (15 years, 4 months ago) by blambert
Branch: MAIN
Changes since 1.90: +5 -8 lines
Diff to previous 1.90 (colored)

Start reworking NFS client mbuf handling by creating an interface which
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

Revision 1.90 / (download) - annotate - [select for diffs], Tue Jan 13 19:44:20 2009 UTC (15 years, 4 months ago) by grange
Branch: MAIN
Changes since 1.89: +3 -2 lines
Diff to previous 1.89 (colored)

Trivial lvalue abuse fixes, no binary changes.
ok millert@ tedu@

Revision 1.89 / (download) - annotate - [select for diffs], Wed Dec 24 02:48:36 2008 UTC (15 years, 5 months ago) by thib
Branch: MAIN
Changes since 1.88: +3 -3 lines
Diff to previous 1.88 (colored)

fix a typo made in last commit, also slightly better wording for
another comment.

Revision 1.88 / (download) - annotate - [select for diffs], Wed Dec 24 02:43:52 2008 UTC (15 years, 5 months ago) by thib
Branch: MAIN
Changes since 1.87: +6 -7 lines
Diff to previous 1.87 (colored)

Replace the TRUE/FALSE defines with 1/0 respectively. This doesn't
hurt readability and it was just plain annoying seeing them defined
in every other .c file.

OK blambert@

Revision 1.87 / (download) - annotate - [select for diffs], Mon Nov 24 20:14:52 2008 UTC (15 years, 6 months ago) by thib
Branch: MAIN
Changes since 1.86: +2 -2 lines
Diff to previous 1.86 (colored)

use the shiny new nitems macro

Revision 1.86 / (download) - annotate - [select for diffs], Mon Aug 25 09:26:17 2008 UTC (15 years, 9 months ago) by pedro
Branch: MAIN
Changes since 1.85: +4 -3 lines
Diff to previous 1.85 (colored)

Correctly invalidate attribute cache entries in case the vnode mode
changes, okay beck@, tedu@ and thib@.

Revision 1.85 / (download) - annotate - [select for diffs], Fri Aug 8 20:44:38 2008 UTC (15 years, 9 months ago) by blambert
Branch: MAIN
Changes since 1.84: +1 -7 lines
Diff to previous 1.84 (colored)

After beck@ changed the way nfsiod's are notified of work, the
nfs_iodwant array became unused. Garbage collect and free up
a few bytes.

ok thib@

Revision 1.84 / (download) - annotate - [select for diffs], Sun Jun 15 04:03:40 2008 UTC (15 years, 11 months ago) by thib
Branch: MAIN
CVS Tags: OPENBSD_4_4_BASE, OPENBSD_4_4
Changes since 1.83: +2 -2 lines
Diff to previous 1.83 (colored)

unroll the NFSMADV() macro and nuke it

ok blambert@

Revision 1.83 / (download) - annotate - [select for diffs], Sat Jun 14 00:26:13 2008 UTC (15 years, 11 months ago) by thib
Branch: MAIN
Changes since 1.82: +3 -3 lines
Diff to previous 1.82 (colored)

use nfsm_padlen() where appropriate;

ok blambert@

Revision 1.82 / (download) - annotate - [select for diffs], Fri Jun 13 22:11:32 2008 UTC (15 years, 11 months ago) by blambert
Branch: MAIN
Changes since 1.81: +2 -4 lines
Diff to previous 1.81 (colored)

Kill one-liner macro which obfuscated mbuf pointer assignment.

Rescue nfsm_reqhead macro name and rename nfsm_reqh.

End of one-liners from nfsm_subs.h.

ok thib@

Revision 1.81 / (download) - annotate - [select for diffs], Fri Jun 13 17:24:13 2008 UTC (15 years, 11 months ago) by thib
Branch: MAIN
Changes since 1.80: +2 -4 lines
Diff to previous 1.80 (colored)

remove rpc_auth_kerb variable, its now unused...

Revision 1.80 / (download) - annotate - [select for diffs], Fri Jun 13 03:49:26 2008 UTC (15 years, 11 months ago) by blambert
Branch: MAIN
Changes since 1.79: +3 -3 lines
Diff to previous 1.79 (colored)

Replace one-line macro which only obfuscated the fact that
the function it was named after took 4 arguments instead of 2.

"get it in; get it in; get it in" thib@

Revision 1.79 / (download) - annotate - [select for diffs], Thu Jun 12 20:24:06 2008 UTC (15 years, 11 months ago) by blambert
Branch: MAIN
Changes since 1.78: +33 -50 lines
Diff to previous 1.78 (colored)

Remove now-vestigial bpos pointer from NFS. For building outgoing
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...)

Revision 1.78 / (download) - annotate - [select for diffs], Wed Jun 11 08:11:33 2008 UTC (15 years, 11 months ago) by thib
Branch: MAIN
Changes since 1.77: +4 -7 lines
Diff to previous 1.77 (colored)

return an XDR'rd xid from nfs_get_xid() and kill the nfs_xid global
variable;

ok & feedback deraadt@

Revision 1.77 / (download) - annotate - [select for diffs], Tue Jun 10 22:59:09 2008 UTC (15 years, 11 months ago) by thib
Branch: MAIN
Changes since 1.76: +13 -1 lines
Diff to previous 1.76 (colored)


o Avoid putting duplicate entries into the name cache,
  add a function to handle cache_enter()'s for us since
  we need to update the appropriate timestamps so we don't
  miss on lookup;
o Do not purge the dvp in nfs_rmdir(), since there's no need;
o cache the new entry created in nfs_mkdir();
o Do caching of the access modes, this drastically reduces the
  amount of over the wire access RPCs we do in the NFSv3 case.

This diff was written by Pedro Martelletto, sometime in 2004.
A lot of people have been running with it at one time or another,
this includes at least markus and matthieu.

OK deraadt@, blambert@

Revision 1.76 / (download) - annotate - [select for diffs], Mon Jun 9 22:49:15 2008 UTC (15 years, 11 months ago) by djm
Branch: MAIN
Changes since 1.75: +3 -3 lines
Diff to previous 1.75 (colored)

nfsm_get_xid() => nfs_get_xid() after thib@ informed me that the
nfsm_* functions are for mbufs

Revision 1.75 / (download) - annotate - [select for diffs], Mon Jun 9 22:47:42 2008 UTC (15 years, 11 months ago) by djm
Branch: MAIN
Changes since 1.74: +19 -8 lines
Diff to previous 1.74 (colored)

Introduce a facility to generate unpredictable 32 bit numbers with
near maximal (2^32) cycle times. These are useful for network
IDs in cases where there are negative consequences to ID prediction
and/or reuse.

Use the idgen32() functions to generate IPv6 IDs and NFS client/server
XIDs.

Pseudorandom permutation code in crypto/idgen.c based on public
domain skip32.c from Greg Rose.

feedback & ok thib@ deraadt@

Revision 1.74 / (download) - annotate - [select for diffs], Tue Apr 22 18:53:34 2008 UTC (16 years, 1 month ago) by thib
Branch: MAIN
Changes since 1.73: +6 -18 lines
Diff to previous 1.73 (colored)

remove the "kerbflag" argument from nfsrv_fhtovp() and nfs_namei()
(the latter only had it to pass it to nfsrv_fhtovp()).

appropriate cleanup also;

ok blambert@

Revision 1.73 / (download) - annotate - [select for diffs], Sat Apr 19 19:38:00 2008 UTC (16 years, 1 month ago) by thib
Branch: MAIN
Changes since 1.72: +2 -2 lines
Diff to previous 1.72 (colored)

in nfsm_reqh(), only allocate an mbuf cluster if the
len exceeds MLEN, not MINCLSIZE; inspired by a similar
commit from damien.

ok damien@, blambert@

Revision 1.72 / (download) - annotate - [select for diffs], Fri Apr 18 06:42:20 2008 UTC (16 years, 1 month ago) by djm
Branch: MAIN
Changes since 1.71: +2 -2 lines
Diff to previous 1.71 (colored)

use arc4random_uniform() for random number requests that are not a
power of two.

use arc4random_bytes() when requesting more than a word of PRNG
output.

ok deraadt@

Revision 1.71 / (download) - annotate - [select for diffs], Wed Apr 16 20:02:46 2008 UTC (16 years, 1 month ago) by damien
Branch: MAIN
Changes since 1.70: +2 -2 lines
Diff to previous 1.70 (colored)

more efficient use of mbufs in nfsm_uiotombuf().
allocate a mbuf cluster only if length is greater than MLEN
instead of MINCLSIZE.

ok blambert@, thib@

Revision 1.70 / (download) - annotate - [select for diffs], Mon Apr 14 13:46:13 2008 UTC (16 years, 1 month ago) by blambert
Branch: MAIN
Changes since 1.69: +86 -142 lines
Diff to previous 1.69 (colored)

Rework NFS mbuf write routines:

nfsm_uiotombuf():
- no meaningful return, function becomes void
- replace frankensteined uiomove/MGET with actual call to uiomove

nfsm_strtmbuf():
- no meaningful return, becomes void
- rename and reorder parameters to be consistent with other functions
- becomes wrapper to nfsm_uiotombuf

nfsm_buftombuf():
- new function; unused but slated for future use
- wrapper to nfsm_uiotombuf

As a bonus, making these functions void removes much unneeded code and
garbage collects `magic' variable t2 which was only used (invisibly)
by the macros from nfsm_subs.h

Preps the way for removing much more NFS goo...

testing by myself, thib@ and merdely@
ok thib@

Revision 1.69 / (download) - annotate - [select for diffs], Sun Jan 6 17:38:23 2008 UTC (16 years, 4 months ago) by blambert
Branch: MAIN
CVS Tags: OPENBSD_4_3_BASE, OPENBSD_4_3
Changes since 1.68: +54 -25 lines
Diff to previous 1.68 (colored)

More NFS-related kernel shrinkage...

When you use a macro ~200 times, it tends to bloat your code, so make a
function out of it.

Shaves ~8.5 kB from my kernel.

ok thib@, "looks good" krw@

In snaps for 1+ week with no negative reports.

Revision 1.68 / (download) - annotate - [select for diffs], Thu Dec 13 18:32:55 2007 UTC (16 years, 5 months ago) by blambert
Branch: MAIN
Changes since 1.67: +77 -1 lines
Diff to previous 1.67 (colored)

convert massive (expanded to 150+ lines) nfsm_v3attr macro to a function

shaves an insane (~8K) amount from an i386 kernel

ok thib@

Revision 1.67 / (download) - annotate - [select for diffs], Wed Nov 28 19:27:43 2007 UTC (16 years, 6 months ago) by thib
Branch: MAIN
Changes since 1.66: +13 -3 lines
Diff to previous 1.66 (colored)

fill the va_blocksize with something a litte saner,
make stat(2) return st_blocksize thats a bit closer
to reality.

From NetBSD;

OK art@, beck@, tedu@

Revision 1.66 / (download) - annotate - [select for diffs], Mon Nov 5 21:18:56 2007 UTC (16 years, 7 months ago) by thib
Branch: MAIN
Changes since 1.65: +2 -8 lines
Diff to previous 1.65 (colored)

deinline nfs_attrtimeo(); and remove some associated
#ifdef goo.

ok krw@, blambert@

Revision 1.65 / (download) - annotate - [select for diffs], Sat Oct 13 17:38:43 2007 UTC (16 years, 7 months ago) by thib
Branch: MAIN
Changes since 1.64: +72 -127 lines
Diff to previous 1.64 (colored)

Remove alot of dead kerberos code (add sane comments too).

Cleanup and partly redo the way we create the RPC header, by having
nfsm_rpchead() do a bit more work. Right now this is pretty RPCAUTH_UNIX
centric, but since it is the only auth method we support right now thats
fine.

Make sure we can never generate a zero xid, thats forbidden by the RFC.

Misc cleanup.

tested by a few.

Revision 1.64 / (download) - annotate - [select for diffs], Mon Oct 8 17:39:52 2007 UTC (16 years, 7 months ago) by deraadt
Branch: MAIN
Changes since 1.63: +5 -8 lines
Diff to previous 1.63 (colored)

shrink nfsrv_v2errmap[] and check table size more carefully to avoid
dependency on ELAST; ok miod thib

Revision 1.63 / (download) - annotate - [select for diffs], Sun Oct 7 16:30:26 2007 UTC (16 years, 7 months ago) by miod
Branch: MAIN
Changes since 1.62: +3 -2 lines
Diff to previous 1.62 (colored)

Make sure nfsrv_v2errmap[] really contains ELAST initialized values.

Revision 1.62 / (download) - annotate - [select for diffs], Thu Sep 20 12:54:31 2007 UTC (16 years, 8 months ago) by thib
Branch: MAIN
Changes since 1.61: +1 -2 lines
Diff to previous 1.61 (colored)

MALLOC/FREE -> malloc/free + M_ZERO.
Uneeded includes and casts...

ok krw@

Revision 1.61 / (download) - annotate - [select for diffs], Thu Apr 19 14:46:44 2007 UTC (17 years, 1 month ago) by thib
Branch: MAIN
CVS Tags: OPENBSD_4_2_BASE, OPENBSD_4_2
Changes since 1.60: +1 -5 lines
Diff to previous 1.60 (colored)

Replace the nfskevq_lock lockmgr lock with rwlock.
Replace nfs_kqinit() wich just calls lockinit with
RWLOCK_INITALIZER. Assorted cleanup.

ok tedu@
"reads good" art@

Revision 1.60 / (download) - annotate - [select for diffs], Fri Apr 13 10:01:35 2007 UTC (17 years, 1 month ago) by thib
Branch: MAIN
Changes since 1.59: +1 -8 lines
Diff to previous 1.59 (colored)

remove some unneeded externs and unused declerations.
There's no need to extern stuff thats declared in the same file.

ok tedu@

Revision 1.59 / (download) - annotate - [select for diffs], Fri Dec 29 13:04:37 2006 UTC (17 years, 5 months ago) by pedro
Branch: MAIN
CVS Tags: OPENBSD_4_1_BASE, OPENBSD_4_1
Changes since 1.58: +3 -3 lines
Diff to previous 1.58 (colored)

Avoid void * arithmetic, okay deraadt@, suggestions from millert@

Revision 1.58 / (download) - annotate - [select for diffs], Wed Nov 1 00:12:35 2006 UTC (17 years, 7 months ago) by thib
Branch: MAIN
Changes since 1.57: +2 -1 lines
Diff to previous 1.57 (colored)

move the declaration of nfsstats from nfs_bio.c to
nfs_subs.c so it gets pulled in for NFSSERVER only
kernels.

ok deraadt@,krw@

Revision 1.57 / (download) - annotate - [select for diffs], Mon May 29 16:49:42 2006 UTC (18 years ago) by avsm
Branch: MAIN
CVS Tags: OPENBSD_4_0_BASE, OPENBSD_4_0
Changes since 1.56: +6 -10 lines
Diff to previous 1.56 (colored)

revert vfs.nfs.privport sysctl, broke a few architectures
requested by deraadt@

Revision 1.56 / (download) - annotate - [select for diffs], Sun May 28 23:29:32 2006 UTC (18 years ago) by avsm
Branch: MAIN
Changes since 1.55: +11 -7 lines
Diff to previous 1.55 (colored)

Add support for NFS mounts to be from non-reserved ports:

- new sysctl vfs.nfs.privport to require NFS mount requests to be on
reserved ports when set to 1 (the default).
- mountd now automatically sets the sysctl depending on the -n flag.
- add mountd_flags to rc.conf to enable the -n flag at boot.
deraadt@ ok

Revision 1.55 / (download) - annotate - [select for diffs], Wed Oct 19 16:50:46 2005 UTC (18 years, 7 months ago) by pedro
Branch: MAIN
CVS Tags: OPENBSD_3_9_BASE, OPENBSD_3_9
Changes since 1.54: +1 -3 lines
Diff to previous 1.54 (colored)

Remove v_vnlock from struct vnode, okay krw@ tedu@

Revision 1.54 / (download) - annotate - [select for diffs], Sat Apr 2 01:00:38 2005 UTC (19 years, 2 months ago) by mickey
Branch: MAIN
CVS Tags: OPENBSD_3_8_BASE, OPENBSD_3_8
Changes since 1.53: +6 -1 lines
Diff to previous 1.53 (colored)

use pool for struct nfsreq; tedu@ pedro@ ok and testing by mark patruck <mark@2ls4agd.net> on several archs

Revision 1.53 / (download) - annotate - [select for diffs], Thu Mar 31 21:47:49 2005 UTC (19 years, 2 months ago) by deraadt
Branch: MAIN
Changes since 1.52: +3 -2 lines
Diff to previous 1.52 (colored)

re-commit marius commit:
> fix preposterous time warnings in the nfs client; caused by false hits
> in the attribute cache
> based on original fix by pedro@, ok pedro@, tedu@; testing kettenis@
was backed out because too close to release
put back in now, since tree is unlocked.  unfortunately it appears that even
after MANY MAILS ON THIS SUBJECT, NOONE HAS DONE THIS.  WTF?  Noone wants
to FINISH jobs anymore?

Revision 1.52 / (download) - annotate - [select for diffs], Tue Feb 1 15:00:04 2005 UTC (19 years, 4 months ago) by pvalchev
Branch: MAIN
CVS Tags: OPENBSD_3_7_BASE, OPENBSD_3_7
Changes since 1.51: +1 -2 lines
Diff to previous 1.51 (colored)

backout nfs_subs.c rev1.51 nfs_vfsops.c rev1.54:
fix preposterous time warnings in the nfs client; caused by false hits
in the attribute cache

too close to release, save for immediately after unlock

Revision 1.51 / (download) - annotate - [select for diffs], Mon Jan 24 00:14:40 2005 UTC (19 years, 4 months ago) by marius
Branch: MAIN
Changes since 1.50: +3 -2 lines
Diff to previous 1.50 (colored)

fix preposterous time warnings in the nfs client; caused by false hits
in the attribute cache

based on original fix by pedro@, ok pedro@, tedu@; testing kettenis@

Revision 1.50 / (download) - annotate - [select for diffs], Tue Aug 3 17:11:48 2004 UTC (19 years, 10 months ago) by marius
Branch: MAIN
CVS Tags: OPENBSD_3_6_BASE, OPENBSD_3_6
Changes since 1.49: +167 -1 lines
Diff to previous 1.49 (colored)

NFS commit coalescion: instead of sending a commit for each block, coalesce
these into larger ranges wherever possible.

this should speed up NFS writes quite a bit.

ok art@ millert@ pedro@ tedu@

Revision 1.49 / (download) - annotate - [select for diffs], Tue Aug 3 06:58:40 2004 UTC (19 years, 10 months ago) by miod
Branch: MAIN
Changes since 1.48: +3 -3 lines
Diff to previous 1.48 (colored)

When accessing device nodes over nfs, do not trim major and minor numbers
to 8 bits only; found the hard way by henning@.

Ok deraadt@ marius@ millert@

Revision 1.48 / (download) - annotate - [select for diffs], Wed Jul 21 17:30:55 2004 UTC (19 years, 10 months ago) by marius
Branch: MAIN
Changes since 1.47: +5 -1 lines
Diff to previous 1.47 (colored)

kqueue support for NFS, adapted from netbsd.

ok art@ pedro@, "get it in" deraadt@

Revision 1.47 / (download) - annotate - [select for diffs], Fri Jul 16 15:01:51 2004 UTC (19 years, 10 months ago) by henning
Branch: MAIN
Changes since 1.46: +1 -19 lines
Diff to previous 1.46 (colored)

kill netiso stuff here as well, millert ok

Revision 1.46 / (download) - annotate - [select for diffs], Tue Jul 13 21:04:29 2004 UTC (19 years, 10 months ago) by millert
Branch: MAIN
Changes since 1.45: +6 -6 lines
Diff to previous 1.45 (colored)

Change mode_t and nlink_t from 16bit to 32bit.  This allows us to
use mode_t in syscalls.master and to use mode_t in more places in
the kernel.  It also makes lint much more useful on kernel code.

I've also added a placeholder for st_birthtime to make a UFS2 import
easier at some future date.

Requested by and OK deraadt@

Revision 1.45 / (download) - annotate - [select for diffs], Mon Jun 21 23:50:38 2004 UTC (19 years, 11 months ago) by tholo
Branch: MAIN
Changes since 1.44: +4 -4 lines
Diff to previous 1.44 (colored)

First step towards more sane time handling in the kernel -- this changes
things such that code that only need a second-resolution uptime or wall
time, and used to get that from time.tv_secs or mono_time.tv_secs now get
this from separate time_t globals time_second and time_uptime.

ok art@ niklas@ nordin@

Revision 1.28.2.9 / (download) - annotate - [select for diffs], Sat Jun 5 23:13:07 2004 UTC (20 years ago) by niklas
Branch: SMP
Changes since 1.28.2.8: +4 -3 lines
Diff to previous 1.28.2.8 (colored) to branchpoint 1.28 (colored) next main 1.29 (colored)

Merge with the trunk

Revision 1.44 / (download) - annotate - [select for diffs], Fri May 14 04:00:34 2004 UTC (20 years ago) by tedu
Branch: MAIN
CVS Tags: SMP_SYNC_B, SMP_SYNC_A
Changes since 1.43: +4 -3 lines
Diff to previous 1.43 (colored)

use pool for namei pathbuf.  testing ok millert@ tdeval@

Revision 1.28.2.8 / (download) - annotate - [select for diffs], Sat Jun 7 11:07:44 2003 UTC (21 years ago) by ho
Branch: SMP
Changes since 1.28.2.7: +2 -6 lines
Diff to previous 1.28.2.7 (colored) to branchpoint 1.28 (colored)

Sync SMP branch to -current

Revision 1.43 / (download) - annotate - [select for diffs], Mon Jun 2 23:28:19 2003 UTC (21 years ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_3_5_BASE, OPENBSD_3_5, OPENBSD_3_4_BASE, OPENBSD_3_4
Changes since 1.42: +2 -6 lines
Diff to previous 1.42 (colored)

Remove the advertising clause in the UCB license which Berkeley
rescinded 22 July 1999.  Proofed by myself and Theo.

Revision 1.37.2.3 / (download) - annotate - [select for diffs], Mon Nov 4 18:02:32 2002 UTC (21 years, 7 months ago) by art
Branch: UBC
Changes since 1.37.2.2: +28 -4 lines
Diff to previous 1.37.2.2 (colored) to branchpoint 1.37 (colored) next main 1.38 (colored)

Huge sync to NetBSD plus lots of bugfixes.
 - uvm is as in netbsd-current minus uvm_map forward merge.
 - various locking bugfixes in nfs.
 - make sure that all specops and fifoops are correct in all vnodeop vectors.
 - make the filesystem code more like filsystem code and less like vm code.

Revision 1.37.2.2 / (download) - annotate - [select for diffs], Tue Jun 11 03:32:04 2002 UTC (21 years, 11 months ago) by art
Branch: UBC
Changes since 1.37.2.1: +5 -5 lines
Diff to previous 1.37.2.1 (colored) to branchpoint 1.37 (colored)

Sync UBC branch to -current

Revision 1.28.2.7 / (download) - annotate - [select for diffs], Thu Mar 28 15:02:48 2002 UTC (22 years, 2 months ago) by niklas
Branch: SMP
Changes since 1.28.2.6: +3 -3 lines
Diff to previous 1.28.2.6 (colored) to branchpoint 1.28 (colored)

Merge in -current from roughly a week ago

Revision 1.42 / (download) - annotate - [select for diffs], Thu Mar 14 01:27:13 2002 UTC (22 years, 2 months ago) by millert
Branch: MAIN
CVS Tags: UBC_SYNC_B, UBC_SYNC_A, OPENBSD_3_3_BASE, OPENBSD_3_3, OPENBSD_3_2_BASE, OPENBSD_3_2, OPENBSD_3_1_BASE, OPENBSD_3_1
Changes since 1.41: +4 -4 lines
Diff to previous 1.41 (colored)

First round of __P removal in sys

Revision 1.28.2.6 / (download) - annotate - [select for diffs], Wed Mar 6 02:17:12 2002 UTC (22 years, 3 months ago) by niklas
Branch: SMP
Changes since 1.28.2.5: +82 -303 lines
Diff to previous 1.28.2.5 (colored) to branchpoint 1.28 (colored)

Merge in trunk

Revision 1.41 / (download) - annotate - [select for diffs], Sun Feb 10 22:02:05 2002 UTC (22 years, 3 months ago) by nate
Branch: MAIN
Changes since 1.40: +2 -2 lines
Diff to previous 1.40 (colored)

theo doesn't like this code

Revision 1.37.2.1 / (download) - annotate - [select for diffs], Thu Jan 31 22:55:47 2002 UTC (22 years, 4 months ago) by niklas
Branch: UBC
Changes since 1.37: +62 -62 lines
Diff to previous 1.37 (colored)

Merge in -current, builds on i386, otherwise untested

Revision 1.40 / (download) - annotate - [select for diffs], Wed Jan 16 21:51:16 2002 UTC (22 years, 4 months ago) by ericj
Branch: MAIN
Changes since 1.39: +67 -67 lines
Diff to previous 1.39 (colored)


use queue.h macro's
remove register

Revision 1.39 / (download) - annotate - [select for diffs], Fri Jan 11 01:20:56 2002 UTC (22 years, 4 months ago) by nate
Branch: MAIN
Changes since 1.38: +2 -2 lines
Diff to previous 1.38 (colored)

Add a new sysctl that removes the requirement for reserved ports to be
used by the nfs server.

Revision 1.38 / (download) - annotate - [select for diffs], Wed Dec 19 08:58:06 2001 UTC (22 years, 5 months ago) by art
Branch: MAIN
Changes since 1.37: +23 -244 lines
Diff to previous 1.37 (colored)

UBC was a disaster. It worked very good when it worked, but on some
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.

Revision 1.37 / (download) - annotate - [select for diffs], Mon Dec 10 02:19:34 2001 UTC (22 years, 5 months ago) by art
Branch: MAIN
CVS Tags: UBC_BASE
Branch point for: UBC
Changes since 1.36: +4 -4 lines
Diff to previous 1.36 (colored)

Merge in struct uvm_vnode into struct vnode.

Revision 1.28.2.5 / (download) - annotate - [select for diffs], Wed Dec 5 01:02:40 2001 UTC (22 years, 6 months ago) by niklas
Branch: SMP
Changes since 1.28.2.4: +243 -22 lines
Diff to previous 1.28.2.4 (colored) to branchpoint 1.28 (colored)

Merge in -current

Revision 1.36 / (download) - annotate - [select for diffs], Tue Nov 27 05:27:12 2001 UTC (22 years, 6 months ago) by art
Branch: MAIN
Changes since 1.35: +244 -23 lines
Diff to previous 1.35 (colored)

Merge in the unified buffer cache code as found in NetBSD 2001/03/10. The
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.

Revision 1.28.2.4 / (download) - annotate - [select for diffs], Tue Nov 13 22:59:59 2001 UTC (22 years, 6 months ago) by niklas
Branch: SMP
Changes since 1.28.2.3: +2 -4 lines
Diff to previous 1.28.2.3 (colored) to branchpoint 1.28 (colored)

merge in -current

Revision 1.35 / (download) - annotate - [select for diffs], Tue Nov 6 19:53:21 2001 UTC (22 years, 7 months ago) by miod
Branch: MAIN
Changes since 1.34: +2 -4 lines
Diff to previous 1.34 (colored)

Replace inclusion of <vm/foo.h> with the correct <uvm/bar.h> when necessary.
(Look ma, I might have broken the tree)

Revision 1.28.2.3 / (download) - annotate - [select for diffs], Wed Oct 31 03:30:30 2001 UTC (22 years, 7 months ago) by nate
Branch: SMP
Changes since 1.28.2.2: +1 -23 lines
Diff to previous 1.28.2.2 (colored) to branchpoint 1.28 (colored)

Sync the SMP branch to something just after 3.0

Revision 1.34 / (download) - annotate - [select for diffs], Sun Aug 19 18:14:54 2001 UTC (22 years, 9 months ago) by art
Branch: MAIN
CVS Tags: OPENBSD_3_0_BASE, OPENBSD_3_0
Changes since 1.33: +1 -23 lines
Diff to previous 1.33 (colored)

Stop whining.

Revision 1.33 / (download) - annotate - [select for diffs], Sun Aug 19 17:45:07 2001 UTC (22 years, 9 months ago) by jason
Branch: MAIN
Changes since 1.32: +2 -2 lines
Diff to previous 1.32 (colored)

add __sparc64__ to list of arch's not checked for bloated structures (also
correct alpha -> __alpha__)

Revision 1.28.2.2 / (download) - annotate - [select for diffs], Wed Jul 4 10:55:50 2001 UTC (22 years, 11 months ago) by niklas
Branch: SMP
Changes since 1.28.2.1: +7 -141 lines
Diff to previous 1.28.2.1 (colored) to branchpoint 1.28 (colored)

Merge in -current from two days ago in the SMP branch.
As usual with merges, they do not indicate progress, so do not hold
your breath for working SMP, and do not mail me and ask about the
state of it.  It has not changed.  There is work ongoing, but very, very
slowly.  The commit is done in parts as to not lock up the tree in too
big chunks at a time.

Revision 1.32 / (download) - annotate - [select for diffs], Wed Jun 27 04:58:46 2001 UTC (22 years, 11 months ago) by art
Branch: MAIN
Changes since 1.31: +1 -9 lines
Diff to previous 1.31 (colored)

Remove old vm.

Revision 1.31 / (download) - annotate - [select for diffs], Mon Jun 25 03:28:10 2001 UTC (22 years, 11 months ago) by csapuntz
Branch: MAIN
Changes since 1.30: +7 -51 lines
Diff to previous 1.30 (colored)

Remove NQNFS

Revision 1.30 / (download) - annotate - [select for diffs], Mon Jun 25 02:15:47 2001 UTC (22 years, 11 months ago) by csapuntz
Branch: MAIN
Changes since 1.29: +1 -83 lines
Diff to previous 1.29 (colored)


Get rid of old directory caching scheme which caused persistent duplicates.

Still not correct for NFSv3 but that's hard.

Revision 1.28.2.1 / (download) - annotate - [select for diffs], Mon May 14 22:44:57 2001 UTC (23 years ago) by niklas
Branch: SMP
Changes since 1.28: +6 -2 lines
Diff to previous 1.28 (colored)

merge in approximately 2.9 into SMP branch

Revision 1.29 / (download) - annotate - [select for diffs], Mon Jun 26 22:48:15 2000 UTC (23 years, 11 months ago) by art
Branch: MAIN
CVS Tags: OPENBSD_2_9_BASE, OPENBSD_2_9, OPENBSD_2_8_BASE, OPENBSD_2_8
Changes since 1.28: +6 -2 lines
Diff to previous 1.28 (colored)

Convert nfs_timer to new timeouts.

Revision 1.28 / (download) - annotate - [select for diffs], Mon Feb 7 04:57:17 2000 UTC (24 years, 4 months ago) by assar
Branch: MAIN
CVS Tags: SMP_BASE, OPENBSD_2_7_BASE, OPENBSD_2_7
Branch point for: SMP
Changes since 1.27: +6 -3 lines
Diff to previous 1.27 (colored)

update to use new checkexp vfs operation

Revision 1.27 / (download) - annotate - [select for diffs], Wed Apr 28 09:28:17 1999 UTC (25 years, 1 month ago) by art
Branch: MAIN
CVS Tags: kame_19991208, OPENBSD_2_6_BASE, OPENBSD_2_6
Changes since 1.26: +2 -2 lines
Diff to previous 1.26 (colored)

zap the newhashinit hack.
Add an extra flag to hashinit telling if it should wait in malloc.
update all calls to hashinit.

Revision 1.26 / (download) - annotate - [select for diffs], Fri Feb 26 03:16:25 1999 UTC (25 years, 3 months ago) by art
Branch: MAIN
CVS Tags: OPENBSD_2_5_BASE, OPENBSD_2_5
Changes since 1.25: +9 -1 lines
Diff to previous 1.25 (colored)

compatibility with uvm vnode pager

Revision 1.25 / (download) - annotate - [select for diffs], Sat Feb 6 23:07:45 1999 UTC (25 years, 4 months ago) by millert
Branch: MAIN
Changes since 1.24: +4 -4 lines
Diff to previous 1.24 (colored)

Use bitwise operations to extract high and low words from the quad
in txdr_hyper.  This should be more portable than casting to an array
of ints and pulling out the two 32-bit words (this produced incorrect
results on alpha for the high word for filesystems < 4gig).  As a side
effect, txdr_hyper now takes a u_quad_t as its first arg, not u_quad_t *.

Revision 1.24 / (download) - annotate - [select for diffs], Sat Jan 16 13:28:25 1999 UTC (25 years, 4 months ago) by niklas
Branch: MAIN
Changes since 1.23: +4 -3 lines
Diff to previous 1.23 (colored)

Do not lose st_blocks on NFSv2 mounts when files>2GB

Revision 1.23 / (download) - annotate - [select for diffs], Wed Aug 19 22:26:55 1998 UTC (25 years, 9 months ago) by csapuntz
Branch: MAIN
CVS Tags: OPENBSD_2_4_BASE, OPENBSD_2_4
Changes since 1.22: +3 -3 lines
Diff to previous 1.22 (colored)



Change fxdr_hyper to return a u_quad_t. This minimizes the evil clobbering
of lvalues that ANSI abhors.

And it fixes df on NFS version 3 mounts on Sparcs.

Revision 1.22 / (download) - annotate - [select for diffs], Thu Nov 6 05:59:03 1997 UTC (26 years, 7 months ago) by csapuntz
Branch: MAIN
CVS Tags: OPENBSD_2_3_BASE, OPENBSD_2_3
Changes since 1.21: +9 -15 lines
Diff to previous 1.21 (colored)

Updates for VFS Lite 2 + soft update.

Revision 1.21 / (download) - annotate - [select for diffs], Mon Oct 6 20:20:49 1997 UTC (26 years, 8 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_2_BASE, OPENBSD_2_2
Changes since 1.20: +14 -8 lines
Diff to previous 1.20 (colored)

back out vfs lite2 till after 2.2

Revision 1.20 / (download) - annotate - [select for diffs], Mon Oct 6 15:23:43 1997 UTC (26 years, 8 months ago) by csapuntz
Branch: MAIN
Changes since 1.19: +9 -15 lines
Diff to previous 1.19 (colored)

VFS Lite2 Changes

Revision 1.19 / (download) - annotate - [select for diffs], Mon Apr 28 00:40:14 1997 UTC (27 years, 1 month ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_1_BASE, OPENBSD_2_1
Changes since 1.18: +8 -12 lines
Diff to previous 1.18 (colored)

indent

Revision 1.18 / (download) - annotate - [select for diffs], Mon Apr 28 00:37:06 1997 UTC (27 years, 1 month ago) by angelos
Branch: MAIN
Changes since 1.17: +11 -24 lines
Diff to previous 1.17 (colored)

Previous patch didn't make much sense. We now set the initial NFS xid
(for requests) to some random value, and then increase that by a small
(1-255) random value for each requests.

Revision 1.17 / (download) - annotate - [select for diffs], Sun Apr 27 23:55:49 1997 UTC (27 years, 1 month ago) by angelos
Branch: MAIN
Changes since 1.16: +30 -16 lines
Diff to previous 1.16 (colored)

Random/unique NFS xids.

Revision 1.16 / (download) - annotate - [select for diffs], Fri Apr 25 09:30:14 1997 UTC (27 years, 1 month ago) by deraadt
Branch: MAIN
Changes since 1.15: +12 -1 lines
Diff to previous 1.15 (colored)

require reserved ports. avoid ftp bounce.

Revision 1.15 / (download) - annotate - [select for diffs], Wed Dec 18 18:30:58 1996 UTC (27 years, 5 months ago) by niklas
Branch: MAIN
Changes since 1.14: +12 -3 lines
Diff to previous 1.14 (colored)

Conditionalize GCC and ANSI/ISO C dependencies

Revision 1.14 / (download) - annotate - [select for diffs], Tue Dec 17 03:46:38 1996 UTC (27 years, 5 months ago) by dm
Branch: MAIN
Changes since 1.13: +27 -2 lines
Diff to previous 1.13 (colored)

NFS attribute cache timeout mount param

Revision 1.13 / (download) - annotate - [select for diffs], Tue Oct 15 11:34:15 1996 UTC (27 years, 7 months ago) by deraadt
Branch: MAIN
Changes since 1.12: +3 -3 lines
Diff to previous 1.12 (colored)

nqnfs code is for client+server; spotted by niklas

Revision 1.12 / (download) - annotate - [select for diffs], Wed Sep 25 11:57:25 1996 UTC (27 years, 8 months ago) by niklas
Branch: MAIN
CVS Tags: OPENBSD_2_0_BASE, OPENBSD_2_0
Changes since 1.11: +1 -3 lines
Diff to previous 1.11 (colored)

Drop unused variable

Revision 1.11 / (download) - annotate - [select for diffs], Sat Sep 21 11:06:19 1996 UTC (27 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.10: +14 -9 lines
Diff to previous 1.10 (colored)

fix NFSSERVER w/o NFSCLIENT; netbsd pr#1780, cgd@netbsd (yes, a 10month
old PR and the fix is mostly unchanged).

Revision 1.10 / (download) - annotate - [select for diffs], Sat Jul 27 11:09:39 1996 UTC (27 years, 10 months ago) by deraadt
Branch: MAIN
Changes since 1.9: +12 -13 lines
Diff to previous 1.9 (colored)

fvdl; We're only handling uio with iovcnt == 1, so don't ever attempt to
increment uio_iov, this will get us into nasty trouble. (Thanks to
Matthias Drochner for tracking this down).

Revision 1.9 / (download) - annotate - [select for diffs], Tue Jul 23 21:32:31 1996 UTC (27 years, 10 months ago) by deraadt
Branch: MAIN
Changes since 1.8: +18 -1 lines
Diff to previous 1.8 (colored)

sync

Revision 1.8 / (download) - annotate - [select for diffs], Tue May 28 13:44:08 1996 UTC (28 years ago) by deraadt
Branch: MAIN
Changes since 1.7: +1 -1 lines
Diff to previous 1.7 (colored)

sync

Revision 1.7 / (download) - annotate - [select for diffs], Sun Apr 21 22:30:30 1996 UTC (28 years, 1 month ago) by deraadt
Branch: MAIN
Changes since 1.6: +17 -12 lines
Diff to previous 1.6 (colored)

partial sync with netbsd 960418, more to come

Revision 1.6 / (download) - annotate - [select for diffs], Wed Apr 17 04:50:31 1996 UTC (28 years, 1 month ago) by mickey
Branch: MAIN
Changes since 1.5: +13 -12 lines
Diff to previous 1.5 (colored)

Minor cleanups. Checked against Lite2.
(NetBSD's was really just a Lite2's, but w/ 64bit support)

Revision 1.5 / (download) - annotate - [select for diffs], Sun Mar 31 13:15:53 1996 UTC (28 years, 2 months ago) by mickey
Branch: MAIN
Changes since 1.4: +916 -154 lines
Diff to previous 1.4 (colored)

From NetBSD: NFSv3 import (tomorrow's Net's kernel)
Open's patches kept in. i'll possibly take a look at Lite2 soon,
is there smth usefull ?..

Revision 1.4 / (download) - annotate - [select for diffs], Thu Feb 29 09:24:56 1996 UTC (28 years, 3 months ago) by niklas
Branch: MAIN
Changes since 1.3: +41 -22 lines
Diff to previous 1.3 (colored)

From NetBSD: merge with 960217 (still NFSv2)

Revision 1.3 / (download) - annotate - [select for diffs], Mon Jan 8 07:36:26 1996 UTC (28 years, 5 months ago) by dm
Branch: MAIN
Changes since 1.2: +1 -1 lines
Diff to previous 1.2 (colored)

graichen@freebsd.org: fixed -type:=direct mounts in amd

Revision 1.2 / (download) - annotate - [select for diffs], Thu Dec 21 14:42:24 1995 UTC (28 years, 5 months ago) by deraadt
Branch: MAIN
Changes since 1.1: +29 -29 lines
Diff to previous 1.1 (colored)

from cgd; handle 64-bit pointers and longs

Revision 1.1.1.1 / (download) - annotate - [select for diffs] (vendor branch), Wed Oct 18 08:53:22 1995 UTC (28 years, 7 months ago) by deraadt
CVS Tags: netbsd_1_1
Changes since 1.1: +0 -0 lines
Diff to previous 1.1 (colored)

initial import of NetBSD tree

Revision 1.1 / (download) - annotate - [select for diffs], Wed Oct 18 08:53:22 1995 UTC (28 years, 7 months ago) by deraadt
Branch: MAIN

Initial revision

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.