Whamcloud - gitweb
LU-10602 utils: fix file heat support 57/34757/3
authorAndreas Dilger <adilger@whamcloud.com>
Thu, 25 Apr 2019 13:23:56 +0000 (15:23 +0200)
committerOleg Drokin <green@whamcloud.com>
Wed, 8 May 2019 06:05:20 +0000 (06:05 +0000)
commitac1f97a881019b78ce3289885461259d280562b3
tree55c3b21d0d4a95dd0075d6755da927c97ba710f4
parent392dab3c01bb802892466f9a05ef1b56406b8522
LU-10602 utils: fix file heat support

Change the LL_IOC_HEAT_SET ioctl number assignment to reduce the
number of different values used, since we are running out.  Use
a __u64 as the IOC struct argument instead of a "long" since that
is what is actually passed, and it avoids being CPU-dependent.

Move the LU_HEAT_FLAG_* values into an enum to avoid a generic
"flags" argument in the code.  This makes it clear what is passed.

Clean up code style for lfs_heat_get() and lfs_heat_set().

Fixes: ae723cf8161f ("LU-10602 llite: add file heat support")
Signed-off-by: Andreas Dilger <adilger@whamcloud.com>
Change-Id: If06212d2d62d085a2104cf54ae9a10e512eb2efd
Reviewed-on: https://review.whamcloud.com/34757
Reviewed-by: Wang Shilong <wshilong@ddn.com>
Tested-by: Jenkins
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Yingjin Qian <qian@ddn.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/include/uapi/linux/lustre/lustre_user.h
lustre/llite/file.c
lustre/utils/lfs.c