Skip to content

Commit 0cc82d6

Browse files
author
Jiri Kosina
committed
Merge branch 'for-5.16/nintendo' into for-linus
- support for Nintendo Switch Pro Controllers and Joy-Cons (Daniel J. Ogorchock)
2 parents a6be4c6 + daf11ca commit 0cc82d6

File tree

6 files changed

+2364
-0
lines changed

6 files changed

+2364
-0
lines changed

MAINTAINERS

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13253,6 +13253,12 @@ W: http://www.netlab.is.tsukuba.ac.jp/~yokota/izumi/ninja/
1325313253
F: Documentation/scsi/NinjaSCSI.rst
1325413254
F: drivers/scsi/nsp32*
1325513255

13256+
NINTENDO HID DRIVER
13257+
M: Daniel J. Ogorchock <[email protected]>
13258+
13259+
S: Maintained
13260+
F: drivers/hid/hid-nintendo*
13261+
1325613262
NIOS2 ARCHITECTURE
1325713263
M: Dinh Nguyen <[email protected]>
1325813264
S: Maintained

drivers/hid/Kconfig

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -731,6 +731,30 @@ config HID_MULTITOUCH
731731
To compile this driver as a module, choose M here: the
732732
module will be called hid-multitouch.
733733

734+
config HID_NINTENDO
735+
tristate "Nintendo Joy-Con and Pro Controller support"
736+
depends on HID
737+
depends on NEW_LEDS
738+
depends on LEDS_CLASS
739+
select POWER_SUPPLY
740+
help
741+
Adds support for the Nintendo Switch Joy-Cons and Pro Controller.
742+
All controllers support bluetooth, and the Pro Controller also supports
743+
its USB mode.
744+
745+
To compile this driver as a module, choose M here: the
746+
module will be called hid-nintendo.
747+
748+
config NINTENDO_FF
749+
bool "Nintendo Switch controller force feedback support"
750+
depends on HID_NINTENDO
751+
select INPUT_FF_MEMLESS
752+
help
753+
Say Y here if you have a Nintendo Switch controller and want to enable
754+
force feedback support for it. This works for both joy-cons and the pro
755+
controller. For the pro controller, both rumble motors can be controlled
756+
individually.
757+
734758
config HID_NTI
735759
tristate "NTI keyboard adapters"
736760
help

drivers/hid/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@ obj-$(CONFIG_HID_MAYFLASH) += hid-mf.o
7878
obj-$(CONFIG_HID_MICROSOFT) += hid-microsoft.o
7979
obj-$(CONFIG_HID_MONTEREY) += hid-monterey.o
8080
obj-$(CONFIG_HID_MULTITOUCH) += hid-multitouch.o
81+
obj-$(CONFIG_HID_NINTENDO) += hid-nintendo.o
8182
obj-$(CONFIG_HID_NTI) += hid-nti.o
8283
obj-$(CONFIG_HID_NTRIG) += hid-ntrig.o
8384
obj-$(CONFIG_HID_ORTEK) += hid-ortek.o

drivers/hid/hid-ids.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -918,6 +918,10 @@
918918
#define USB_VENDOR_ID_NINTENDO 0x057e
919919
#define USB_DEVICE_ID_NINTENDO_WIIMOTE 0x0306
920920
#define USB_DEVICE_ID_NINTENDO_WIIMOTE2 0x0330
921+
#define USB_DEVICE_ID_NINTENDO_JOYCONL 0x2006
922+
#define USB_DEVICE_ID_NINTENDO_JOYCONR 0x2007
923+
#define USB_DEVICE_ID_NINTENDO_PROCON 0x2009
924+
#define USB_DEVICE_ID_NINTENDO_CHRGGRIP 0x200E
921925

922926
#define USB_VENDOR_ID_NOVATEK 0x0603
923927
#define USB_DEVICE_ID_NOVATEK_PCT 0x0600

0 commit comments

Comments
 (0)