aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPavel Rojtberg <rojtberg@gmail.com>2015-10-19 03:06:58 -0400
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2015-10-19 03:11:22 -0400
commitfbe6a3114471cccaeaeabfa56937731503ece545 (patch)
treeb592ae04804f7edd2b579dc52808344fae7d786d
parent9378c0251c7ac4b247177fb0c292a025ca1b751c (diff)
Input: xpad - fix clash of presence handling with LED setting
Do not call xpad_identify_controller at init with wireless devices: it conflicts with the already sent presence packet and will be called by xpad360w_process_packet as needed anyway. Signed-off-by: Pavel Rojtberg <rojtberg@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-rw-r--r--drivers/input/joystick/xpad.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/drivers/input/joystick/xpad.c b/drivers/input/joystick/xpad.c
index d382d48d6750..fd4100d56d8c 100644
--- a/drivers/input/joystick/xpad.c
+++ b/drivers/input/joystick/xpad.c
@@ -1001,8 +1001,15 @@ static int xpad_led_probe(struct usb_xpad *xpad)
1001 if (error) 1001 if (error)
1002 goto err_free_id; 1002 goto err_free_id;
1003 1003
1004 /* Light up the segment corresponding to controller number */ 1004 if (xpad->xtype == XTYPE_XBOX360) {
1005 xpad_identify_controller(xpad); 1005 /*
1006 * Light up the segment corresponding to controller
1007 * number on wired devices. On wireless we'll do that
1008 * when they respond to "presence" packet.
1009 */
1010 xpad_identify_controller(xpad);
1011 }
1012
1006 return 0; 1013 return 0;
1007 1014
1008err_free_id: 1015err_free_id: