summaryrefslogtreecommitdiffstats
path: root/drivers/staging/lustre/lustre/include/obd.h
diff options
context:
space:
mode:
authorVitaly Fertman <vitaly.fertman@seagate.com>2018-04-16 00:14:53 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-04-23 14:57:40 +0200
commita3c849f1fda9bdfcdb2bb868fbfd33ab00d2ec83 (patch)
tree05549d7f17ade8b5f75203b9b35a2d85524cb035 /drivers/staging/lustre/lustre/include/obd.h
parent8c4931881e30c3f6c292eada725f174da9858e04 (diff)
downloadop-kernel-dev-a3c849f1fda9bdfcdb2bb868fbfd33ab00d2ec83.zip
op-kernel-dev-a3c849f1fda9bdfcdb2bb868fbfd33ab00d2ec83.tar.gz
staging: lustre: ldlm: xattr locks are lost on mdt
On the server side mdt_intent_getxattr() can return EFAULT if a buffer cannot be found, it is returned after lock_replace, where a new lock is installed into lockp. An error forces ldlm_lock_enqueue() to destroy the original lock, but ldlm_handle_enqueue0() drops the reference on the new lock. The xattr client code implied intent error is returned under a lock, which is immediately cancelled. Check if a lock obtained and cancel it properly for error cases. Note: we should support both cases for interop needs, an intent error under a lock and with a lock abort. Keep returning a lock with an intent error for interop purposes for now, to be dropped later when client will get old enough. make all intent ops to work through md_intent_lock: getxattr and layout, which should extract the intent error. Signed-off-by: Vitaly Fertman <vitaly.fertman@seagate.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-7433 Seagate-bug-id: MRP-3072 MRP-3137 Reviewed-on: http://review.whamcloud.com/17220 Reviewed-by: Andrew Perepechko <andrew.perepechko@seagate.com> Reviewed-by: Andriy Skulysh <andriy.skulysh@seagate.com> Tested-by: Elena V. Gryaznova <elena.gryaznova@seagate.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Lai Siyao <lai.siyao@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/lustre/lustre/include/obd.h')
-rw-r--r--drivers/staging/lustre/lustre/include/obd.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/staging/lustre/lustre/include/obd.h b/drivers/staging/lustre/lustre/include/obd.h
index ea6056b..48cf7ab 100644
--- a/drivers/staging/lustre/lustre/include/obd.h
+++ b/drivers/staging/lustre/lustre/include/obd.h
@@ -909,8 +909,7 @@ struct md_ops {
const void *, size_t, umode_t, uid_t, gid_t,
cfs_cap_t, __u64, struct ptlrpc_request **);
int (*enqueue)(struct obd_export *, struct ldlm_enqueue_info *,
- const union ldlm_policy_data *,
- struct lookup_intent *, struct md_op_data *,
+ const union ldlm_policy_data *, struct md_op_data *,
struct lustre_handle *, __u64);
int (*getattr)(struct obd_export *, struct md_op_data *,
struct ptlrpc_request **);
OpenPOWER on IntegriCloud