linux-stable/drivers/input/joystick
Brenton Simpson 80441f76ee Input: xpad - add Lenovo Legion Go controllers
The Lenovo Legion Go is a handheld gaming system, similar to a Steam Deck.
It has a gamepad (including rear paddles), 3 gyroscopes, a trackpad,
volume buttons, a power button, and 2 LED ring lights.

The Legion Go firmware presents these controls as a USB hub with various
devices attached.  In its default state, the gamepad is presented as an
Xbox controller connected to this hub.  (By holding a combination of
buttons, it can be changed to use the older DirectInput API.)

This patch teaches the existing Xbox controller module `xpad` to bind to
the controller in the Legion Go, which enables support for the:

- directional pad,
- analog sticks (including clicks),
- X, Y, A, B,
- start and select (or menu and capture),
- shoulder buttons, and
- rumble.

The trackpad, touchscreen, volume controls, and power button are already
supported via existing kernel modules.  Two of the face buttons, the
gyroscopes, rear paddles, and LEDs are not.

After this patch lands, the Legion Go will be mostly functional in Linux,
out-of-the-box.  The various components of the USB hub can be synthesized
into a single logical controller (including the additional buttons) in
userspace with [Handheld Daemon](https://github.com/hhd-dev/hhd), which
makes the Go fully functional.

Signed-off-by: Brenton Simpson <appsforartists@google.com>
Link: https://lore.kernel.org/r/20240118183546.418064-1-appsforartists@google.com
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2024-01-30 14:20:55 -08:00
..
iforce Input: iforce - invert valid length check when fetching device IDs 2022-11-07 10:28:58 -08:00
a3d.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
adafruit-seesaw.c Input: driver for Adafruit Seesaw Gamepad 2024-01-09 23:45:19 -08:00
adc-joystick.c Input: adc-joystick - add polled input device support 2022-08-17 12:32:51 -07:00
adi.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
amijoy.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
analog.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
as5011.c Input: as5011 - convert to GPIO descriptor 2023-12-13 21:26:13 -08:00
cobra.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
db9.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
fsia6b.c treewide: Use fallthrough pseudo-keyword 2020-08-23 17:36:59 -05:00
gamecon.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
gf2k.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
grip.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
grip_mp.c treewide: Add SPDX license identifier for more missed files 2019-05-21 10:50:45 +02:00
guillemot.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
interact.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
joydump.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
Kconfig Input: driver for Adafruit Seesaw Gamepad 2024-01-09 23:45:19 -08:00
magellan.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
Makefile Input: driver for Adafruit Seesaw Gamepad 2024-01-09 23:45:19 -08:00
maplecontrol.c treewide: Add SPDX license identifier for more missed files 2019-05-21 10:50:45 +02:00
n64joy.c Input: n64joy - fix return value check in n64joy_probe() 2021-03-09 21:41:28 -08:00
psxpad-spi.c Input: pxspad - fix unused data warning when force feedback not enabled 2022-12-07 13:29:05 -08:00
pxrc.c Input: pxrc - simplify mutex handling with guard macro 2023-12-09 22:25:23 -08:00
qwiic-joystick.c Input: Switch i2c drivers back to use .probe() 2023-05-17 09:59:11 -07:00
sensehat-joystick.c Input: sensehat-joystick - remove unnecessary error message 2022-06-28 22:50:48 -07:00
sidewinder.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
spaceball.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
spaceorb.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
stinger.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
tmdc.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
turbografx.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
twidjoy.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
walkera0701.c Input: walkera0701 - use module_parport_driver macro to simplify the code 2023-10-29 02:56:46 +00:00
warrior.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
xpad.c Input: xpad - add Lenovo Legion Go controllers 2024-01-30 14:20:55 -08:00
zhenhua.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00