History log of /freebsd-10.1-release/lib/libstand/nfs.c
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
# 272461 02-Oct-2014 gjb

Copy stable/10@r272459 to releng/10.1 as part of
the 10.1-RELEASE process.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation

# 256281 10-Oct-2013 gjb

Copy head (r256279) to stable/10 as part of the 10.0-RELEASE cycle.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation


# 252468 01-Jul-2013 mav

Move pos++ out of the complicated equation, introduced at r240780.
There is an oppinion that result of that equation is compiler-specific.

Submitted by: dt71@gmx.com, kientzle
Reviewed by: rmacklem
MFC after: 3 days


# 240881 24-Sep-2012 kevlo

Revert r240850 and remove redundant NULL check before free(3).
free(3) handles NULL parameter fine.

Reviewed by: kib, Garrett Cooper


# 240850 23-Sep-2012 kevlo

Avoid NULL dereference


# 240780 21-Sep-2012 mav

Make nfs_readdir() more careful about using response data, cached in global
buffer. For now it fixes bug when following `ls` command will return data
from previous one aborted by pager. Also it should allow to read several
directories same time, for example, for recursive tracerse.


# 240774 21-Sep-2012 mav

Don't use global nfs_root_node variable as per-file storage. There are
fields that should be file-specific.


# 212125 01-Sep-2010 rmacklem

Modify lib/libstand/nfs.c to use NFSv3 instead of NFSv2.
This allows the nfs_getrootfh() function to return the
correct file handle size to pxe.c for pxeboot. It also
results in NFSv2 no longer being used by default anywhere
in FreeBSD. If built with OLD_NFSV2 defined, the old
code that predated this patch will be built and NFSv2
will be used.

Tested by: danny at cs.huji.ac.il
MFC after: 2 weeks


# 197178 13-Sep-2009 emaste

ANSIfy, whitespace and comment adjustments, to simplify comparing these
files with NetBSD / OpenBSD versions.


# 185155 21-Nov-2008 luigi

use the correct variable in a debug message.


# 177935 05-Apr-2008 dfr

On i386, don't try to do network-type stuff if the device name is'nt pxeN.


# 124811 21-Jan-2004 jhb

Clean up error handling in libstand filesystem code to be more consistent:
- bzipfs and gzipfs now properly return errno values directly from their
read routines rather than returning -1.
- missing errno values on error returns for the seek routines on almost
all filesystems were added.
- fstat() now returns -1 if an error occurs rather than ignoring it.
- nfs's readdir() routine now reports valid errno values if an error or
EOF occurs rather than EPERM (It was just returning 0 for success and
1 for failure).
- nullfs used the wrong semantics for every function besides close() and
seek(). Getting it right for close() appears to be an accident at that.
- read() for buffered files no longer returns 0 (EOF) if an error occurs,
but returns -1 instead.


# 111776 02-Mar-2003 marcel

Fix a machine check abort caused by the EFI loader trying to open a
file in the NFS file system when the underlying device is not a
network device. A Sparc64 specific hack for this exact problem was
already present (nfs.c:1.9, tftp.c:1.10), but the problem is not
specific to Sparc64. The hack has been promoted to a non-i386 test
because on non-i386 architectures it's either impossible to have
non-network devices coexist in the same loader with the NFS FS, or
network and non-network device coexist and NFS filesystems can only
be used on top of network devices. I believe i386 pxeboot is where
this does not hold.

The root cause of this problem is in open.c where each file system
is tried until no more file systems exist or a file system returns
success. There's no notion of a list of valid file systems given
the underlying device and the non-existence of a file can cause
the invalid combination to be tried.


# 101112 31-Jul-2002 jake

Stash various networking paramters in the environment for the kernel
to pick up, ala pxe.


# 99558 07-Jul-2002 jake

Add a hack (kludge?) to avoid trying to access files backed by disk
devices as though they were backed by network devices.


# 92913 21-Mar-2002 obrien

Remove 'register' keyword.


# 84221 30-Sep-2001 dillon

Add __FBSDID()s to libstand


# 65496 05-Sep-2000 msmith

Expose the NFS root node, so that an evil consumer can use it to get the
NFS filehandle for the root mount.


# 59853 01-May-2000 ps

Add readdir support to the NFS filesystem in libstand.


# 59824 01-May-2000 ps

Do not attempt to free a nfs node if it is the root node. The root
node is statically allocated and is not guarded, so free will panic
in nfs_close.


# 59766 29-Apr-2000 jlemon

Add a readdir function to the loader fsops vector, and implement the
functionality for some of the filesystesms.


# 39468 18-Sep-1998 msmith

Path arguments to *_open functions should be const, but we were mangling
them.

Submitted by: write-protected text segment in BTX


# 38452 20-Aug-1998 msmith

This commit was generated by cvs2svn to compensate for changes in r38451,
which included commits to RCS files with non-trunk default branches.


# 38451 20-Aug-1998 msmith

This is libstand; a support library for standalone executables (eg. bootstrap
modules).
Obtained from: NetBSD, with some architectural changes and many additions.