summaryrefslogtreecommitdiffstats
path: root/drivers/input
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2023-05-02 00:11:55 +0200
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2023-05-02 00:14:06 +0200
commit53bea86b5712c7491bb3dae12e271666df0a308c (patch)
tree19119be4f31a24e164a8cff1f7939a7843a4f491 /drivers/input
parentdt-bindings: input: pwm-beeper: convert to dt schema (diff)
downloadlinux-53bea86b5712c7491bb3dae12e271666df0a308c.tar.xz
linux-53bea86b5712c7491bb3dae12e271666df0a308c.zip
Revert "Input: xpad - fix support for some third-party controllers"
This reverts commit db7220c48d8d71476f881a7ae1285e1df4105409 because it causes crashes when trying to dereference xpad->dev->dev in xpad_probe() which has not been set up yet. Reported-by: syzbot+a3f758b8d8cb7e49afec@syzkaller.appspotmail.com Reported-by: Dongliang Mu <dzm91@hust.edu.cn> Link: https://groups.google.com/g/syzkaller-bugs/c/iMhTgpGuIbM Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to 'drivers/input')
-rw-r--r--drivers/input/joystick/xpad.c23
1 files changed, 0 insertions, 23 deletions
diff --git a/drivers/input/joystick/xpad.c b/drivers/input/joystick/xpad.c
index 138e4a9f341f..50ecff681b89 100644
--- a/drivers/input/joystick/xpad.c
+++ b/drivers/input/joystick/xpad.c
@@ -264,7 +264,6 @@ static const struct xpad_device {
{ 0x0f0d, 0x0067, "HORIPAD ONE", 0, XTYPE_XBOXONE },
{ 0x0f0d, 0x0078, "Hori Real Arcade Pro V Kai Xbox One", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOXONE },
{ 0x0f0d, 0x00c5, "Hori Fighting Commander ONE", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOXONE },
- { 0x0f0d, 0x00dc, "HORIPAD FPS for Nintendo Switch", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 },
{ 0x0f30, 0x010b, "Philips Recoil", 0, XTYPE_XBOX },
{ 0x0f30, 0x0202, "Joytech Advanced Controller", 0, XTYPE_XBOX },
{ 0x0f30, 0x8888, "BigBen XBMiniPad Controller", 0, XTYPE_XBOX },
@@ -2032,28 +2031,6 @@ static int xpad_probe(struct usb_interface *intf, const struct usb_device_id *id
goto err_free_in_urb;
}
- if (xpad->xtype == XTYPE_XBOX360) {
- /*
- * Some third-party controllers Xbox 360-style controllers
- * require this message to finish initialization.
- */
- u8 dummy[20];
-
- error = usb_control_msg_recv(udev, 0,
- /* bRequest */ 0x01,
- /* bmRequestType */
- USB_TYPE_VENDOR | USB_DIR_IN |
- USB_RECIP_INTERFACE,
- /* wValue */ 0x100,
- /* wIndex */ 0x00,
- dummy, sizeof(dummy),
- 25, GFP_KERNEL);
- if (error)
- dev_warn(&xpad->dev->dev,
- "unable to receive magic message: %d\n",
- error);
- }
-
ep_irq_in = ep_irq_out = NULL;
for (i = 0; i < 2; i++) {