* [PATCH] Input: xpad - Add custom init packet for Xbox One S controllers [not found] <92b71dc5-ddd5-7ffd-65f8-65a6610dfe43@gmail.com> @ 2020-04-22 7:46 ` LuK1337 2020-04-22 7:52 ` LuK1337 1 sibling, 0 replies; 4+ messages in thread From: LuK1337 @ 2020-04-22 7:46 UTC (permalink / raw) Cc: Cameron Gutman, Łukasz Patron, stable, Dmitry Torokhov, Greg Kroah-Hartman, Allison Randal, Thomas Gleixner, Richard Fontana, linux-input, linux-kernel From: Łukasz Patron <priv.luk@gmail.com> Sending [ 0x05, 0x20, 0x02, 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> Cc: stable@vger.kernel.org --- drivers/input/joystick/xpad.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/drivers/input/joystick/xpad.c b/drivers/input/joystick/xpad.c index 6b40a1c68f9f..c77cdb3b62b5 100644 --- a/drivers/input/joystick/xpad.c +++ b/drivers/input/joystick/xpad.c @@ -458,6 +458,16 @@ static const u8 xboxone_fw2015_init[] = { 0x05, 0x20, 0x00, 0x01, 0x00 }; +/* + * This packet is required for Xbox One S (0x045e:0x02ea) + * and Xbox One Elite Series 2 (0x045e:0x0b00) pads to + * initialize the controller that was previously used in + * Bluetooth mode. + */ +static const u8 xboxone_s_init[] = { + 0x05, 0x20, 0x00, 0x0f, 0x06 +}; + /* * This packet is required for the Titanfall 2 Xbox One pads * (0x0e6f:0x0165) to finish initialization and for Hori pads @@ -516,6 +526,8 @@ static const struct xboxone_init_packet xboxone_init_packets[] = { XBOXONE_INIT_PKT(0x0e6f, 0x0165, xboxone_hori_init), XBOXONE_INIT_PKT(0x0f0d, 0x0067, xboxone_hori_init), XBOXONE_INIT_PKT(0x0000, 0x0000, xboxone_fw2015_init), + XBOXONE_INIT_PKT(0x045e, 0x02ea, xboxone_s_init), + XBOXONE_INIT_PKT(0x045e, 0x0b00, xboxone_s_init), XBOXONE_INIT_PKT(0x0e6f, 0x0000, xboxone_pdp_init1), XBOXONE_INIT_PKT(0x0e6f, 0x0000, xboxone_pdp_init2), XBOXONE_INIT_PKT(0x24c6, 0x541a, xboxone_rumblebegin_init), -- 2.26.0 ^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH] Input: xpad - Add custom init packet for Xbox One S controllers [not found] <92b71dc5-ddd5-7ffd-65f8-65a6610dfe43@gmail.com> 2020-04-22 7:46 ` [PATCH] Input: xpad - Add custom init packet for Xbox One S controllers LuK1337 @ 2020-04-22 7:52 ` LuK1337 2020-04-22 17:20 ` Cameron Gutman 1 sibling, 1 reply; 4+ messages in thread From: LuK1337 @ 2020-04-22 7:52 UTC (permalink / raw) Cc: Cameron Gutman, Łukasz Patron, stable, Dmitry Torokhov, Thomas Gleixner, Allison Randal, Greg Kroah-Hartman, Richard Fontana, linux-input, linux-kernel From: Łukasz Patron <priv.luk@gmail.com> 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> Cc: stable@vger.kernel.org --- drivers/input/joystick/xpad.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/drivers/input/joystick/xpad.c b/drivers/input/joystick/xpad.c index 6b40a1c68f9f..c77cdb3b62b5 100644 --- a/drivers/input/joystick/xpad.c +++ b/drivers/input/joystick/xpad.c @@ -458,6 +458,16 @@ static const u8 xboxone_fw2015_init[] = { 0x05, 0x20, 0x00, 0x01, 0x00 }; +/* + * This packet is required for Xbox One S (0x045e:0x02ea) + * and Xbox One Elite Series 2 (0x045e:0x0b00) pads to + * initialize the controller that was previously used in + * Bluetooth mode. + */ +static const u8 xboxone_s_init[] = { + 0x05, 0x20, 0x00, 0x0f, 0x06 +}; + /* * This packet is required for the Titanfall 2 Xbox One pads * (0x0e6f:0x0165) to finish initialization and for Hori pads @@ -516,6 +526,8 @@ static const struct xboxone_init_packet xboxone_init_packets[] = { XBOXONE_INIT_PKT(0x0e6f, 0x0165, xboxone_hori_init), XBOXONE_INIT_PKT(0x0f0d, 0x0067, xboxone_hori_init), XBOXONE_INIT_PKT(0x0000, 0x0000, xboxone_fw2015_init), + XBOXONE_INIT_PKT(0x045e, 0x02ea, xboxone_s_init), + XBOXONE_INIT_PKT(0x045e, 0x0b00, xboxone_s_init), XBOXONE_INIT_PKT(0x0e6f, 0x0000, xboxone_pdp_init1), XBOXONE_INIT_PKT(0x0e6f, 0x0000, xboxone_pdp_init2), XBOXONE_INIT_PKT(0x24c6, 0x541a, xboxone_rumblebegin_init), -- 2.26.0 ^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] Input: xpad - Add custom init packet for Xbox One S controllers 2020-04-22 7:52 ` LuK1337 @ 2020-04-22 17:20 ` Cameron Gutman 2020-04-22 21:13 ` Dmitry Torokhov 0 siblings, 1 reply; 4+ messages in thread From: Cameron Gutman @ 2020-04-22 17:20 UTC (permalink / raw) To: LuK1337 Cc: stable, Dmitry Torokhov, Thomas Gleixner, Allison Randal, Greg Kroah-Hartman, Richard Fontana, linux-input, linux-kernel On 4/22/20 12:52 AM, LuK1337 wrote: > From: Łukasz Patron <priv.luk@gmail.com> > > 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> > Cc: stable@vger.kernel.org LGTM. Tested working on both of my Xbox One S gamepads: - idVendor=045e, idProduct=02ea, bcdDevice= 3.01 - idVendor=045e, idProduct=02ea, bcdDevice= 4.08 Reviewed-by: Cameron Gutman <aicommander@gmail.com> > --- > drivers/input/joystick/xpad.c | 12 ++++++++++++ > 1 file changed, 12 insertions(+) > > diff --git a/drivers/input/joystick/xpad.c b/drivers/input/joystick/xpad.c > index 6b40a1c68f9f..c77cdb3b62b5 100644 > --- a/drivers/input/joystick/xpad.c > +++ b/drivers/input/joystick/xpad.c > @@ -458,6 +458,16 @@ static const u8 xboxone_fw2015_init[] = { > 0x05, 0x20, 0x00, 0x01, 0x00 > }; > > +/* > + * This packet is required for Xbox One S (0x045e:0x02ea) > + * and Xbox One Elite Series 2 (0x045e:0x0b00) pads to > + * initialize the controller that was previously used in > + * Bluetooth mode. > + */ > +static const u8 xboxone_s_init[] = { > + 0x05, 0x20, 0x00, 0x0f, 0x06 > +}; > + > /* > * This packet is required for the Titanfall 2 Xbox One pads > * (0x0e6f:0x0165) to finish initialization and for Hori pads > @@ -516,6 +526,8 @@ static const struct xboxone_init_packet xboxone_init_packets[] = { > XBOXONE_INIT_PKT(0x0e6f, 0x0165, xboxone_hori_init), > XBOXONE_INIT_PKT(0x0f0d, 0x0067, xboxone_hori_init), > XBOXONE_INIT_PKT(0x0000, 0x0000, xboxone_fw2015_init), > + XBOXONE_INIT_PKT(0x045e, 0x02ea, xboxone_s_init), > + XBOXONE_INIT_PKT(0x045e, 0x0b00, xboxone_s_init), > XBOXONE_INIT_PKT(0x0e6f, 0x0000, xboxone_pdp_init1), > XBOXONE_INIT_PKT(0x0e6f, 0x0000, xboxone_pdp_init2), > XBOXONE_INIT_PKT(0x24c6, 0x541a, xboxone_rumblebegin_init), > ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] Input: xpad - Add custom init packet for Xbox One S controllers 2020-04-22 17:20 ` Cameron Gutman @ 2020-04-22 21:13 ` Dmitry Torokhov 0 siblings, 0 replies; 4+ messages in thread From: Dmitry Torokhov @ 2020-04-22 21:13 UTC (permalink / raw) To: Cameron Gutman Cc: LuK1337, stable, Thomas Gleixner, Allison Randal, Greg Kroah-Hartman, Richard Fontana, linux-input, linux-kernel On Wed, Apr 22, 2020 at 10:20:08AM -0700, Cameron Gutman wrote: > On 4/22/20 12:52 AM, LuK1337 wrote: > > From: Łukasz Patron <priv.luk@gmail.com> > > > > 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> > > Cc: stable@vger.kernel.org > > LGTM. Tested working on both of my Xbox One S gamepads: > - idVendor=045e, idProduct=02ea, bcdDevice= 3.01 > - idVendor=045e, idProduct=02ea, bcdDevice= 4.08 > > Reviewed-by: Cameron Gutman <aicommander@gmail.com> Applied, thank you. > > > --- > > drivers/input/joystick/xpad.c | 12 ++++++++++++ > > 1 file changed, 12 insertions(+) > > > > diff --git a/drivers/input/joystick/xpad.c b/drivers/input/joystick/xpad.c > > index 6b40a1c68f9f..c77cdb3b62b5 100644 > > --- a/drivers/input/joystick/xpad.c > > +++ b/drivers/input/joystick/xpad.c > > @@ -458,6 +458,16 @@ static const u8 xboxone_fw2015_init[] = { > > 0x05, 0x20, 0x00, 0x01, 0x00 > > }; > > > > +/* > > + * This packet is required for Xbox One S (0x045e:0x02ea) > > + * and Xbox One Elite Series 2 (0x045e:0x0b00) pads to > > + * initialize the controller that was previously used in > > + * Bluetooth mode. > > + */ > > +static const u8 xboxone_s_init[] = { > > + 0x05, 0x20, 0x00, 0x0f, 0x06 > > +}; > > + > > /* > > * This packet is required for the Titanfall 2 Xbox One pads > > * (0x0e6f:0x0165) to finish initialization and for Hori pads > > @@ -516,6 +526,8 @@ static const struct xboxone_init_packet xboxone_init_packets[] = { > > XBOXONE_INIT_PKT(0x0e6f, 0x0165, xboxone_hori_init), > > XBOXONE_INIT_PKT(0x0f0d, 0x0067, xboxone_hori_init), > > XBOXONE_INIT_PKT(0x0000, 0x0000, xboxone_fw2015_init), > > + XBOXONE_INIT_PKT(0x045e, 0x02ea, xboxone_s_init), > > + XBOXONE_INIT_PKT(0x045e, 0x0b00, xboxone_s_init), > > XBOXONE_INIT_PKT(0x0e6f, 0x0000, xboxone_pdp_init1), > > XBOXONE_INIT_PKT(0x0e6f, 0x0000, xboxone_pdp_init2), > > XBOXONE_INIT_PKT(0x24c6, 0x541a, xboxone_rumblebegin_init), > > > -- Dmitry ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2020-04-22 21:13 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <92b71dc5-ddd5-7ffd-65f8-65a6610dfe43@gmail.com>
2020-04-22 7:46 ` [PATCH] Input: xpad - Add custom init packet for Xbox One S controllers LuK1337
2020-04-22 7:52 ` LuK1337
2020-04-22 17:20 ` Cameron Gutman
2020-04-22 21:13 ` Dmitry Torokhov
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).