Skip to content

Commit e9bb37f

Browse files
Lee Jonesbentiss
authored andcommitted
HID: hid-thrustmaster: Demote a bunch of kernel-doc abuses
Fixes the following W=1 kernel build warning(s): drivers/hid/hid-thrustmaster.c:23: warning: Incorrect use of kernel-doc format: * These interrupts are used to prevent a nasty crash when initializing the drivers/hid/hid-thrustmaster.c:26: warning: cannot understand function prototype: 'const u8 setup_0[] = ' drivers/hid/hid-thrustmaster.c:49: warning: cannot understand function prototype: 'struct tm_wheel_info ' drivers/hid/hid-thrustmaster.c:62: warning: wrong kernel-doc identifier on line: drivers/hid/hid-thrustmaster.c:84: warning: cannot understand function prototype: 'struct __packed tm_wheel_response ' drivers/hid/hid-thrustmaster.c:143: warning: wrong kernel-doc identifier on line: drivers/hid/hid-thrustmaster.c:202: warning: Function parameter or member 'urb' not described in 'thrustmaster_model_handler' drivers/hid/hid-thrustmaster.c:202: warning: expecting prototype for Called by the USB subsystem when the wheel responses to our request(). Prototype was for thrustmaster_model_handler() instead drivers/hid/hid-thrustmaster.c:265: warning: wrong kernel-doc identifier on line: Cc: Jiri Kosina <[email protected]> Cc: Benjamin Tissoires <[email protected]> Cc: Maxime Coquelin <[email protected]> Cc: Alexandre Torgue <[email protected]> Cc: Dario Pagani <[email protected]> Cc: Kim Kuparinen <[email protected]> Cc: [email protected] Cc: [email protected] Cc: [email protected] Signed-off-by: Lee Jones <[email protected]> Signed-off-by: Benjamin Tissoires <[email protected]>
1 parent 66ff899 commit e9bb37f

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

drivers/hid/hid-thrustmaster.c

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// SPDX-License-Identifier: GPL-2.0
2-
/**
2+
/*
33
* When connected to the machine, the Thrustmaster wheels appear as
44
* a «generic» hid gamepad called "Thrustmaster FFB Wheel".
55
*
@@ -19,7 +19,7 @@
1919
#include <linux/slab.h>
2020
#include <linux/module.h>
2121

22-
/**
22+
/*
2323
* These interrupts are used to prevent a nasty crash when initializing the
2424
* T300RS. Used in thrustmaster_interrupts().
2525
*/
@@ -36,7 +36,7 @@ static const unsigned int setup_arr_sizes[] = {
3636
ARRAY_SIZE(setup_3),
3737
ARRAY_SIZE(setup_4)
3838
};
39-
/**
39+
/*
4040
* This struct contains for each type of
4141
* Thrustmaster wheel
4242
*
@@ -49,7 +49,7 @@ static const unsigned int setup_arr_sizes[] = {
4949
struct tm_wheel_info {
5050
uint16_t wheel_type;
5151

52-
/**
52+
/*
5353
* See when the USB control out packet is prepared...
5454
* @TODO The TMX seems to require multiple control codes to switch.
5555
*/
@@ -58,7 +58,7 @@ struct tm_wheel_info {
5858
char const *const wheel_name;
5959
};
6060

61-
/**
61+
/*
6262
* Known wheels.
6363
* Note: TMX does not work as it requires 2 control packets
6464
*/
@@ -72,7 +72,7 @@ static const struct tm_wheel_info tm_wheels_infos[] = {
7272

7373
static const uint8_t tm_wheels_infos_length = 4;
7474

75-
/**
75+
/*
7676
* This structs contains (in little endian) the response data
7777
* of the wheel to the request 73
7878
*
@@ -82,7 +82,7 @@ static const uint8_t tm_wheels_infos_length = 4;
8282
*/
8383
struct __packed tm_wheel_response
8484
{
85-
/**
85+
/*
8686
* Seems to be the type of packet
8787
* - 0x0049 if is data.a (15 bytes)
8888
* - 0x0047 if is data.b (7 bytes)
@@ -93,7 +93,7 @@ struct __packed tm_wheel_response
9393
struct __packed {
9494
uint16_t field0;
9595
uint16_t field1;
96-
/**
96+
/*
9797
* Seems to be the model code of the wheel
9898
* Read table thrustmaster_wheels to values
9999
*/
@@ -122,7 +122,7 @@ struct tm_wheel {
122122
struct usb_ctrlrequest *change_request;
123123
};
124124

125-
/** The control packet to send to wheel */
125+
/* The control packet to send to wheel */
126126
static const struct usb_ctrlrequest model_request = {
127127
.bRequestType = 0xc1,
128128
.bRequest = 73,
@@ -139,7 +139,7 @@ static const struct usb_ctrlrequest change_request = {
139139
.wLength = 0
140140
};
141141

142-
/**
142+
/*
143143
* On some setups initializing the T300RS crashes the kernel,
144144
* these interrupts fix that particular issue. So far they haven't caused any
145145
* adverse effects in other wheels.
@@ -191,7 +191,7 @@ static void thrustmaster_change_handler(struct urb *urb)
191191
hid_warn(hdev, "URB to change wheel mode seems to have failed with error %d\n", urb->status);
192192
}
193193

194-
/**
194+
/*
195195
* Called by the USB subsystem when the wheel responses to our request
196196
* to get [what it seems to be] the wheel's model.
197197
*
@@ -261,7 +261,7 @@ static void thrustmaster_remove(struct hid_device *hdev)
261261
hid_hw_stop(hdev);
262262
}
263263

264-
/**
264+
/*
265265
* Function called by HID when a hid Thrustmaster FFB wheel is connected to the host.
266266
* This function starts the hid dev, tries to allocate the tm_wheel data structure and
267267
* finally send an USB CONTROL REQUEST to the wheel to get [what it seems to be] its

0 commit comments

Comments
 (0)