diff options
Diffstat (limited to 'drivers/usb/input/hid-tmff.c')
-rw-r--r-- | drivers/usb/input/hid-tmff.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/drivers/usb/input/hid-tmff.c b/drivers/usb/input/hid-tmff.c index 8f6a0a6f94a9..023fd5ac31c8 100644 --- a/drivers/usb/input/hid-tmff.c +++ b/drivers/usb/input/hid-tmff.c | |||
@@ -111,6 +111,7 @@ int hid_tmff_init(struct hid_device *hid) | |||
111 | struct tmff_device *private; | 111 | struct tmff_device *private; |
112 | struct list_head *pos; | 112 | struct list_head *pos; |
113 | struct hid_input *hidinput = list_entry(hid->inputs.next, struct hid_input, list); | 113 | struct hid_input *hidinput = list_entry(hid->inputs.next, struct hid_input, list); |
114 | struct input_dev *input_dev = hidinput->input; | ||
114 | 115 | ||
115 | private = kmalloc(sizeof(struct tmff_device), GFP_KERNEL); | 116 | private = kmalloc(sizeof(struct tmff_device), GFP_KERNEL); |
116 | if (!private) | 117 | if (!private) |
@@ -155,7 +156,7 @@ int hid_tmff_init(struct hid_device *hid) | |||
155 | private->report = report; | 156 | private->report = report; |
156 | private->rumble = field; | 157 | private->rumble = field; |
157 | 158 | ||
158 | set_bit(FF_RUMBLE, hidinput->input.ffbit); | 159 | set_bit(FF_RUMBLE, input_dev->ffbit); |
159 | break; | 160 | break; |
160 | 161 | ||
161 | default: | 162 | default: |
@@ -164,11 +165,11 @@ int hid_tmff_init(struct hid_device *hid) | |||
164 | } | 165 | } |
165 | 166 | ||
166 | /* Fallthrough to here only when a valid usage is found */ | 167 | /* Fallthrough to here only when a valid usage is found */ |
167 | hidinput->input.upload_effect = hid_tmff_upload_effect; | 168 | input_dev->upload_effect = hid_tmff_upload_effect; |
168 | hidinput->input.flush = hid_tmff_flush; | 169 | input_dev->flush = hid_tmff_flush; |
169 | 170 | ||
170 | set_bit(EV_FF, hidinput->input.evbit); | 171 | set_bit(EV_FF, input_dev->evbit); |
171 | hidinput->input.ff_effects_max = TMFF_EFFECTS; | 172 | input_dev->ff_effects_max = TMFF_EFFECTS; |
172 | } | 173 | } |
173 | } | 174 | } |
174 | 175 | ||