Whamcloud - gitweb
LU-11830 lov: avoid signed vs. unsigned comparison 21/33921/8
authorAndreas Dilger <adilger@whamcloud.com>
Wed, 26 Dec 2018 09:29:55 +0000 (02:29 -0700)
committerOleg Drokin <green@whamcloud.com>
Sun, 3 Mar 2019 00:21:00 +0000 (00:21 +0000)
commit632b3591b6ea21e3029299ef875179a4b5ca918f
treed32560f6803ca649cf2f14aa9eb51a9bab43d541
parentb24d69492b818457d9da0d6dce3adc0f91f18ec6
LU-11830 lov: avoid signed vs. unsigned comparison

In the expansion of do_div64() GCC complains about pointer comparison
because loff_t is not a u64 variable as it should be.  lov_do_div64()
also has signed vs. unsigned comparisons due to a signed loff_t.
Change lov_do_div() to use a 64-bit variable for do_div() instead of
loff_t to avoid these warnings.

Change OST_MAXREQSIZE and friends to be consistently unsigned values
to avoid compiler warnings.

Fix "lfs mirror resync" to avoid comparing signed and unsigned valued.

Signed-off-by: Andreas Dilger <adilger@whamcloud.com>
Change-Id: I6df31a2c0d75e5777f471fe8cb252715dd85a5b1
Reviewed-on: https://review.whamcloud.com/33921
Reviewed-by: Jian Yu <yujian@whamcloud.com>
Tested-by: Jenkins
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/include/lustre_net.h
lustre/lov/lov_internal.h
lustre/obdclass/lprocfs_status.c
lustre/tests/mirror_io.c
lustre/utils/liblustreapi_layout.c
lustre/utils/liblustreapi_mirror.c