--- zzzz-none-000/linux-3.10.107/drivers/hid/usbhid/hid-pidff.c 2017-06-27 09:49:32.000000000 +0000 +++ scorpion-7490-727/linux-3.10.107/drivers/hid/usbhid/hid-pidff.c 2021-02-04 17:41:59.000000000 +0000 @@ -568,6 +568,12 @@ int type_id; int error; + pidff->block_load[PID_EFFECT_BLOCK_INDEX].value[0] = 0; + if (old) { + pidff->block_load[PID_EFFECT_BLOCK_INDEX].value[0] = + pidff->pid_id[effect->id]; + } + switch (effect->type) { case FF_CONSTANT: if (!old) { @@ -1252,6 +1258,8 @@ pidff->hid = hid; + hid_device_io_start(hid); + pidff_find_reports(hid, HID_OUTPUT_REPORT, pidff); pidff_find_reports(hid, HID_FEATURE_REPORT, pidff); @@ -1315,9 +1323,13 @@ hid_info(dev, "Force feedback for USB HID PID devices by Anssi Hannula \n"); + hid_device_io_stop(hid); + return 0; fail: + hid_device_io_stop(hid); + kfree(pidff); return error; }