aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/hid/hid-wiimote.h
diff options
context:
space:
mode:
authorDavid Herrmann <dh.herrmann@gmail.com>2013-05-05 17:12:54 -0400
committerJiri Kosina <jkosina@suse.cz>2013-06-03 05:07:01 -0400
commit6c5ae01805e2cc1810328b538ccb2376b5f8bd9f (patch)
tree0870bb177a597bb36787d48b4112c587ab2614f9 /drivers/hid/hid-wiimote.h
parentdcf392313817efb4f318ebbf21f607dbdaf5ea56 (diff)
HID: wiimote: convert LEDS to modules
Each of the 4 LEDs may be supported individually by devices. Therefore, we need one module for each device. To avoid code-duplication, we simply pass the LED ID as "arg" argument to the module loading code. This just moves the code over to wiimote-module. The semantics stay the same as before. Signed-off-by: David Herrmann <dh.herrmann@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers/hid/hid-wiimote.h')
-rw-r--r--drivers/hid/hid-wiimote.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/hid/hid-wiimote.h b/drivers/hid/hid-wiimote.h
index 4151514fcd2e..66150a693324 100644
--- a/drivers/hid/hid-wiimote.h
+++ b/drivers/hid/hid-wiimote.h
@@ -129,6 +129,10 @@ enum wiimod_module {
129 WIIMOD_KEYS, 129 WIIMOD_KEYS,
130 WIIMOD_RUMBLE, 130 WIIMOD_RUMBLE,
131 WIIMOD_BATTERY, 131 WIIMOD_BATTERY,
132 WIIMOD_LED1,
133 WIIMOD_LED2,
134 WIIMOD_LED3,
135 WIIMOD_LED4,
132 WIIMOD_NUM, 136 WIIMOD_NUM,
133 WIIMOD_NULL = WIIMOD_NUM, 137 WIIMOD_NULL = WIIMOD_NUM,
134}; 138};
@@ -185,6 +189,7 @@ enum wiiproto_reqs {
185 189
186extern void wiiproto_req_drm(struct wiimote_data *wdata, __u8 drm); 190extern void wiiproto_req_drm(struct wiimote_data *wdata, __u8 drm);
187extern void wiiproto_req_rumble(struct wiimote_data *wdata, __u8 rumble); 191extern void wiiproto_req_rumble(struct wiimote_data *wdata, __u8 rumble);
192extern void wiiproto_req_leds(struct wiimote_data *wdata, int leds);
188extern void wiiproto_req_status(struct wiimote_data *wdata); 193extern void wiiproto_req_status(struct wiimote_data *wdata);
189extern int wiimote_cmd_write(struct wiimote_data *wdata, __u32 offset, 194extern int wiimote_cmd_write(struct wiimote_data *wdata, __u32 offset,
190 const __u8 *wmem, __u8 size); 195 const __u8 *wmem, __u8 size);