Commit b65d0d1b authored by Dmitry Torokhov's avatar Dmitry Torokhov

Input: HID - fix an oops in PID initialization code

Signed-off-by: default avatarDmitry Torokhov <dtor@mail.ru>
parent 940824b0
...@@ -259,7 +259,7 @@ static int hid_pid_upload_effect(struct input_dev *dev, ...@@ -259,7 +259,7 @@ static int hid_pid_upload_effect(struct input_dev *dev,
int hid_pid_init(struct hid_device *hid) int hid_pid_init(struct hid_device *hid)
{ {
struct hid_ff_pid *private; struct hid_ff_pid *private;
struct hid_input *hidinput = list_entry(&hid->inputs, struct hid_input, list); struct hid_input *hidinput = list_entry(hid->inputs.next, struct hid_input, list);
struct input_dev *input_dev = hidinput->input; struct input_dev *input_dev = hidinput->input;
private = hid->ff_private = kzalloc(sizeof(struct hid_ff_pid), GFP_KERNEL); private = hid->ff_private = kzalloc(sizeof(struct hid_ff_pid), GFP_KERNEL);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment