Input: xpad - set the LEDs properly on XBox Wireless controllers
authorPierre-Loup A. Griffais <pgriffais@valvesoftware.com>
Mon, 22 Jun 2015 21:10:36 +0000 (14:10 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 1 Dec 2018 08:48:00 +0000 (09:48 +0100)
commit30221037921b3d4e659579cb4fa58d938f8364b0
treea0675d84b3acb1b9a11b3758e72579025a362e7b
parent70d7e0cb424806267aea2a2deff8165f115957c6
Input: xpad - set the LEDs properly on XBox Wireless controllers

[ Upstream commit 75b7f05d2798ee3a1cc5bbdd54acd0e318a80396 ]

Based on Patch by Pierre-Loup A. Griffais <pgriffais@valvesoftware.com>:
Add the logic to set the LEDs on XBox Wireless controllers.  Command
sequence found by sniffing the Windows data stream when plugging the
device in.

Updated based on comments on linux-input:
unify codepaths in xpad_send_led_command for wired/ wireless controller.
Also document command values for clarification.
All values tested on Xbox 360 Wireless Controller.

Signed-off-by: Pavel Rojtberg <rojtberg@gmail.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/input/joystick/xpad.c