summaryrefslogtreecommitdiff
path: root/io-module/mts-io.c
diff options
context:
space:
mode:
authorMike Nicholson <mikempls@users.noreply.github.com>2019-08-06 15:50:30 -0500
committerVolodymyr Vorobiov <volodymyr.vorobiov@globallogic.com>2020-02-12 12:29:58 +0200
commit0a4a5f96dd649a5c5e18d43d7bd206f35845e1cb (patch)
treedc7636fb24b1dd84141e7b3356add2bfeb0f0cf6 /io-module/mts-io.c
parentce0d4983a61b0fed699bf67cf4c1f6472cc92d87 (diff)
downloadmts-io-0a4a5f96dd649a5c5e18d43d7bd206f35845e1cb.tar.gz
mts-io-0a4a5f96dd649a5c5e18d43d7bd206f35845e1cb.tar.bz2
mts-io-0a4a5f96dd649a5c5e18d43d7bd206f35845e1cb.zip
Add correct timer cb proto for kernel < 4.15.0
(cherry picked from commit 9cae1b197308e0ed093596c984bae21ded4e7ec8)
Diffstat (limited to 'io-module/mts-io.c')
-rw-r--r--io-module/mts-io.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/io-module/mts-io.c b/io-module/mts-io.c
index 66ded86..154d120 100644
--- a/io-module/mts-io.c
+++ b/io-module/mts-io.c
@@ -135,9 +135,6 @@ static volatile int radio_reset_timer_is_start = 0;
static struct timer_list radio_reset_available_timer;
static volatile int radio_reset_available_timer_is_start = 0;
static time_t time_now_secs(void);
-static void radio_reset_available_timer_callback(struct timer_list *list);
-static void radio_reset_timer_callback(struct timer_list *list);
-
/* generic GPIO support */
#include "gpio.c"
@@ -283,7 +280,11 @@ static time_t time_now_secs(void)
return ts.tv_sec;
}
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,15,0)
static void radio_reset_available_timer_callback( struct timer_list *data )
+#else
+static void radio_reset_available_timer_callback( unsigned long data )
+#endif
{
/* do your timer stuff here */
//log_info("radio_reset_available_timer_callback\n");
@@ -295,7 +296,11 @@ static void radio_reset_available_timer_callback( struct timer_list *data )
radio_reset_available_timer_is_start = 0;
}
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,15,0)
static void radio_reset_timer_callback( struct timer_list *data )
+#else
+static void radio_reset_timer_callback( unsigned long data )
+#endif
{
/* do your timer stuff here */
//log_info("radio_reset_timer_callback\n");