Whamcloud - gitweb
LU-11285 mdt: improve IBITS lock definitions 45/35045/6
authorAndreas Dilger <adilger@whamcloud.com>
Mon, 3 Jun 2019 18:21:53 +0000 (12:21 -0600)
committerOleg Drokin <green@whamcloud.com>
Fri, 12 Jul 2019 05:19:25 +0000 (05:19 +0000)
commit3611352b699ce479779c0ff92ca558d9321e58a2
treeb0540335d68ba4031b069ba6377588d25a953d99
parent87306c22e4b977356f4857d5f750447639d89c26
LU-11285 mdt: improve IBITS lock definitions

Move MDS_INODELOCK_* flags into a named enum, and add the definitions
for the newer flags into wirecheck/wiretest to ensure consistency.

Rename MDS_INODELOCK_MAXSHIFT to MDS_INODELOCK_NUMBITS to hold current
number of lockbits, rather than one less than the number of lockbits,
since the only two places that use it expect it to be one larger than
it is.  Fix uses of MDS_INODELOCK_NUMBITS to be number of locks.  This
does not change the value of MDS_INODELOCK_FULL, which is used in the
protocol to exchange supported lock bits between client and server.

Signed-off-by: Andreas Dilger <adilger@whamcloud.com>
Change-Id: I0c2985bcc602b7182d5db2cf8d590923be2cab07
Reviewed-on: https://review.whamcloud.com/35045
Reviewed-by: Patrick Farrell <pfarrell@whamcloud.com>
Reviewed-by: Mike Pershin <mpershin@whamcloud.com>
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/include/uapi/linux/lustre/lustre_idl.h
lustre/llite/file.c
lustre/ptlrpc/wiretest.c
lustre/utils/wirecheck.c
lustre/utils/wiretest.c