OpenSDE Packages Database (without history before r20070)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

343 lines
12 KiB

  1. # --- SDE-COPYRIGHT-NOTE-BEGIN ---
  2. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  3. #
  4. # Filename: package/.../lirc/kernel-usb-hotfix.patch
  5. # Copyright (C) 2006 The T2 SDE Project
  6. #
  7. # More information can be found in the files COPYING and README.
  8. #
  9. # This patch file is dual-licensed. It is available under the license the
  10. # patched project is licensed under, as long as it is an OpenSource license
  11. # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
  12. # of the GNU General Public License as published by the Free Software
  13. # Foundation; either version 2 of the License, or (at your option) any later
  14. # version.
  15. # --- SDE-COPYRIGHT-NOTE-END ---
  16. Kernel 2.6.16 changed struct usb_driver, now has the .owner field removed
  17. Patch is taken from lirc CVS
  18. Index: drivers/kcompat.h
  19. ===================================================================
  20. RCS file: /cvsroot/lirc/lirc/drivers/kcompat.h,v
  21. retrieving revision 5.24
  22. retrieving revision 5.26
  23. diff -u -r5.24 -r5.26
  24. --- ./drivers/kcompat.h 7 Jan 2006 20:51:31 -0000 5.24
  25. +++ ./drivers/kcompat.h 4 Mar 2006 23:16:02 -0000 5.26
  26. @@ -1,10 +1,16 @@
  27. -/* $Id: kcompat.h,v 5.24 2006/01/07 20:51:31 lirc Exp $ */
  28. +/* $Id: kcompat.h,v 5.26 2006/03/04 23:16:02 lirc Exp $ */
  29. #ifndef _KCOMPAT_H
  30. #define _KCOMPAT_H
  31. #include <linux/version.h>
  32. +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,16)
  33. +#define LIRC_THIS_MODULE(x) x,
  34. +#else /* >= 2.6.16 */
  35. +#define LIRC_THIS_MODULE(x)
  36. +#endif
  37. +
  38. #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,0)
  39. #include <linux/device.h>
  40. @@ -245,6 +251,11 @@
  41. # define I2C_ALGO_BIT 0
  42. #endif
  43. +/* removed in 2.6.16 */
  44. +#ifndef I2C_DRIVERID_EXP3
  45. +# define I2C_DRIVERID_EXP3 0xf003
  46. +#endif
  47. +
  48. /*************************** USB specific *****************************/
  49. #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 4, 0)
  50. #include <linux/usb.h>
  51. Index: drivers/lirc_atiusb/lirc_atiusb.c
  52. ===================================================================
  53. RCS file: /cvsroot/lirc/lirc/drivers/lirc_atiusb/lirc_atiusb.c,v
  54. retrieving revision 1.51
  55. retrieving revision 1.53
  56. diff -u -r1.51 -r1.53
  57. --- ./drivers/lirc_atiusb/lirc_atiusb.c 29 Oct 2005 14:18:53 -0000 1.51
  58. +++ ./drivers/lirc_atiusb/lirc_atiusb.c 4 Mar 2006 22:36:38 -0000 1.53
  59. @@ -12,7 +12,7 @@
  60. * Artur Lipowski <alipowski@kki.net.pl>'s 2002
  61. * "lirc_dev" and "lirc_gpio" LIRC modules
  62. *
  63. - * $Id: lirc_atiusb.c,v 1.51 2005/10/29 14:18:53 lirc Exp $
  64. + * $Id: lirc_atiusb.c,v 1.53 2006/03/04 22:36:38 lirc Exp $
  65. */
  66. /*
  67. @@ -408,13 +408,13 @@
  68. dprintk(DRIVER_NAME "[%d]: accept channel %d\n", ir->devnum, chan+1);
  69. if (ir->remote_type == ATI1_COMPATIBLE) {
  70. + for (i = len; i < CODE_LENGTH; i++) iep->buf[i] = 0;
  71. /* check for repeats */
  72. if (memcmp(iep->old, iep->buf, len) == 0) {
  73. if (iep->old_jiffies + repeat_jiffies > jiffies) {
  74. return -1;
  75. }
  76. } else {
  77. - for (i = len; i < CODE_LENGTH; i++) iep->buf[i] = 0;
  78. memcpy(iep->old, iep->buf, CODE_LENGTH);
  79. }
  80. iep->old_jiffies = jiffies;
  81. @@ -1180,7 +1180,7 @@
  82. }
  83. static struct usb_driver usb_remote_driver = {
  84. - .owner = THIS_MODULE,
  85. + LIRC_THIS_MODULE(.owner = THIS_MODULE)
  86. .name = DRIVER_NAME,
  87. .probe = usb_remote_probe,
  88. .disconnect = usb_remote_disconnect,
  89. @@ -1195,7 +1195,7 @@
  90. printk("\n" DRIVER_NAME ": " DRIVER_DESC " v" DRIVER_VERSION "\n");
  91. printk(DRIVER_NAME ": " DRIVER_AUTHOR "\n");
  92. - dprintk(DRIVER_NAME ": debug mode enabled: $Id: lirc_atiusb.c,v 1.51 2005/10/29 14:18:53 lirc Exp $\n");
  93. + dprintk(DRIVER_NAME ": debug mode enabled: $Id: lirc_atiusb.c,v 1.53 2006/03/04 22:36:38 lirc Exp $\n");
  94. request_module("lirc_dev");
  95. Index: drivers/lirc_i2c/lirc_i2c.c
  96. ===================================================================
  97. RCS file: /cvsroot/lirc/lirc/drivers/lirc_i2c/lirc_i2c.c,v
  98. retrieving revision 1.35
  99. retrieving revision 1.36
  100. diff -u -r1.35 -r1.36
  101. --- ./drivers/lirc_i2c/lirc_i2c.c 20 Oct 2005 18:25:58 -0000 1.35
  102. +++ ./drivers/lirc_i2c/lirc_i2c.c 4 Mar 2006 23:16:03 -0000 1.36
  103. @@ -1,4 +1,4 @@
  104. -/* $Id: lirc_i2c.c,v 1.35 2005/10/20 18:25:58 lirc Exp $ */
  105. +/* $Id: lirc_i2c.c,v 1.36 2006/03/04 23:16:03 lirc Exp $ */
  106. /*
  107. * i2c IR lirc plugin for Hauppauge and Pixelview cards - new 2.3.x i2c stack
  108. @@ -360,9 +360,16 @@
  109. static int ir_command(struct i2c_client *client, unsigned int cmd, void *arg);
  110. static struct i2c_driver driver = {
  111. +#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 16)
  112. name: "i2c ir driver",
  113. - id: I2C_DRIVERID_EXP3, /* FIXME */
  114. flags: I2C_DF_NOTIFY,
  115. +#else
  116. + .driver = {
  117. + owner: THIS_MODULE,
  118. + name: "i2c ir driver",
  119. + },
  120. +#endif
  121. + id: I2C_DRIVERID_EXP3, /* FIXME */
  122. attach_adapter: ir_probe,
  123. detach_client: ir_detach,
  124. command: ir_command,
  125. Index: drivers/lirc_igorplugusb/lirc_igorplugusb.c
  126. ===================================================================
  127. RCS file: /cvsroot/lirc/lirc/drivers/lirc_igorplugusb/lirc_igorplugusb.c,v
  128. retrieving revision 1.7
  129. retrieving revision 1.8
  130. diff -u -r1.7 -r1.8
  131. --- ./drivers/lirc_igorplugusb/lirc_igorplugusb.c 21 Mar 2005 14:39:38 -0000 1.7
  132. +++ ./drivers/lirc_igorplugusb/lirc_igorplugusb.c 4 Mar 2006 22:36:38 -0000 1.8
  133. @@ -615,7 +615,7 @@
  134. };
  135. static struct usb_driver usb_remote_driver = {
  136. - .owner = THIS_MODULE,
  137. + LIRC_THIS_MODULE(.owner = THIS_MODULE)
  138. .name = DRIVER_NAME,
  139. .probe = usb_remote_probe,
  140. .disconnect = usb_remote_disconnect,
  141. Index: drivers/lirc_imon/lirc_imon.c
  142. ===================================================================
  143. RCS file: /cvsroot/lirc/lirc/drivers/lirc_imon/lirc_imon.c,v
  144. retrieving revision 1.9
  145. retrieving revision 1.10
  146. diff -u -r1.9 -r1.10
  147. --- ./drivers/lirc_imon/lirc_imon.c 3 Dec 2005 15:18:07 -0000 1.9
  148. +++ ./drivers/lirc_imon/lirc_imon.c 4 Mar 2006 22:36:38 -0000 1.10
  149. @@ -1,7 +1,7 @@
  150. /*
  151. * lirc_imon.c: LIRC plugin/VFD driver for Ahanix/Soundgraph IMON IR/VFD
  152. *
  153. - * $Id: lirc_imon.c,v 1.9 2005/12/03 15:18:07 lirc Exp $
  154. + * $Id: lirc_imon.c,v 1.10 2006/03/04 22:36:38 lirc Exp $
  155. *
  156. * Version 0.3
  157. * Supports newer iMON models that send decoded IR signals.
  158. @@ -201,7 +201,7 @@
  159. /* USB Device data */
  160. static struct usb_driver imon_driver = {
  161. - .owner = THIS_MODULE,
  162. + LIRC_THIS_MODULE(.owner = THIS_MODULE)
  163. .name = MOD_NAME,
  164. .probe = imon_probe,
  165. .disconnect = imon_disconnect,
  166. Index: drivers/lirc_it87/lirc_it87.c
  167. ===================================================================
  168. RCS file: /cvsroot/lirc/lirc/drivers/lirc_it87/lirc_it87.c,v
  169. retrieving revision 1.17
  170. retrieving revision 1.18
  171. diff -u -r1.17 -r1.18
  172. --- ./drivers/lirc_it87/lirc_it87.c 4 Oct 2005 20:10:04 -0000 1.17
  173. +++ ./drivers/lirc_it87/lirc_it87.c 21 Jan 2006 17:43:36 -0000 1.18
  174. @@ -58,7 +58,7 @@
  175. #include <linux/delay.h>
  176. #include <linux/poll.h>
  177. #include <asm/system.h>
  178. -#include <asm/segment.h>
  179. +#include <asm/uaccess.h>
  180. #include <asm/io.h>
  181. #include <asm/irq.h>
  182. #include <asm/fcntl.h>
  183. Index: drivers/lirc_mceusb/lirc_mceusb.c
  184. ===================================================================
  185. RCS file: /cvsroot/lirc/lirc/drivers/lirc_mceusb/lirc_mceusb.c,v
  186. retrieving revision 1.10
  187. retrieving revision 1.11
  188. diff -u -r1.10 -r1.11
  189. --- ./drivers/lirc_mceusb/lirc_mceusb.c 29 Oct 2005 14:18:53 -0000 1.10
  190. +++ ./drivers/lirc_mceusb/lirc_mceusb.c 4 Mar 2006 22:36:39 -0000 1.11
  191. @@ -222,7 +222,7 @@
  192. /* usb specific object needed to register this driver with the usb subsystem */
  193. static struct usb_driver mceusb_driver = {
  194. - .owner = THIS_MODULE,
  195. + LIRC_THIS_MODULE(.owner = THIS_MODULE)
  196. .name = DRIVER_NAME,
  197. .probe = mceusb_probe,
  198. .disconnect = mceusb_disconnect,
  199. Index: drivers/lirc_mceusb2/lirc_mceusb2.c
  200. ===================================================================
  201. RCS file: /cvsroot/lirc/lirc/drivers/lirc_mceusb2/lirc_mceusb2.c,v
  202. retrieving revision 1.2
  203. retrieving revision 1.4
  204. diff -u -r1.2 -r1.4
  205. --- ./drivers/lirc_mceusb2/lirc_mceusb2.c 29 Oct 2005 14:18:53 -0000 1.2
  206. +++ ./drivers/lirc_mceusb2/lirc_mceusb2.c 24 Mar 2006 21:01:22 -0000 1.4
  207. @@ -98,11 +98,13 @@
  208. #define VENDOR_PHILIPS 0x0471
  209. #define VENDOR_SMK 0x0609
  210. #define VENDOR_TATUNG 0x1460
  211. +#define VENDOR_GATEWAY 0x107b
  212. static struct usb_device_id usb_remote_table [] = {
  213. { USB_DEVICE(VENDOR_PHILIPS, 0x0815) }, /* Philips eHome Infrared Transciever */
  214. { USB_DEVICE(VENDOR_SMK, 0x031d) }, /* SMK/Toshiba G83C0004D410 */
  215. { USB_DEVICE(VENDOR_TATUNG, 0x9150) }, /* Tatung eHome Infrared Transceiver */
  216. + { USB_DEVICE(VENDOR_GATEWAY, 0x3009) }, /* Gateway eHome Infrared Transceiver */
  217. { } /* Terminating entry */
  218. };
  219. @@ -585,7 +587,7 @@
  220. }
  221. static struct usb_driver usb_remote_driver = {
  222. - .owner = THIS_MODULE,
  223. + LIRC_THIS_MODULE(.owner = THIS_MODULE)
  224. .name = DRIVER_NAME,
  225. .probe = usb_remote_probe,
  226. .disconnect = usb_remote_disconnect,
  227. Index: drivers/lirc_sasem/lirc_sasem.c
  228. ===================================================================
  229. RCS file: /cvsroot/lirc/lirc/drivers/lirc_sasem/lirc_sasem.c,v
  230. retrieving revision 1.12
  231. retrieving revision 1.13
  232. diff -u -r1.12 -r1.13
  233. --- ./drivers/lirc_sasem/lirc_sasem.c 3 Dec 2005 15:18:07 -0000 1.12
  234. +++ ./drivers/lirc_sasem/lirc_sasem.c 4 Mar 2006 22:36:39 -0000 1.13
  235. @@ -1,4 +1,4 @@
  236. -/* $Id: lirc_sasem.c,v 1.12 2005/12/03 15:18:07 lirc Exp $ */
  237. +/* $Id: lirc_sasem.c,v 1.13 2006/03/04 22:36:39 lirc Exp $ */
  238. /* lirc_sasem.c - USB remote support for LIRC
  239. * Version 0.5
  240. @@ -189,7 +189,7 @@
  241. /* USB Device data */
  242. static struct usb_driver sasem_driver = {
  243. - .owner = THIS_MODULE,
  244. + LIRC_THIS_MODULE(.owner = THIS_MODULE)
  245. .name = MOD_NAME,
  246. .probe = sasem_probe,
  247. .disconnect = sasem_disconnect,
  248. Index: drivers/lirc_serial/lirc_serial.c
  249. ===================================================================
  250. RCS file: /cvsroot/lirc/lirc/drivers/lirc_serial/lirc_serial.c,v
  251. retrieving revision 5.69
  252. retrieving revision 5.70
  253. diff -u -r5.69 -r5.70
  254. --- ./drivers/lirc_serial/lirc_serial.c 17 Dec 2005 13:56:57 -0000 5.69
  255. +++ ./drivers/lirc_serial/lirc_serial.c 21 Jan 2006 17:43:36 -0000 5.70
  256. @@ -1,4 +1,4 @@
  257. -/* $Id: lirc_serial.c,v 5.69 2005/12/17 13:56:57 lirc Exp $ */
  258. +/* $Id: lirc_serial.c,v 5.70 2006/01/21 17:43:36 lirc Exp $ */
  259. /****************************************************************************
  260. ** lirc_serial.c ***********************************************************
  261. @@ -91,7 +91,7 @@
  262. #include <linux/poll.h>
  263. #include <asm/system.h>
  264. -#include <asm/segment.h>
  265. +#include <asm/uaccess.h>
  266. #include <asm/io.h>
  267. #include <asm/irq.h>
  268. #include <asm/fcntl.h>
  269. Index: drivers/lirc_sir/lirc_sir.c
  270. ===================================================================
  271. RCS file: /cvsroot/lirc/lirc/drivers/lirc_sir/lirc_sir.c,v
  272. retrieving revision 1.42
  273. retrieving revision 1.43
  274. diff -u -r1.42 -r1.43
  275. --- ./drivers/lirc_sir/lirc_sir.c 14 Jan 2006 13:57:24 -0000 1.42
  276. +++ ./drivers/lirc_sir/lirc_sir.c 21 Jan 2006 17:43:36 -0000 1.43
  277. @@ -75,7 +75,7 @@
  278. #include <linux/delay.h>
  279. #include <linux/poll.h>
  280. #include <asm/system.h>
  281. -#include <asm/segment.h>
  282. +#include <asm/uaccess.h>
  283. #include <asm/io.h>
  284. #include <asm/irq.h>
  285. #include <asm/fcntl.h>
  286. Index: drivers/lirc_streamzap/lirc_streamzap.c
  287. ===================================================================
  288. RCS file: /cvsroot/lirc/lirc/drivers/lirc_streamzap/lirc_streamzap.c,v
  289. retrieving revision 1.15
  290. retrieving revision 1.16
  291. diff -u -r1.15 -r1.16
  292. --- ./drivers/lirc_streamzap/lirc_streamzap.c 6 Jan 2006 07:18:03 -0000 1.15
  293. +++ ./drivers/lirc_streamzap/lirc_streamzap.c 4 Mar 2006 22:36:39 -0000 1.16
  294. @@ -1,4 +1,4 @@
  295. -/* $Id: lirc_streamzap.c,v 1.15 2006/01/06 07:18:03 lirc Exp $ */
  296. +/* $Id: lirc_streamzap.c,v 1.16 2006/03/04 22:36:39 lirc Exp $ */
  297. /*
  298. * Streamzap Remote Control driver
  299. @@ -53,7 +53,7 @@
  300. #include "drivers/kcompat.h"
  301. #include "drivers/lirc_dev/lirc_dev.h"
  302. -#define DRIVER_VERSION "$Revision: 1.15 $"
  303. +#define DRIVER_VERSION "$Revision: 1.16 $"
  304. #define DRIVER_NAME "lirc_streamzap"
  305. #define DRIVER_DESC "Streamzap Remote Control driver"
  306. @@ -177,7 +177,7 @@
  307. /* usb specific object needed to register this driver with the usb subsystem */
  308. static struct usb_driver streamzap_driver = {
  309. - .owner = THIS_MODULE,
  310. + LIRC_THIS_MODULE(.owner = THIS_MODULE)
  311. .name = DRIVER_NAME,
  312. .probe = streamzap_probe,
  313. .disconnect = streamzap_disconnect,