diff --git a/driver/x52joy.c b/driver/x52joy.c index 8f32d41..13abb94 100644 --- a/driver/x52joy.c +++ b/driver/x52joy.c @@ -415,6 +415,8 @@ static int x52_probe(struct usb_interface *intf, device_create_file(&intf->dev, &dev_attr_led_blink); + try_module_get(THIS_MODULE); + dev_info(&intf->dev, "X52 device now attached\n"); return 0; @@ -463,6 +465,8 @@ static void x52_disconnect(struct usb_interface *intf) usb_put_dev(joy->udev); kfree(joy); + module_put(THIS_MODULE); + dev_info(&intf->dev, "X52 device now disconnected\n"); } diff --git a/driver/x52joy_common.h b/driver/x52joy_common.h index 39fbc2b..af1ae4d 100644 --- a/driver/x52joy_common.h +++ b/driver/x52joy_common.h @@ -14,6 +14,8 @@ #include +#include "x52joy_map.h" + /* * The X52 MFD supports the following: * - 3 lines of 16 characters each @@ -68,7 +70,13 @@ struct x52_joy { u8 shift_ind:1; u8 blink_led:1; - u8 :6; + u8 clutch_mode:1; + + u8 shift_state_enabled:1; + u8 clock_enabled:1; + u8 clutch_enabled:1; + u8 clutch_latched:1; + u8 :1; u8 feat_mfd:1; u8 feat_led:1;