LU-4597 clio: clear nowait flag agl lock re-enqueue

The LDLM_FL_BLOCK_NOWAIT flag should be cleared when re-enqueue
the agl lock as normal glimpse, otherwise, it won't get size back
if there is conflicting locks on other client.

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Change-Id: Ifd311606e824d6574bfbf3256841061e8867214a
Patch-Set: 1
LU-4703 mdd: do not skip xattr sanity check for all cases

xattr sanity check should be done at all times.
Otherwise we are risking letting a non root user setting
access acl on any file.

Cherry-picked-by: Ned Bass <bass6@llnl.gov>
Path-set: 1

Signed-off-by: Li Dongyang <dongyang.li@anu.edu.au>
Change-Id: I5f44d38f2589f0758548d8ccae5efef27205f0a0
LU-4704 acl: fix permission problem of setfacl

Setxattr does not check the permission when setting ACL xattrs. This
will cause security problem because any user can walk around
permission checking by changing ACL rules.

Patch-set: 2
Cherry-picked-by: Ned Bass <bass6@llnl.gov>

Signed-off-by: Li Xi <lixi@ddn.com>
Change-Id: I1e5c44674f2e22ecbe29a589a219bed52d037b9b
LU-4006 lnet: abort messages whose MD has been unlinked

If LNetMDUnlink has been called, all outgoing messages
on that MD should be aborted before lnet_ni_send() is
called.

Signed-off-by: Isaac Huang <he.huang@intel.com>
Change-Id: I3ebe6d3f4ecc21cd6f00aebfb98b90109501df5a
Reviewed-on: http://review.whamcloud.com/8041
Tested-by: Jenkins
Reviewed-by: Liang Zhen <liang.zhen@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Patch-Set: 4
Revert "LU-4222 mdt: extra checking for getattr RPC."

This reverts commit 4496fd9562bb1b2b0d9e1f925d7771e8dd795f4d.
LU-4222 mdt: extra checking for getattr RPC.

It should check whether getattr RPC can hold
layout MD(RMF_MDT_MD), in case the client sends
some invalid RPC, which can cause panic on MDT.

Client will retrieve cl_max_md_size/cl_default_md_size
from MDS during mount process, so it will initialize
cl_max_md_size/cl_default_md_size before sending getattr
to MDS.

Signed-off-by: wang di <di.wang@intel.com>
Change-Id: Ic12f281d574e7138ee0e1d5aae6161b7607837cc
Patch-Set: 7
LU-4008 mdt: Don't allocate unused unlink cookie buffer

Since quite awhile ago we no longer send unlink cookies
or EA data to the clients from unlinks/renames, so we
no longer need to allocate reply buffer for them in
mdt_close() and other such places.
Also clean up unused fields related to these buffers in
md_attr structure.

Additionally for lockless getattr, try to allocate just
as much EA space in the reply as needed (based on the
EA size of the inode).

Change-Id: I4c5bfb5f2d39653d5612c90967d5e1ac83d441e6
Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Patch-Set: 5
LU-4008 mdt: Shrink default LOVEA reply buffer

Instead of allocating maximum possible LOVEA for intent requests,
allocate a sane default to fit up to 100 stripes, should the size
be bigger, the buffer reallocation code will kick in.

Change-Id: I2c5e09ab5288769484837d4f7c32361e316eb7e2
Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Patch-Set: 2
LU-4719 mdt: Don't try to print non-existent objects

mdt_dump_lmm() needs to make sure it's not trying to print
objects for a default striping from a directory, since there
are not objects in this case.

Return early if the D_INFO debug mask is disenabled, so it
doesn't iterate through the LOV/LMV layout at all.  That is
just a waste of effort.

Change-Id: I2fffdaefad2a6b05247676441451fffdca620dcd
Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Patch-Set: 1