summaryrefslogtreecommitdiff
path: root/pcr/lirc-parabola-lts/wpc8769l-build-fix.patch
blob: 5e25693abece01b35a697fa7caede0b1deb11d4c (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
79
80
81
82
83
84
85
86
87
88
89
90
diff --git a/drivers/lirc_wpc8769l/lirc_wpc8769l.c b/drivers/lirc_wpc8769l/lirc_wpc8769l.c
index 790efa2..4248fe9 100644
--- a/drivers/lirc_wpc8769l/lirc_wpc8769l.c
+++ b/drivers/lirc_wpc8769l/lirc_wpc8769l.c
@@ -51,17 +51,13 @@
 #include <linux/irq.h>
 
 #include <linux/acpi.h>
+#include <linux/types.h>
 
 #include <linux/platform_device.h>
+#include <asm-generic/bitops/find.h>
 
-#include "drivers/kcompat.h"
-#if LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 35)
-#include <media/lirc.h>
-#include <media/lirc_dev.h>
-#else
-#include "drivers/lirc.h"
-#include "drivers/lirc_dev/lirc_dev.h"
-#endif
+#include "media/lirc_dev.h"
+#include "media/lirc.h"
 
 #include "lirc_wpc8769l.h"
 
@@ -105,11 +101,11 @@ static unsigned int baseport2;
 static unsigned int irq;
 
 /* Debugging flag. */
-static int debug;
+static bool debug;
 
 /* If true, we skip ACPI autodetection and use the parameter-supplied I/O and
  * IRQ. */
-static int skip_probe;
+static bool skip_probe;
 
 /* Whether the device is open or not. */
 static int lirc_wpc8769l_is_open;
@@ -360,14 +356,14 @@ static irqreturn_t irq_handler(int irqno, void *blah, struct pt_regs *regs)
 		size = count << 3;
 
 		ldata = (unsigned long *) data_buf;
-		next_one = generic_find_next_le_bit(ldata, size, 0);
+		next_one = find_next_bit(ldata, size, 0);
 
 		if (next_one > 0)
 			put_pulse_bit(next_one
 				* WPC8769L_USECS_PER_BIT);
 
 		while (next_one < size) {
-			next_zero = generic_find_next_zero_le_bit(ldata,
+			next_zero = find_next_zero_bit(ldata,
 				size, next_one + 1);
 
 			put_space_bit(
@@ -375,7 +371,7 @@ static irqreturn_t irq_handler(int irqno, void *blah, struct pt_regs *regs)
 				* WPC8769L_USECS_PER_BIT);
 
 			if (next_zero < size) {
-				next_one = generic_find_next_le_bit(ldata,
+				next_one = find_next_bit(ldata,
 					size, next_zero + 1);
 
 				put_pulse_bit(
@@ -922,12 +918,12 @@ static int wpc8769l_acpi_detect(void)
 #ifdef MODULE
 static struct platform_device *lirc_wpc8769l_platform_dev;
 
-static int __devinit lirc_wpc8769l_probe(struct platform_device *dev)
+static int lirc_wpc8769l_probe(struct platform_device *dev)
 {
 	return 0;
 }
 
-static int __devexit lirc_wpc8769l_remove(struct platform_device *dev)
+static int lirc_wpc8769l_remove(struct platform_device *dev)
 {
 	return 0;
 }
@@ -955,7 +951,7 @@ static int lirc_wpc8769l_resume(struct platform_device *dev)
 
 static struct platform_driver lirc_wpc8769l_platform_driver = {
 	.probe		= lirc_wpc8769l_probe,
-	.remove		= __devexit_p(lirc_wpc8769l_remove),
+	.remove		= lirc_wpc8769l_remove,
 	.suspend	= lirc_wpc8769l_suspend,
 	.resume		= lirc_wpc8769l_resume,
 	.driver		= {