aboutsummaryrefslogtreecommitdiff
path: root/scripts/objdiff
diff options
context:
space:
mode:
authorJian Yu <[email protected]>2016-03-27 20:26:27 -0400
committerGreg Kroah-Hartman <[email protected]>2016-03-29 12:10:20 -0700
commit304d13ff4d5dcccea2cf199d96d6716de31b7321 (patch)
treeacdb4fa8e16dc4c6389f6682779cafebdfc3a488 /scripts/objdiff
parent2dc09ea8d91a97dd01c675f2903ce5b4d1fd48d3 (diff)
staging: lustre: libcfs: replace direct HZ access with kernel APIs
On some customers' systems, the kernel was compiled with HZ defined to 100, instead of 1000. This improves performance for HPC applications. However, to use these systems with Lustre, customers have to re-build Lustre for the kernel because Lustre directly uses the defined constant HZ. Since kernel 2.6.21, some non-HZ dependent timing APIs become non- inline functions, which can be used in Lustre codes to replace the direct HZ access. These kernel APIs include: jiffies_to_msecs() jiffies_to_usecs() jiffies_to_timespec() msecs_to_jiffies() usecs_to_jiffies() timespec_to_jiffies() And here are some samples of the replacement: HZ -> msecs_to_jiffies(MSEC_PER_SEC) n * HZ -> msecs_to_jiffies(n * MSEC_PER_SEC) HZ / n -> msecs_to_jiffies(MSEC_PER_SEC / n) n / HZ -> jiffies_to_msecs(n) / MSEC_PER_SEC n / HZ * 1000 -> jiffies_to_msecs(n) This patch replaces the direct HZ access in the libcfs module. Signed-off-by: Jian Yu <[email protected]> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5443 Reviewed-on: http://review.whamcloud.com/11993 Reviewed-by: Nathaniel Clark <[email protected]> Reviewed-by: James Simmons <[email protected]> Reviewed-by: Oleg Drokin <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'scripts/objdiff')
0 files changed, 0 insertions, 0 deletions