This patch implements support for the joystick.
It supports left/right/up/down/enter and is
attached via i2c and a gpio pin for irq.
Signed-off-by: Charles Mirabile <cmirabil@xxxxxxxxxx>
Signed-off-by: Mwesigwa Guma <mguma@xxxxxxxxxx>
Signed-off-by: Joel Savitz <jsavitz@xxxxxxxxxx>
---
drivers/input/joystick/Kconfig | 8 ++
drivers/input/joystick/Makefile | 1 +
drivers/input/joystick/sensehat-joystick.c | 135 +++++++++++++++++++++
3 files changed, 144 insertions(+)
create mode 100644 drivers/input/joystick/sensehat-joystick.c
diff --git a/drivers/input/joystick/Kconfig b/drivers/input/joystick/Kconfig
index 3b23078bc7b5..d2f78353b74c 100644
--- a/drivers/input/joystick/Kconfig
+++ b/drivers/input/joystick/Kconfig
@@ -399,4 +399,12 @@ config JOYSTICK_N64
Say Y here if you want enable support for the four
built-in controller ports on the Nintendo 64 console.
+config JOYSTICK_SENSEHAT
+ tristate "Raspberry Pi Sense HAT joystick"
+ depends on GPIOLIB && INPUT
+ select MFD_SENSEHAT_CORE
+
+ help
+ This is the joystick driver for the Raspberry Pi Sense HAT
+
endif