Whamcloud - gitweb
LU-11157 obd: round values to nearest MiB for *_mb syfs files 93/36393/2
authorJames Simmons <uja.ornl@yahoo.com>
Tue, 30 Apr 2019 13:17:56 +0000 (09:17 -0400)
committerOleg Drokin <green@whamcloud.com>
Thu, 21 Nov 2019 07:31:57 +0000 (07:31 +0000)
commit72c2d383c3e77206b0d169d894a18b5e43b7b72b
tree4bd8eb362c087ac05a2b06474f1394e6e02a8fdd
parentf0cf4dfa339f0252cda73f57fe833012c3aea4fa
LU-11157 obd: round values to nearest MiB for *_mb syfs files

Several sysfs files report their settings with the functions
lprocfs_[seq]_read_frac_helper() which has the intent of showing
fractional values i.e 1.5 MiB. This approach has caused problems
with shells which don't handle fractional representation and the
values reported don't faithfully represent the original value the
configurator passed into the sysfs file. To resolve this lets
instead always round up the value the configurator passed into
the sysfs file to the nearest MiB value. This way it is always
guaranteed the values reported are always exactly some MiB value.

Lustre-change: https://review.whamcloud.com/34317
Lustre-commit: ba2817fe3ead1b8e32be6d6c6ce25b490626118a

Change-Id: Ia2e8cf8421784853aa33d4bb87c54aee00953835
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Ben Evans <bevans@cray.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Signed-off-by: Minh Diep <mdiep@whamcloud.com>
Reviewed-on: https://review.whamcloud.com/36393
Tested-by: jenkins <devops@whamcloud.com>
Reviewed-by: James Simmons <jsimmons@infradead.org>
Tested-by: Maloo <maloo@whamcloud.com>
lustre/include/lprocfs_status.h
lustre/llite/llite_internal.h
lustre/llite/lproc_llite.c
lustre/mdc/lproc_mdc.c
lustre/obdclass/lprocfs_status.c
lustre/osc/lproc_osc.c