Whamcloud - gitweb
LU-11200 libcfs: handle DECLARE_TIMER reduced to two arguments 39/32939/5
authorJames Simmons <uja.ornl@yahoo.com>
Mon, 6 Aug 2018 17:56:55 +0000 (13:56 -0400)
committerOleg Drokin <green@whamcloud.com>
Sat, 18 Aug 2018 02:23:45 +0000 (02:23 +0000)
commitac40000d4bde21f807a68cb2add326ea5d77385c
tree77bfa13abab726298f3e8c51db2c4084a9270d1e
parent511ea5850f2553d14891aeda7972d0526c67a3af
LU-11200 libcfs: handle DECLARE_TIMER reduced to two arguments

For the linux kernel their exist two ways to initialize a
struct timer_list. One method is with setup_timer() and the other is
with the DEFINE_TIMER macro. For earlier kernels both methods employed
callbacked with a argument of the type unsigned long. In kernels 4.15+
both methods of initialization use struct timer_list pointer for its
callback argument. During the 4.14 development phase we have
setup_timer() using struct timer_list as an argument for its callback
but DEFINE_TIMER was still using unsigned long. Additionally when
DEFINE_TIMER did move to using struct timer_list it reduced the number
of arguments to the macro. This patch handles the 4.14 kernel state of
development for the timer API.

Test-Parameters: trivial

Change-Id: I1c509838153328ed4bbdfa50468a396e13037d50
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-on: https://review.whamcloud.com/32939
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Li Dongyang <dongyangli@ddn.com>
Reviewed-by: Yang Sheng <ys@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
libcfs/autoconf/lustre-libcfs.m4
libcfs/include/libcfs/linux/linux-time.h
lustre/ldlm/ldlm_lockd.c