| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
| |
allocation and deallocation. This flag's principal use is shortly after
allocation. For such cases, clearing the flag is pointless. The only
unusual use of PG_ZERO is in vfs_bio_clrbuf(). However, allocbuf() never
requests a prezeroed page. So, vfs_bio_clrbuf() never sees a prezeroed
page.
Reviewed by: tegge@
Notes:
svn path=/head/; revision=128992
|
|
|
|
|
|
|
|
|
|
|
|
| |
This avoids presenting invalid data to the client's applications
when the file is modified, and then extended within the window of
the resolution of the modifcation timestamp.
Reviewed By: iedowse
PR: kern/64091
Notes:
svn path=/head/; revision=128263
|
|
|
|
| |
Notes:
svn path=/head/; revision=128126
|
|
|
|
|
|
|
|
|
|
|
|
| |
This includes a modified form of some code from Thomas Moestl (tmm@)
to properly clean up the UMA zone and the "nfsnodehashtbl" hash
table.
Reviewed By: iedowse
PR: 16299
Notes:
svn path=/head/; revision=128111
|
|
|
|
|
|
|
|
|
|
| |
license, per letter dated July 22, 1999 and email from Peter Wemm,
Alan Cox and Robert Watson.
Approved by: core, peter, alc, rwatson
Notes:
svn path=/head/; revision=127977
|
|
|
|
| |
Notes:
svn path=/head/; revision=127857
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
NFSv3. It's likely that modifying the attributes will affect the
file's accessibility. This version of the patch is one suggested
by Ian Dowse after reviewing my original attempt in the PR
Reviewed By: iedowse
PR: kern/44336
MFC after: 3 days
Notes:
svn path=/head/; revision=127797
|
|
|
|
|
|
|
|
|
|
|
|
| |
are supposed to continue firing as long as there is work to do, not
stop after the first invocation.
This is damage control after a patch that has been committed prematurely.
Tested by: kris
Notes:
svn path=/head/; revision=127515
|
|
|
|
|
|
|
|
| |
Submitted by: kan
Approved by: alfred
Notes:
svn path=/head/; revision=127421
|
|
|
|
|
|
|
|
|
| |
nfs sockets.
Requested by: ru
Notes:
svn path=/head/; revision=127144
|
|
|
|
|
|
|
|
|
| |
mounts which will be closed by netapp, solaris, etc. if left idle too long.
Obtained from: NetBSD
Notes:
svn path=/head/; revision=127137
|
|
|
|
|
|
|
|
|
| |
clock precision on i386. This is a NOP change on i386. But this stops
the mount_nfs units from suddenly changing to units of 1/20 of a second
(vs the normal 1/10 of a second) if HZ is increased.
Notes:
svn path=/head/; revision=126962
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
path to an absolute path without a host name. Previously, there was a
nasty POLA violation where a system would PXE boot until you added the
BOOTP option and then it would panic instead.
Reviewed by: tegge, Dirk-Willem van Gulik <dirkx at webweaving.org>
(a previous version)
Submitted by: tegge (getip function)
Notes:
svn path=/head/; revision=126888
|
|
|
|
|
|
|
| |
and s/BUF_WRITE()/bwrite()/ since it now does the same as bwrite().
Notes:
svn path=/head/; revision=126853
|
|
|
|
|
|
|
| |
Don't call addaliasu() on VBLK nodes.
Notes:
svn path=/head/; revision=126851
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
functions in kern_socket.c.
Rename the "canwait" field to "mflags" and pass M_WAITOK and M_NOWAIT
in from the caller context rather than "1" or "0".
Correct mflags pass into mac_init_socket() from previous commit to not
include M_ZERO.
Submitted by: sam
Notes:
svn path=/head/; revision=126425
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
remove unused pid field of file context struct
map nfs4 error codes to errnos
eliminate redundant code from nfs4_request
use zero stateid on setattr that doesn't set file size
use same clientid on all mounts until reboot
invalidate dirty bufs in nfs4_close, to play it safe
open file for writing if truncating and it's not already open
Approved by: alfred
Notes:
svn path=/head/; revision=126330
|
|
|
|
|
|
|
|
|
|
| |
free it again.
Reported by: "Ted Unangst" <tedu@coverity.com>
Approved by: rwatson (mentor)
Notes:
svn path=/head/; revision=126105
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- struct plimit includes a mutex to protect a reference count. The plimit
structure is treated similarly to struct ucred in that is is always copy
on write, so having a reference to a structure is sufficient to read from
it without needing a further lock.
- The proc lock protects the p_limit pointer and must be held while reading
limits from a process to keep the limit structure from changing out from
under you while reading from it.
- Various global limits that are ints are not protected by a lock since
int writes are atomic on all the archs we support and thus a lock
wouldn't buy us anything.
- All accesses to individual resource limits from a process are abstracted
behind a simple lim_rlimit(), lim_max(), and lim_cur() API that return
either an rlimit, or the current or max individual limit of the specified
resource from a process.
- dosetrlimit() was renamed to kern_setrlimit() to match existing style of
other similar syscall helper functions.
- The alpha OSF/1 compat layer no longer calls getrlimit() and setrlimit()
(it didn't used the stackgap when it should have) but uses lim_rlimit()
and kern_setrlimit() instead.
- The svr4 compat no longer uses the stackgap for resource limits calls,
but uses lim_rlimit() and kern_setrlimit() instead.
- The ibcs2 compat no longer uses the stackgap for resource limits. It
also no longer uses the stackgap for accessing sysctl's for the
ibcs2_sysconf() syscall but uses kernel_sysctl() instead. As a result,
ibcs2_sysconf() no longer needs Giant.
- The p_rlimit macro no longer exists.
Submitted by: mtm (mostly, I only did a few cleanups and catchups)
Tested on: i386
Compiled on: alpha, amd64
Notes:
svn path=/head/; revision=125454
|
|
|
|
|
|
|
|
|
|
| |
Solaris and HP-UX. This increases read performance for large files across NFS.
PR: 62024 & 26324
Submitted by: Bjoern Groenvall <bg@sics.se>
Notes:
svn path=/head/; revision=125263
|
|
|
|
|
|
|
|
|
|
|
| |
and the nfs3 client. Also fix some bugs that happen to be causing crashes
in both v3 and v4 introduced by the v4 import.
Submitted by: Jim Rees <rees@umich.edu>
Approved by: re
Notes:
svn path=/head/; revision=122953
|
|
|
|
|
|
|
| |
for fstat(1).
Notes:
svn path=/head/; revision=122736
|
|
|
|
| |
Notes:
svn path=/head/; revision=122719
|
|
|
|
|
|
|
| |
Submitted by: Jim Rees <rees@umich.edu>
Notes:
svn path=/head/; revision=122698
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
vfs_mount_alloc/vfs_mount_destroy functions and take care to completely
destroy the mount point along with its locks. Mount struct has grown in
coplexity recently and depending on each failure path to destroy it
completely isn't working anymore.
2. Eliminate largely identical vfs_mount and vfs_unmount question by
moving the code to handle both cases into a newly introduced vfs_domount
function.
3. Simplify nfs_mount_diskless to always expect an allocated mount
struct and never attempt an allocation/destruction itself. The
vfs_allocroot allocation was there to support 'magic' swap space
configuration for diskless clients that was already removed by PHK some
time ago.
4. Include a vfs_buildopts cleanups by Peter Edwards to validate the
sanity of nmount parameters passed from userland.
Submitted by: (4) Peter Edwards <peter.edwards@openet-telecom.com>
Reviewed by: rwatson
Notes:
svn path=/head/; revision=122523
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The reason this was done was to avoid a race to the root when an
NFS server went down. However a semi-recent change to the way that
the kernel's lookup() routine traverses mount points prevents this.
Rev 1.39 of vfs_lookup.c changed the ordering of locks such that we
aquire a shared lock on the mount point being accessed and then drop
the directory vnode lock before requesting the target lock.
With that in place we no longer need shared locks for NFS to prevent
race to the root lockups.
Notes:
svn path=/head/; revision=122450
|
|
|
|
|
|
|
|
|
|
| |
preparatory for MPSAFE network commits and ongoing socket
locking work.
Supported by: FreeBSD Foundation
Notes:
svn path=/head/; revision=122261
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Introduce two new macros MNT_ILOCK(mp)/MNT_IUNLOCK(mp) to
operate on this mutex transparently.
Eventually new mutex will be protecting more fields in
struct mount, not only vnode list.
Discussed with: jeff
Notes:
svn path=/head/; revision=122091
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
wasn't curthread, i.e. when we receive a thread pointer to use
as a function argument. Use VOP_UNLOCK/vrele in these cases.
The only case there td != curthread known at the moment is
boot() calling sync with thread0 pointer.
This fixes the panic on shutdown people have reported.
Notes:
svn path=/head/; revision=121874
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
if_xname, if_dname, and if_dunit. if_xname is the name of the interface
and if_dname/unit are the driver name and instance.
This change paves the way for interface renaming and enhanced pseudo
device creation and configuration symantics.
Approved By: re (in principle)
Reviewed By: njl, imp
Tested On: i386, amd64, sparc64
Obtained From: NetBSD (if_xname)
Notes:
svn path=/head/; revision=121816
|
|
|
|
|
|
|
|
| |
bp->b_iooffset (the spot on the disk), not bp->b_offset (the offset in
the file)
Notes:
svn path=/head/; revision=121205
|
|
|
|
|
|
|
| |
Remove KASSERTS and panics with B_PHYS checks which no longer apply.
Notes:
svn path=/head/; revision=121201
|
|
|
|
| |
Notes:
svn path=/head/; revision=121191
|
|
|
|
|
|
|
|
|
|
| |
VOP_INACTIVE routines need not worry about their vnode getting
recycled if they block. Remove the code from nfs_inactive() that
used vget() to get an extra vnode reference that was held during
the nfs_vinvalbuf() call.
Notes:
svn path=/head/; revision=120812
|
|
|
|
|
|
|
| |
it uses vget() which will fail if the identity changes.
Notes:
svn path=/head/; revision=120788
|
|
|
|
| |
Notes:
svn path=/head/; revision=120787
|
|
|
|
| |
Notes:
svn path=/head/; revision=120786
|
|
|
|
|
|
|
| |
Pointed out by: pete@isilon.com
Notes:
svn path=/head/; revision=120755
|
|
|
|
|
|
|
|
| |
- Make a note of the lack of XLOCK protection in this code. We would access
a vnode while it is changing identities without Giant.
Notes:
svn path=/head/; revision=120736
|
|
|
|
|
|
|
|
|
|
|
| |
stack trace supplied by phk, I now understand what's going on here. The
check for VI_XLOCK stops us from calling vinvalbuf once the vnode has been
partially torn down in vclean(). It is not clear that this would cause
a problem. Document this in nfs_bio.c, which is where the other two
filesystems copied this code from.
Notes:
svn path=/head/; revision=120730
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
sufficient to guarantee that this race is not hit. The XLOCK will likely
have to be redesigned due to the way reference counting and mutexes work
in FreeBSD. We currently can not be guaranteed that xlock was not set
and cleared while we were blocked on the interlock while waiting to check
for XLOCK. This would lead us to reference a vnode which was not the
vnode we requested.
- Add a backtrace() call inside of INVARIANTS in the hopes of finding out if
this condition is ever hit. It should not, since we should be retaining
a reference to the vnode in these cases. The reference would be sufficient
to block recycling.
Notes:
svn path=/head/; revision=120264
|
|
|
|
|
|
|
| |
This improves the output of src/tools/tools/vop_table
Notes:
svn path=/head/; revision=120003
|
|
|
|
| |
Notes:
svn path=/head/; revision=119766
|
|
|
|
|
|
|
|
|
| |
Suggested by: bde
Approved by: schweikh (mentor - blanket)
MFC after: 6 weeks
Notes:
svn path=/head/; revision=119735
|
|
|
|
|
|
|
|
|
|
|
| |
read and open.
Approved by: schweikh (mentor)
Agreed: bde
MFC after: 6 weeks
Notes:
svn path=/head/; revision=119687
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This code dates back to the very first diskless support on FreeBSD,
back when swapon(8) couldn't simply be run on a NFS backed file.
Suggested replacement command sequence on the client:
dd if=/dev/zero of=/swapfile bs=1k count=1 oseek=100000
swapon /swapfile
rm -f /swapfile
For whatever value of 100000 you want.
Notes:
svn path=/head/; revision=118944
|
|
|
|
|
|
|
|
|
|
|
| |
1) avoid immediately calling bzero() after malloc() by passing M_ZERO
2) do not initialize individual members of the global context to zero
3) remove an unused assignment of ifctx in bootpc_init()
Reviewed by: tegge
Notes:
svn path=/head/; revision=118639
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
to set np->n_size back to the desired size again after calling
nfs_meta_setsize(), since it could end up in nfs_loadattrcache() getting
called, which would change n_size back to the value it had before the
truncate request was issued. The result of this bug is that the size info
cached in the nfsnode becomes incorrect, lseek(fd, ofs, SEEK_END) seeks
past the end of the file, stat() returns the wrong size, etc.
PR: 41792
MFC after: 2 weeks
Notes:
svn path=/head/; revision=118135
|
|
|
|
| |
Notes:
svn path=/head/; revision=118094
|
|
|
|
| |
Notes:
svn path=/head/; revision=117152
|