summaryrefslogtreecommitdiff
path: root/drivers/input/joystick/xpad.c
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2017-09-15 09:52:21 -0700
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2017-09-15 09:52:21 -0700
commitbbc8608755da42e7494c00dce24a636007972def (patch)
tree7db003ee57a435042dedfa6664aef31c24922c04 /drivers/input/joystick/xpad.c
parenta6cbfa1e6d38c4b3ab0ce7e3aea4bb4e744f24b8 (diff)
parent697c5d8a36768b36729533fb44622b35d56d6ad0 (diff)
Merge branch 'next' into for-linus
Prepare second round of input updates for 4.14 merge window.
Diffstat (limited to 'drivers/input/joystick/xpad.c')
-rw-r--r--drivers/input/joystick/xpad.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/input/joystick/xpad.c b/drivers/input/joystick/xpad.c
index f8e34ef643c7..d86e59515b9c 100644
--- a/drivers/input/joystick/xpad.c
+++ b/drivers/input/joystick/xpad.c
@@ -1764,10 +1764,12 @@ static int xpad_probe(struct usb_interface *intf, const struct usb_device_id *id
struct usb_endpoint_descriptor *ep =
&intf->cur_altsetting->endpoint[i].desc;
- if (usb_endpoint_dir_in(ep))
- ep_irq_in = ep;
- else
- ep_irq_out = ep;
+ if (usb_endpoint_xfer_int(ep)) {
+ if (usb_endpoint_dir_in(ep))
+ ep_irq_in = ep;
+ else
+ ep_irq_out = ep;
+ }
}
if (!ep_irq_in || !ep_irq_out) {