From ff49480735bcc87231c4047de44cfa83d73ffa37 Mon Sep 17 00:00:00 2001 From: Guillaume Knispel Date: Tue, 17 Jan 2012 17:10:57 +0100 Subject: port to 2.6.32 (work in progress) --- tdm/xivo_tdm.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'tdm/xivo_tdm.c') diff --git a/tdm/xivo_tdm.c b/tdm/xivo_tdm.c index b6ea0c8..4b3afa6 100644 --- a/tdm/xivo_tdm.c +++ b/tdm/xivo_tdm.c @@ -45,7 +45,7 @@ #include // rdtscl static ulong tstamp; static int dump_count; -module_param(dump_count, int, 0666); +module_param(dump_count, int, 0664); MODULE_PARM_DESC(dump_count, "number of traces to emit " "(can be reset at runtime via /sys)"); #define DBG_TRACE(...) \ @@ -88,7 +88,7 @@ MODULE_LICENSE("GPL"); #if defined(REF_0_0) && defined(REF_1_1) -# error don't define both REF_0_0 and REF_1_1 +# error dont define both REF_0_0 and REF_1_1 #endif #if !defined(REF_0_0) && !defined(REF_1_1) @@ -104,12 +104,13 @@ MODULE_LICENSE("GPL"); #define RX_BUF_NUM (2048) /* for Linux < 2.6.19; WARNING: DO NOT USE IN INTERFACES IN THIS CASE! - * (no ifdef so that this warning can be respected when porting - * to modern kernel) thanks to a clash between this definition of 'bool' - * and those of Linux */ +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,19) typedef unsigned char bool; enum { false = 0, true = 1 }; +#else +# warning "remember to not use bool in interfaces while Linux < 2.6.19 is supported" +#endif struct xivo_tdm_callbacks_struct { -- cgit v1.2.3