1
Fix location of headers for kernel 2.6.27.
3
Source: svn diff -c 4496 http://svn.digium.com/svn/zaptel/branches/1.4
4
Upstream Issue: http://bugs.digium.com/13277
10
#include <linux/kernel.h>
11
#include <linux/device.h>
12
+#include <linux/version.h>
13
#include <asm/atomic.h>
14
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
15
+#include <linux/semaphore.h>
17
#include <asm/semaphore.h>
19
#include <linux/moduleparam.h>
21
#ifndef CONFIG_DEBUG_FS
22
--- a/kernel/wctdm24xxp/GpakCust.c
23
+++ b/kernel/wctdm24xxp/GpakCust.c
26
#include <linux/version.h>
27
#include <linux/delay.h>
28
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
29
+#include <linux/semaphore.h>
31
#include <asm/semaphore.h>
35
#include "wctdm24xxp.h"
36
--- a/kernel/wctdm24xxp/wctdm24xxp.h
37
+++ b/kernel/wctdm24xxp/wctdm24xxp.h
40
#include "../zaptel.h"
41
#include "../voicebus.h"
42
+#include <linux/version.h>
43
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
44
+#include <linux/semaphore.h>
46
#include <asm/semaphore.h>
49
#define NUM_FXO_REGS 60
51
--- a/kernel/wctdm24xxp/base.c
52
+++ b/kernel/wctdm24xxp/base.c
53
@@ -44,7 +44,11 @@ Tx Gain - W/Pre-Emphasis: -23.99 to 0.00
54
#include <linux/interrupt.h>
55
#include <linux/workqueue.h>
56
#include <linux/delay.h>
57
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
58
+#include <linux/semaphore.h>
60
#include <asm/semaphore.h>
64
#include <linux/moduleparam.h>
65
--- a/kernel/wctdm24xxp/GpakApi.c
66
+++ b/kernel/wctdm24xxp/GpakApi.c
70
#include <linux/version.h>
71
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
72
+#include <linux/semaphore.h>
74
#include <asm/semaphore.h>
79
--- a/kernel/wcte12xp/vpmadt032.c
80
+++ b/kernel/wcte12xp/vpmadt032.c
84
#include <linux/delay.h>
85
+#include <linux/version.h>
86
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
87
+#include <linux/semaphore.h>
89
#include <asm/semaphore.h>
91
#include <linux/pci.h>
92
#include <linux/firmware.h>
93
#include <linux/list.h>
94
--- a/kernel/wctc4xxp/base.c
95
+++ b/kernel/wctc4xxp/base.c
97
#include <linux/mman.h>
98
#include <linux/delay.h>
100
+#include <linux/version.h>
101
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
102
+#include <linux/semaphore.h>
104
#include <asm/semaphore.h>
106
#include <linux/jiffies.h>
107
#include <linux/workqueue.h>
108
#include <linux/moduleparam.h>