pxa/hx4700: Add Synaptics NavPoint (PXA27x SSP/SPI) driver
Subsystems (5)
PATCH v4 1/2 pxa/hx4700: Add Synaptics NavPoint (PXA27x SSP/SPI) driver
Add support for the Synaptics NavPoint touchpad connected to a PXA27x SSP port in SPI slave mode. The driver implements a simple navigation pad. The four raised dots are mapped to UP/DOWN/LEFT/RIGHT buttons and the centre of the touchpad is mapped to the ENTER button.
Signed-off-by Paul Parsons <[email protected]>
---
V4:
Fixed dev argument to dev_warn() calls.
Made navpoint_suspend() and navpoint_resume() static.
Moved msleep() loop to before gpio_set_value(1) (NavPoint power on). Added timeout to msleep() loop.
Tweaked kzalloc() sizeof argument.
Moved request_irq() call to after platform_set_drvdata(). Removed (void) casts from navpoint_suspend() and navpoint_resume() calls.
arch/arm/mach-pxa/include/mach/mfp-pxa27x.h +1 -0
@@ -206,6 +206,7 @@#define GPIO113_I2S_SYSCLK MFP_CFG_OUT(GPIO113, AF1, DRIVE_LOW)/* SSP 1 */ +#define GPIO23_SSP1_SCLK_IN MFP_CFG_IN(GPIO23, AF2)#define GPIO23_SSP1_SCLK MFP_CFG_OUT(GPIO23, AF2, DRIVE_LOW)#define GPIO29_SSP1_SCLK MFP_CFG_IN(GPIO29, AF3)#define GPIO27_SSP1_SYSCLK MFP_CFG_OUT(GPIO27, AF1, DRIVE_LOW)
drivers/input/mouse/Kconfig +9 -0
@@ -322,4 +322,13 @@ config MOUSE_SYNAPTICS_I2C To compile this driver as a module, choose M here: the module will be called synaptics_i2c. +config MOUSE_NAVPOINT_PXA27x + tristate "Synaptics NavPoint (PXA27x SSP/SPI)" + depends on PXA27x && PXA_SSP + help + This option enables support for the Synaptics NavPoint connected to + a PXA27x SSP port in SPI slave mode. The driver implements a simple + navigation pad. The four raised dots are mapped to UP/DOWN/LEFT/RIGHT + buttons and the centre of the touchpad is mapped to the ENTER button. + endif
drivers/input/mouse/Makefile +1 -0
@@ -12,6 +12,7 @@ obj-$(CONFIG_MOUSE_GPIO) += gpio_mouse. obj-$(CONFIG_MOUSE_INPORT) += inport.o obj-$(CONFIG_MOUSE_LOGIBM) += logibm.o obj-$(CONFIG_MOUSE_MAPLE) += maplemouse.o +obj-$(CONFIG_MOUSE_NAVPOINT_PXA27x) += navpoint.o obj-$(CONFIG_MOUSE_PC110PAD) += pc110pad.o obj-$(CONFIG_MOUSE_PS2) += psmouse.o obj-$(CONFIG_MOUSE_PXA930_TRKBALL) += pxa930_trkball.o
drivers/input/mouse/navpoint.c +330 -0
330 lines not on this page · raw message
include/linux/input/navpoint.h +12 -0
@@ -0,0 +1,12 @@ +/* +* Copyright (C) 2011 Paul Parsons <[email protected]> +* +* This program is free software; you can redistribute it and/or modify +* it under the terms of the GNU General Public License version 2 as +* published by the Free Software Foundation. +*/ + +struct navpoint_platform_data { +int port;/* PXA SSP port for pxa_ssp_request() */ +int gpio;/* GPIO for power on/off */ +};