Unconditionally support IPV6 (build).

A richer model for interface selection is coming, but for now, unclutter
the code and potential build configurations.

Track a change removing a vestigial instance of conditionally-compiled
IPV6 support.

Signed-off-by: Matt Benjamin <matt@linuxbox.com>
Combine GPFS code to one library.
Fix underflow in lookup_pseudo_exp

Signed-off-by: Adam C. Emerson <aemerson@linuxbox.com>
9P walk: pentry argument to cache_inode_lookup must be NULL on cache miss + put intermediate lookups as we don't need them
(cherry picked from commit 08a2f7e94e0c89b28405d43bc0abceef5adc8781)
FSAL_VFS: fix bad management of xattr. Assumption was made that xattr's contents were always plain strings
(cherry picked from commit e9ef2098c0fa6ca140f1346f4c5be1feb6c67073)
9P: new implementation of xattr. Allow acl to be written (setfacl is a disguised setfattr, it uses system.posix_acl_perms).
(cherry picked from commit 36e698bcc0380f01d85812a02735cb6c9db8354e)
Fix gpfs config file and init script
cmake rpm isn't used in RHEL, stop requiring it in spec file.
Use atomic inc for new_clientid and new_clientid_verifier

Also correct function name for new_clientid_verifier.

Ported from 1.5 5f67b48645e840c4d502eec440d7e0c3fe26d647

Signed-off-by: Frank S. Filz <ffilz@us.ibm.com>
Temp change to return NFS4ERR_BAD_STATEID before clientid is included in stateid for better judgement

Ported from 1.5 ef7e31d8c9ffca379c5e08d8f06300b949001c9d

Signed-off-by: Frank S. Filz <ffilz@us.ibm.com>
Remove dead nfs_tools code

Ported from 1.5 d213b1dc0193beaf88e184c4481f2f52ac1fe3eb

Signed-off-by: Frank S. Filz <ffilz@us.ibm.com>
Grace period should be >= Lease_lifetime.
For environments which have issues with grace period more than 60 seonds,
Lease_Lifetime in main.conf can be changed to a smaller value.

Ported from 1.5 71249367cdabac404425a74907900c143bd722cb

Signed-off-by: Srikrishan Malik <srimalik@in.ibm.com>
Signed-off-by: Frank S. Filz <ffilz@us.ibm.com>
Convert ETXTBSY to ERR_FSAL_SHARE_DENIED instead of FSAL_FILE_OPEN.
For v4 it will be converted to NFS4ERR_SHARE_DENIED.
For v3 it will be converted to NFS3ER_JUKEBOX, which will allow a client to wait
for the share reservation to be released.

Ported from 1.5 35b1a70bacdc777b4fd2fa056a4753220a7e24c7

Signed-off-by: Srikrishan Malik <srimalik@in.ibm.com>
Signed-off-by: Frank S. Filz <ffilz@us.ibm.com>
Don't allow OPEN of a PseudoFS file

Also, return a better error for nfs_FhandleToCache failures.

Ported from 1.5: 9075bee497b67ec1cd0826cda097d6e0de3cf89a

Signed-off-by: Frank S. Filz <ffilz@us.ibm.com>
Fixed byte range lock merging when up- or downgrading sub-ranges

Ported from 1.5: 44aab46665eee745cda796cd73cd96e34210d644

Signed-off-by: Manfred Haubrich <haubrich@de.ibm.com>
Signed-off-by: Frank S. Filz <ffilz@us.ibm.com>
Fix OPNDG10

Two issues:

1. OPEN CREATE UNGUARDED did not reuse existing state
2. state_share_upgrade did not create union of old access and new access

Signed-off-by: Frank S. Filz <ffilz@us.ibm.com>
Reintroduce -DUSE_TIRPC_IPV6=ON option

Signed-off-by: Frank S. Filz <ffilz@us.ibm.com>
Fix OPEN30

For open replay, we need to track the directory cache entry pointer not
the resulting file cache entry pointer.

The entry is saved by Copy_nfs4_state_req and checked by
Check_nfs4_seqid when validating a replayed request.

Ported from 1.5: 9d8a485c1b5726919a62a77e453341840b3e81ba

Additional fixes for 2.0:

open4_open_owner returns bool instead of the status, because
Check_nfs4_seqid could return ANY code including NFS4_OK, and if
we got there, then we have a replayed request.

entry_parent needs to be set at the to for use in Copy_nfs4_state_req.

Signed-off-by: Frank S. Filz <ffilz@us.ibm.com>
Properly fix CLOSE4

It turns out Ganesha really wasn't handling a CLOSE with an invalid
stateid properly. If we detect that the stateid belongs to a valid
clientid, we can return NFS4_OK, but in that case, we must also
update the lease.

We also need to make sure that ONLY CLOSE is affected by this
functionality. V4.1 also handles leases differently.

Signed-off-by: Frank S. Filz <ffilz@us.ibm.com>
Signed-off-by: Venkateswararao Jujjuri "<jvrao@linux.vnet.ibm.com>
Signed-off-by: Frank S. Filz <ffilz@us.ibm.com>
Update 15to20-porting.txt

Signed-off-by: Frank S. Filz <ffilz@us.ibm.com>