aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJulia Lawall <Julia.Lawall@lip6.fr>2018-01-16 19:56:54 -0500
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2018-01-17 12:52:22 -0500
commit698c03b4745006e14eccb8270f714d52fac1c97e (patch)
tree5432e1f38da57af40039f4a99cff24b74c84c722
parent77ecf14e9e878eb87ecb5449711ca979712798be (diff)
Input: inline macros for MODULE_LICENSE, etc
Inline macro for MODULE_LICENSE to make the license information easy to find, eg with grep. Inline the other module-related macros at the same time. A simplified version of the semantic patch for the MODULE_LICENSE case is as follows: (http://coccinelle.lip6.fr/) // <smpl> @s@ identifier i; expression e; @@ @@ declarer name MODULE_LICENSE; identifier s.i; expression s.e; @@ MODULE_LICENSE( - i + e ); // </smpl> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> [dtor: added a couple of drivers missed by the script, removed a few unused DRIVER_VERSION macros] Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-rw-r--r--drivers/input/joystick/xpad.c7
-rw-r--r--drivers/input/misc/keyspan_remote.c8
-rw-r--r--drivers/input/misc/yealink.c6
-rw-r--r--drivers/input/tablet/acecad.c11
-rw-r--r--drivers/input/tablet/aiptek.c11
-rw-r--r--drivers/input/tablet/hanwang.c7
-rw-r--r--drivers/input/tablet/kbtab.c14
-rw-r--r--drivers/input/touchscreen/usbtouchscreen.c9
8 files changed, 17 insertions, 56 deletions
diff --git a/drivers/input/joystick/xpad.c b/drivers/input/joystick/xpad.c
index d86e59515b9c..0434a1369188 100644
--- a/drivers/input/joystick/xpad.c
+++ b/drivers/input/joystick/xpad.c
@@ -84,9 +84,6 @@
84#include <linux/usb/input.h> 84#include <linux/usb/input.h>
85#include <linux/usb/quirks.h> 85#include <linux/usb/quirks.h>
86 86
87#define DRIVER_AUTHOR "Marko Friedemann <mfr@bmx-chemnitz.de>"
88#define DRIVER_DESC "X-Box pad driver"
89
90#define XPAD_PKT_LEN 64 87#define XPAD_PKT_LEN 64
91 88
92/* xbox d-pads should map to buttons, as is required for DDR pads 89/* xbox d-pads should map to buttons, as is required for DDR pads
@@ -1924,6 +1921,6 @@ static struct usb_driver xpad_driver = {
1924 1921
1925module_usb_driver(xpad_driver); 1922module_usb_driver(xpad_driver);
1926 1923
1927MODULE_AUTHOR(DRIVER_AUTHOR); 1924MODULE_AUTHOR("Marko Friedemann <mfr@bmx-chemnitz.de>");
1928MODULE_DESCRIPTION(DRIVER_DESC); 1925MODULE_DESCRIPTION("X-Box pad driver");
1929MODULE_LICENSE("GPL"); 1926MODULE_LICENSE("GPL");
diff --git a/drivers/input/misc/keyspan_remote.c b/drivers/input/misc/keyspan_remote.c
index 4f13b2f7bf4f..67482b248b2d 100644
--- a/drivers/input/misc/keyspan_remote.c
+++ b/drivers/input/misc/keyspan_remote.c
@@ -17,10 +17,6 @@
17#include <linux/module.h> 17#include <linux/module.h>
18#include <linux/usb/input.h> 18#include <linux/usb/input.h>
19 19
20#define DRIVER_VERSION "v0.1"
21#define DRIVER_AUTHOR "Michael Downey <downey@zymeta.com>"
22#define DRIVER_DESC "Driver for the USB Keyspan remote control."
23
24/* Parameters that can be passed to the driver. */ 20/* Parameters that can be passed to the driver. */
25static int debug; 21static int debug;
26module_param(debug, int, 0444); 22module_param(debug, int, 0444);
@@ -589,6 +585,6 @@ static struct usb_driver keyspan_driver =
589module_usb_driver(keyspan_driver); 585module_usb_driver(keyspan_driver);
590 586
591MODULE_DEVICE_TABLE(usb, keyspan_table); 587MODULE_DEVICE_TABLE(usb, keyspan_table);
592MODULE_AUTHOR(DRIVER_AUTHOR); 588MODULE_AUTHOR("Michael Downey <downey@zymeta.com>");
593MODULE_DESCRIPTION(DRIVER_DESC); 589MODULE_DESCRIPTION("Driver for the USB Keyspan remote control.");
594MODULE_LICENSE("GPL"); 590MODULE_LICENSE("GPL");
diff --git a/drivers/input/misc/yealink.c b/drivers/input/misc/yealink.c
index a1e0ff59d2f2..f0c9bf87b4e3 100644
--- a/drivers/input/misc/yealink.c
+++ b/drivers/input/misc/yealink.c
@@ -56,8 +56,6 @@
56#include "yealink.h" 56#include "yealink.h"
57 57
58#define DRIVER_VERSION "yld-20051230" 58#define DRIVER_VERSION "yld-20051230"
59#define DRIVER_AUTHOR "Henk Vergonet"
60#define DRIVER_DESC "Yealink phone driver"
61 59
62#define YEALINK_POLLING_FREQUENCY 10 /* in [Hz] */ 60#define YEALINK_POLLING_FREQUENCY 10 /* in [Hz] */
63 61
@@ -1006,6 +1004,6 @@ module_usb_driver(yealink_driver);
1006 1004
1007MODULE_DEVICE_TABLE (usb, usb_table); 1005MODULE_DEVICE_TABLE (usb, usb_table);
1008 1006
1009MODULE_AUTHOR(DRIVER_AUTHOR); 1007MODULE_AUTHOR("Henk Vergonet");
1010MODULE_DESCRIPTION(DRIVER_DESC); 1008MODULE_DESCRIPTION("Yealink phone driver");
1011MODULE_LICENSE("GPL"); 1009MODULE_LICENSE("GPL");
diff --git a/drivers/input/tablet/acecad.c b/drivers/input/tablet/acecad.c
index fcb67c7cd86b..a86255d08a6b 100644
--- a/drivers/input/tablet/acecad.c
+++ b/drivers/input/tablet/acecad.c
@@ -30,15 +30,8 @@
30#include <linux/module.h> 30#include <linux/module.h>
31#include <linux/usb/input.h> 31#include <linux/usb/input.h>
32 32
33/* 33MODULE_AUTHOR("Edouard TISSERANT <edouard.tisserant@wanadoo.fr>");
34 * Version Information 34MODULE_DESCRIPTION("USB Acecad Flair tablet driver");
35 */
36#define DRIVER_VERSION "v3.2"
37#define DRIVER_DESC "USB Acecad Flair tablet driver"
38#define DRIVER_AUTHOR "Edouard TISSERANT <edouard.tisserant@wanadoo.fr>"
39
40MODULE_AUTHOR(DRIVER_AUTHOR);
41MODULE_DESCRIPTION(DRIVER_DESC);
42MODULE_LICENSE("GPL"); 35MODULE_LICENSE("GPL");
43 36
44#define USB_VENDOR_ID_ACECAD 0x0460 37#define USB_VENDOR_ID_ACECAD 0x0460
diff --git a/drivers/input/tablet/aiptek.c b/drivers/input/tablet/aiptek.c
index 0b55e1f375b3..545fa6e89035 100644
--- a/drivers/input/tablet/aiptek.c
+++ b/drivers/input/tablet/aiptek.c
@@ -79,13 +79,6 @@
79#include <asm/unaligned.h> 79#include <asm/unaligned.h>
80 80
81/* 81/*
82 * Version Information
83 */
84#define DRIVER_VERSION "v2.3 (May 2, 2007)"
85#define DRIVER_AUTHOR "Bryan W. Headley/Chris Atenasio/Cedric Brun/Rene van Paassen"
86#define DRIVER_DESC "Aiptek HyperPen USB Tablet Driver (Linux 2.6.x)"
87
88/*
89 * Aiptek status packet: 82 * Aiptek status packet:
90 * 83 *
91 * (returned as Report 1 - relative coordinates from mouse and stylus) 84 * (returned as Report 1 - relative coordinates from mouse and stylus)
@@ -1941,8 +1934,8 @@ static struct usb_driver aiptek_driver = {
1941 1934
1942module_usb_driver(aiptek_driver); 1935module_usb_driver(aiptek_driver);
1943 1936
1944MODULE_AUTHOR(DRIVER_AUTHOR); 1937MODULE_AUTHOR("Bryan W. Headley/Chris Atenasio/Cedric Brun/Rene van Paassen");
1945MODULE_DESCRIPTION(DRIVER_DESC); 1938MODULE_DESCRIPTION("Aiptek HyperPen USB Tablet Driver");
1946MODULE_LICENSE("GPL"); 1939MODULE_LICENSE("GPL");
1947 1940
1948module_param(programmableDelay, int, 0); 1941module_param(programmableDelay, int, 0);
diff --git a/drivers/input/tablet/hanwang.c b/drivers/input/tablet/hanwang.c
index 70cb26bbfe1d..4042c41160f4 100644
--- a/drivers/input/tablet/hanwang.c
+++ b/drivers/input/tablet/hanwang.c
@@ -28,11 +28,8 @@
28#include <linux/module.h> 28#include <linux/module.h>
29#include <linux/usb/input.h> 29#include <linux/usb/input.h>
30 30
31#define DRIVER_AUTHOR "Xing Wei <weixing@hanwang.com.cn>" 31MODULE_AUTHOR("Xing Wei <weixing@hanwang.com.cn>");
32#define DRIVER_DESC "USB Hanwang tablet driver" 32MODULE_DESCRIPTION("USB Hanwang tablet driver");
33
34MODULE_AUTHOR(DRIVER_AUTHOR);
35MODULE_DESCRIPTION(DRIVER_DESC);
36MODULE_LICENSE("GPL"); 33MODULE_LICENSE("GPL");
37 34
38#define USB_VENDOR_ID_HANWANG 0x0b57 35#define USB_VENDOR_ID_HANWANG 0x0b57
diff --git a/drivers/input/tablet/kbtab.c b/drivers/input/tablet/kbtab.c
index bee18e33e261..75b500651e4e 100644
--- a/drivers/input/tablet/kbtab.c
+++ b/drivers/input/tablet/kbtab.c
@@ -5,19 +5,11 @@
5#include <asm/unaligned.h> 5#include <asm/unaligned.h>
6 6
7/* 7/*
8 * Version Information 8 * Pressure-threshold modules param code from Alex Perry <alex.perry@ieee.org>
9 * v0.0.1 - Original, extremely basic version, 2.4.xx only
10 * v0.0.2 - Updated, works with 2.5.62 and 2.4.20;
11 * - added pressure-threshold modules param code from
12 * Alex Perry <alex.perry@ieee.org>
13 */ 9 */
14 10
15#define DRIVER_VERSION "v0.0.2" 11MODULE_AUTHOR("Josh Myer <josh@joshisanerd.com>");
16#define DRIVER_AUTHOR "Josh Myer <josh@joshisanerd.com>" 12MODULE_DESCRIPTION("USB KB Gear JamStudio Tablet driver");
17#define DRIVER_DESC "USB KB Gear JamStudio Tablet driver"
18
19MODULE_AUTHOR(DRIVER_AUTHOR);
20MODULE_DESCRIPTION(DRIVER_DESC);
21MODULE_LICENSE("GPL"); 13MODULE_LICENSE("GPL");
22 14
23#define USB_VENDOR_ID_KBGEAR 0x084e 15#define USB_VENDOR_ID_KBGEAR 0x084e
diff --git a/drivers/input/touchscreen/usbtouchscreen.c b/drivers/input/touchscreen/usbtouchscreen.c
index 2c41107240de..aa77d243b786 100644
--- a/drivers/input/touchscreen/usbtouchscreen.c
+++ b/drivers/input/touchscreen/usbtouchscreen.c
@@ -55,11 +55,6 @@
55#include <linux/usb/input.h> 55#include <linux/usb/input.h>
56#include <linux/hid.h> 56#include <linux/hid.h>
57 57
58
59#define DRIVER_VERSION "v0.6"
60#define DRIVER_AUTHOR "Daniel Ritz <daniel.ritz@gmx.ch>"
61#define DRIVER_DESC "USB Touchscreen Driver"
62
63static bool swap_xy; 58static bool swap_xy;
64module_param(swap_xy, bool, 0644); 59module_param(swap_xy, bool, 0644);
65MODULE_PARM_DESC(swap_xy, "If set X and Y axes are swapped."); 60MODULE_PARM_DESC(swap_xy, "If set X and Y axes are swapped.");
@@ -1763,8 +1758,8 @@ static struct usb_driver usbtouch_driver = {
1763 1758
1764module_usb_driver(usbtouch_driver); 1759module_usb_driver(usbtouch_driver);
1765 1760
1766MODULE_AUTHOR(DRIVER_AUTHOR); 1761MODULE_AUTHOR("Daniel Ritz <daniel.ritz@gmx.ch>");
1767MODULE_DESCRIPTION(DRIVER_DESC); 1762MODULE_DESCRIPTION("USB Touchscreen Driver");
1768MODULE_LICENSE("GPL"); 1763MODULE_LICENSE("GPL");
1769 1764
1770MODULE_ALIAS("touchkitusb"); 1765MODULE_ALIAS("touchkitusb");