client: expose layout information

This allows us to construct pNFS layouts and DS filehandles that
match the Ceph clustering, placement, and striping structure.

(Includes pieces of API v2 by Matt.)

Signed-off-by: Matt Benjamin <matt@linuxbox.com>

Conflicts:
	src/client/Client.cc

Signed-off-by: Matt Benjamin <matt@linuxbox.com>
client: direct read/write methods that bypass cache, cap checks

These methods were created to implement pNFS data server support,
bypassing cap checks since the pNFS MDS holds a cap on behalf of
the client, realized in the recallable layout.

(Includes pieces of API v2 by Matt.)

Signed-off-by: Matt Benjamin <matt@linuxbox.com>
client/SyntheticClient: adapt to new ll_* interface

(Includes pieces of NFS interface widening by Adam.)

Signed-off-by: Matt Benjamin <matt@linuxbox.com>
client/fuse_ll: adapt to new ll_ interface

This adapts the FUSE client to David Zafman's proposed interface
changes.

(Includes pieces of NFS interface widening by Adam.)

Signed-off-by: Matt Benjamin <matt@linuxbox.com>

Conflicts:
	src/client/fuse_ll.cc

Signed-off-by: Matt Benjamin <matt@linuxbox.com>
libcephfs: expose new client ll_ interface

This patch exposes all changes made for interfacing with Ganesha
and layout support and David Zafman's proposed modifications to
the low-level API.

Signed-off-by: Adam Emerson <aemerson@linuxbox.com>
Signed-off-by: Matt Benjamin <matt@linuxbox.com>
libcephfs: add ceph_ll_lookup_root()

Signed-off-by: Andrey Kuznetsov <Andrey_Kuznetsov@epam.com>
libcephfs: add ceph_ll_listxattr

Signed-off-by: Andrey Kuznetsov <Andrey_Kuznetsov@epam.com>
libcephfs: add an xattr ll test

Signed-off-by: Andrey Kuznetsov <Andrey_Kuznetsov@epam.com>
mds: include requested caps (namely, xattrs) on getattr reply

For xattrs, we only include them in the reply if we are issuing caps on
them.  However, in the getattr case, we need to include the snapshot of the
current state.

The original problem is reproduced by LibCephFS.Xattrs_ll (a simple set
then get).

Signed-off-by: Sage Weil <sage@inktank.com>
client, libcephfs: make readlink sane

Supply a buffer and copy the data into it.  Do not ever expose internal
pointers from libcephfs's own cache.

Signed-off-by: Sage Weil <sage@inktank.com>