Re: [PATCH V2] Input: xpad - Add HyperX Clutch Gladiate Support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 24 Jul, 2023 15:49:05 -0700 HP Dev <hphyperxdev@xxxxxxxxx> wrote:
> Add HyperX controller support to xpad_device and xpad_table.
>
> Suggested-by: Chris Toledanes <chris.toledanes@xxxxxx>
> Reviewed-by: Carl Ng <carl.ng@xxxxxx>
> Signed-off-by: Max Nguyen <maxwell.nguyen@xxxxxx>
> ---
> V1 -> V2: Remove Xbox 360 vendor-specific class support.

Thanks for making this change. I think it makes sense. I think if we
want to have universal support for probing both Xbox 360 and Xbox One
controller devices for a single vendorId in the xpad driver, the
XPAD_XBOX360_VENDOR and XPAD_XBOXONE_VENDOR macros would be consolidated
(one macro that instantiates support for both protocols). Since no
HyperX controller for supporting Xbox 360 exists currently, I do not
think it makes sense to introduce XPAD_XBOX360_VENDOR vendor-specific
class matching for the HyperX vendorId in this patch (what v2 resolves).

>
>  drivers/input/joystick/xpad.c | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/drivers/input/joystick/xpad.c b/drivers/input/joystick/xpad.c
> index cdb193317c3b..1e377d040c43 100644
> --- a/drivers/input/joystick/xpad.c
> +++ b/drivers/input/joystick/xpad.c
> @@ -130,6 +130,7 @@ static const struct xpad_device {
>  	{ 0x0079, 0x18d4, "GPD Win 2 X-Box Controller", 0, XTYPE_XBOX360 },
>  	{ 0x03eb, 0xff01, "Wooting One (Legacy)", 0, XTYPE_XBOX360 },
>  	{ 0x03eb, 0xff02, "Wooting Two (Legacy)", 0, XTYPE_XBOX360 },
> +	{ 0x03f0, 0x0495, "HyperX Clutch Gladiate", 0, XTYPE_XBOXONE },
>  	{ 0x044f, 0x0f00, "Thrustmaster Wheel", 0, XTYPE_XBOX },
>  	{ 0x044f, 0x0f03, "Thrustmaster Wheel", 0, XTYPE_XBOX },
>  	{ 0x044f, 0x0f07, "Thrustmaster, Inc. Controller", 0, XTYPE_XBOX },
> @@ -457,6 +458,7 @@ static const struct usb_device_id xpad_table[] = {
>  	{ USB_INTERFACE_INFO('X', 'B', 0) },	/* Xbox USB-IF not-approved class */
>  	XPAD_XBOX360_VENDOR(0x0079),		/* GPD Win 2 controller */
>  	XPAD_XBOX360_VENDOR(0x03eb),		/* Wooting Keyboards (Legacy) */
> +	XPAD_XBOXONE_VENDOR(0x03f0),		/* HP HyperX Xbox One controllers */
>  	XPAD_XBOX360_VENDOR(0x044f),		/* Thrustmaster Xbox 360 controllers */
>  	XPAD_XBOX360_VENDOR(0x045e),		/* Microsoft Xbox 360 controllers */
>  	XPAD_XBOXONE_VENDOR(0x045e),		/* Microsoft Xbox One controllers */

Reviewed-by: Rahul Rameshbabu <rrameshbabu@xxxxxxxxxx>



[Index of Archives]     [Linux Media Devel]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Linux Wireless Networking]     [Linux Omap]

  Powered by Linux