summaryrefslogtreecommitdiffstats
path: root/abs/core/lirc_085/kernel-2.6.27.patch
blob: 05cf75bb3dabe497402998a9285f5ff3577fc3ce (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
diff -Nur lirc-0.8.3.orig/drivers/lirc_dev/lirc_dev.c lirc-0.8.3/drivers/lirc_dev/lirc_dev.c
--- lirc-0.8.3.orig/drivers/lirc_dev/lirc_dev.c	2008-01-13 11:45:02.000000000 +0100
+++ lirc-0.8.3/drivers/lirc_dev/lirc_dev.c	2008-10-10 16:29:15.000000000 +0200
@@ -49,7 +49,7 @@
 #include <linux/uaccess.h>
 #include <linux/errno.h>
 #endif
-#include <asm/semaphore.h>
+#include <linux/semaphore.h>
 #if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 0)
 #include <linux/wrapper.h>
 #endif
diff -Nur lirc-0.8.3.orig/drivers/lirc_i2c/lirc_i2c.c lirc-0.8.3/drivers/lirc_i2c/lirc_i2c.c
--- lirc-0.8.3.orig/drivers/lirc_i2c/lirc_i2c.c	2008-05-04 15:49:53.000000000 +0200
+++ lirc-0.8.3/drivers/lirc_i2c/lirc_i2c.c	2008-10-10 16:29:00.000000000 +0200
@@ -54,7 +54,7 @@
 #include <linux/i2c.h>
 #include <linux/i2c-algo-bit.h>
 
-#include <asm/semaphore.h>
+#include <linux/semaphore.h>
 
 #include "drivers/kcompat.h"
 #include "drivers/lirc_dev/lirc_dev.h"
--- lirc-0.8.3.orig/drivers/kcompat.h	2008/05/14 16:37:49	5.36
+++ lirc-0.8.3.orig/drivers/kcompat.h	2008/09/27 08:16:15	5.37
@@ -36,7 +36,7 @@
 	class_simple_destroy(cls);
 }
 
-#define lirc_device_create(cs, parent, dev, fmt, args...) \
+#define lirc_device_create(cs, parent, dev, drvdata, fmt, args...) \
 	class_simple_device_add(cs, dev, parent, fmt, ## args)
 
 static inline void lirc_device_destroy(lirc_class_t *cls, dev_t devt)
@@ -48,20 +48,29 @@
 
 #if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 15)
 
-#define lirc_device_create(cs, parent, dev, fmt, args...) \
+#define lirc_device_create(cs, parent, dev, drvdata, fmt, args...) \
 	class_device_create(cs, dev, parent, fmt, ## args)
 
 #else /* >= 2.6.15 */
 
 #if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 26)
 
-#define lirc_device_create(cs, parent, dev, fmt, args...) \
+#define lirc_device_create(cs, parent, dev, drvdata, fmt, args...) \
 	class_device_create(cs, NULL, dev, parent, fmt, ## args)
 
 #else /* >= 2.6.26 */
 
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 27)
+
+#define lirc_device_create(cs, parent, dev, drvdata, fmt, args...) \
+	class_device_create(cs, parent, dev, fmt, ## args)
+
+#else /* >= 2.6.27 */
+
 #define lirc_device_create device_create
 
+#endif /* >= 2.6.27 */
+
 #endif /* >= 2.6.26 */
 
 #define LIRC_DEVFS_PREFIX
--- lirc-0.8.3.orig/drivers/lirc_dev/lirc_dev.c	2008/09/06 07:30:16	1.60
+++ lirc-0.8.3.orig/drivers/lirc_dev/lirc_dev.c	2008/09/27 08:16:15	1.61
@@ -397,7 +397,7 @@
 			DEV_LIRC "/%u", ir->p.minor);
 #endif
 	(void) lirc_device_create(lirc_class, ir->p.dev,
-				  MKDEV(IRCTL_DEV_MAJOR, ir->p.minor),
+				  MKDEV(IRCTL_DEV_MAJOR, ir->p.minor), NULL,
 				  "lirc%u", ir->p.minor);
 
 	if (p->sample_rate || p->get_queue) {