diff options
author | David Herrmann <dh.herrmann@googlemail.com> | 2011-11-17 14:12:10 +0100 |
---|---|---|
committer | Jiri Kosina <jkosina@suse.cz> | 2011-11-22 23:10:26 +0100 |
commit | 43e5e7c60ee7039f538ccfaaa4e99829719d9bea (patch) | |
tree | c97a33352738f583e8f0c563af733914e02b147a /drivers/hid/hid-wiimote.h | |
parent | 5906215bab9fccf7aa2c4305accf0716c4634d69 (diff) | |
download | kernel_goldelico_gta04-43e5e7c60ee7039f538ccfaaa4e99829719d9bea.zip kernel_goldelico_gta04-43e5e7c60ee7039f538ccfaaa4e99829719d9bea.tar.gz kernel_goldelico_gta04-43e5e7c60ee7039f538ccfaaa4e99829719d9bea.tar.bz2 |
HID: wiimote: Add debugfs support stubs
Add initializer and deinitializer for debugfs support. This will later allow raw
eeprom access and direct DRM modifications to debug wiimote behaviour and
further protocol reverse-engineerings.
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers/hid/hid-wiimote.h')
-rw-r--r-- | drivers/hid/hid-wiimote.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/drivers/hid/hid-wiimote.h b/drivers/hid/hid-wiimote.h index 1f3e53a..89b8851 100644 --- a/drivers/hid/hid-wiimote.h +++ b/drivers/hid/hid-wiimote.h @@ -74,6 +74,7 @@ struct wiimote_data { struct input_dev *ir; struct power_supply battery; struct wiimote_ext *ext; + struct wiimote_debug *debug; spinlock_t qlock; __u8 head; @@ -137,6 +138,18 @@ static inline void wiiext_handle(void *u, const __u8 *p) { } #endif +#ifdef CONFIG_DEBUG_FS + +extern int wiidebug_init(struct wiimote_data *wdata); +extern void wiidebug_deinit(struct wiimote_data *wdata); + +#else + +static inline int wiidebug_init(void *u) { return 0; } +static inline void wiidebug_deinit(void *u) { } + +#endif + /* requires the state.lock spinlock to be held */ static inline bool wiimote_cmd_pending(struct wiimote_data *wdata, int cmd, __u32 opt) |