From f4e39f710f9069208594870b5cdd37879b46a404 Mon Sep 17 00:00:00 2001 From: Oleg Drokin Date: Mon, 3 Jun 2019 02:39:41 -0400 Subject: [PATCH 1/1] LU-10948 mdt: Remove openlock compat code with 2.1 Checking openlock when doing a create does not allow us to create a file if we want to also get openlock from it right away. Since 2.1 is no longer something we care about wrt compatibility, ok to kill it. Change-Id: Ic4327be5c45ae856dfbe20291a59c5b1654dbf8f Signed-off-by: Oleg Drokin Reviewed-on: https://review.whamcloud.com/35039 Reviewed-by: Patrick Farrell Tested-by: Jenkins Tested-by: Maloo Reviewed-by: Andreas Dilger --- lustre/mdt/mdt_open.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/lustre/mdt/mdt_open.c b/lustre/mdt/mdt_open.c index fe0cb34..eb43f79 100644 --- a/lustre/mdt/mdt_open.c +++ b/lustre/mdt/mdt_open.c @@ -1365,11 +1365,7 @@ int mdt_reint_open(struct mdt_thread_info *info, struct mdt_lock_handle *lhc) GOTO(out, result = -EFAULT); } CDEBUG(D_INFO, "No object(1), continue as regular open.\n"); - } else if (open_flags & (MDS_OPEN_BY_FID | MDS_OPEN_LOCK)) { - /* - * MDS_OPEN_LOCK is checked for backward compatibility with 2.1 - * client. - */ + } else if (open_flags & MDS_OPEN_BY_FID) { result = mdt_open_by_fid_lock(info, ldlm_rep, lhc); if (result < 0) CDEBUG(D_INFO, "no object for "DFID": %d\n", -- 1.8.3.1