aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/hid/hid-bigbenff.c
AgeCommit message (Collapse)Author
2020-03-21HID: hid-bigbenff: fix race condition for scheduled work during removalHanno Zulla
[ Upstream commit 4eb1b01de5b9d8596d6c103efcf1a15cfc1bedf7 ] It's possible that there is scheduled work left while the device is already being removed, which can cause a kernel crash. Adding a flag will avoid this. Signed-off-by: Hanno Zulla <kontakt@hanno.de> Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-03-21HID: hid-bigbenff: call hid_hw_stop() in case of errorHanno Zulla
[ Upstream commit 976a54d0f4202cb412a3b1fc7f117e1d97db35f3 ] It's required to call hid_hw_stop() once hid_hw_start() was called previously, so error cases need to handle this. Also, hid_hw_close() is not necessary during removal. Signed-off-by: Hanno Zulla <kontakt@hanno.de> Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-03-21HID: hid-bigbenff: fix general protection fault caused by double kfreeHanno Zulla
[ Upstream commit 789a2c250340666220fa74bc6c8f58497e3863b3 ] The struct *bigben was allocated via devm_kzalloc() and then used as a parameter in input_ff_create_memless(). This caused a double kfree during removal of the device, since both the managed resource API and ml_ff_destroy() in drivers/input/ff-memless.c would call kfree() on it. Signed-off-by: Hanno Zulla <kontakt@hanno.de> Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
2018-09-24HID: hid-bigbenff: driver for BigBen Interactive PS3OFMINIPAD gamepadHanno Zulla
This is a driver to fix input mapping and add LED & force feedback support for the "BigBen Interactive Kid-friendly Wired Controller PS3OFMINIPAD SONY" gamepad with USB id 146b:0902. It was originally sold as a PS3 accessory and makes a very nice gamepad for Retropie. Signed-off-by: Hanno Zulla <kontakt@hanno.de> Signed-off-by: Jiri Kosina <jkosina@suse.cz>