Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Input: xpad - add custom init packet for Xbox One S controllers

Sending [ 0x05, 0x20, 0x00, 0x0f, 0x06 ] packet for Xbox One S controllers
fixes an issue where controller is stuck in Bluetooth mode and not sending
any inputs.

Signed-off-by: Łukasz Patron <priv.luk@gmail.com>
Reviewed-by: Cameron Gutman <aicommander@gmail.com>
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/r/20200422075206.18229-1-priv.luk@gmail.com
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>

authored by

Łukasz Patron and committed by
Dmitry Torokhov
764f7f91 09264098

+12
+12
drivers/input/joystick/xpad.c
··· 459 459 }; 460 460 461 461 /* 462 + * This packet is required for Xbox One S (0x045e:0x02ea) 463 + * and Xbox One Elite Series 2 (0x045e:0x0b00) pads to 464 + * initialize the controller that was previously used in 465 + * Bluetooth mode. 466 + */ 467 + static const u8 xboxone_s_init[] = { 468 + 0x05, 0x20, 0x00, 0x0f, 0x06 469 + }; 470 + 471 + /* 462 472 * This packet is required for the Titanfall 2 Xbox One pads 463 473 * (0x0e6f:0x0165) to finish initialization and for Hori pads 464 474 * (0x0f0d:0x0067) to make the analog sticks work. ··· 526 516 XBOXONE_INIT_PKT(0x0e6f, 0x0165, xboxone_hori_init), 527 517 XBOXONE_INIT_PKT(0x0f0d, 0x0067, xboxone_hori_init), 528 518 XBOXONE_INIT_PKT(0x0000, 0x0000, xboxone_fw2015_init), 519 + XBOXONE_INIT_PKT(0x045e, 0x02ea, xboxone_s_init), 520 + XBOXONE_INIT_PKT(0x045e, 0x0b00, xboxone_s_init), 529 521 XBOXONE_INIT_PKT(0x0e6f, 0x0000, xboxone_pdp_init1), 530 522 XBOXONE_INIT_PKT(0x0e6f, 0x0000, xboxone_pdp_init2), 531 523 XBOXONE_INIT_PKT(0x24c6, 0x541a, xboxone_rumblebegin_init),