the only call thar really needs a big encodebuf is WRITE. So give each
PDU its private encodebuf. This avoids the need to memcpy the data from
the static rpc->encodebuf to the pdu->outdata.data.
Signed-off-by: Peter Lieven <pl@kamp.de>
The NFS spec states:
"The ratio of the directory entry size to the size of the attributes plus the
size of the file handle is usually at least 8 to 1."
Though implementation dependent the spec implies that the previous 1 to 1 ratio
could have a detrimental impact on the performance of the server due to most of
the data per VOP_READDIR call being wasted.
The Linux kernel uses the 8 to 1 ratio.
Signed-off-by: Stefan Blanke <stefan.blanke@framestore.com>
Signed-off-by: Mark Hills <mark.hills@framestore.com>
Map NFS3ERR_NOTEMPTY to ENOTEMPTY rather than EEXIST. POSIX allows
either EEXIST or ENOTEMPTY for rmdir on a non-empty directory but
ENOTEMPTY is more explicit and in line with Linux, OS X, FreeBSD and
OpenBSD's behavior.
Signed-off-by: Ross Lagerwall <rosslagerwall@gmail.com>
This patch switches libnfs over to use precompiled rpcgen files
and using ZDR. ZDR is a trivial reimplementation of XDR that is built in
into libnfs.
This removes the dependencies of rpc/xdr completely and allow us to build on any
system, even systems where rpcgen and librpc/libxdr are not generally available.