Skip to contentSkip to conversation

Touch: DA9052/53 touch screen driver v2

PATCH Applied Ashish Jangam 2 participants 5 messages Apr 20, 2012 – Apr 30, 2012

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Touch: DA9052/53 touch screen driver v2

This driver adds support for DA9052/53 4-wire resistive ADC interfaced touchscreen controller.

DA9052/53 is a MFD therefore this driver depends on DA9052/53 core driver for core functionalities.

This patch is functionally tested on Samsung SMDKV6410 and i.mx53 loco.

---
Changes since V2:
- Fix for race & sync condition

---
 drivers/input/touchscreen/Kconfig      |    7 +
 drivers/input/touchscreen/Makefile     |    1 +
 drivers/input/touchscreen/da9052_tsi.c |  373 ++++++++++++++++++++++++++++++++
 3 files changed, 381 insertions(+), 0 deletions(-)
drivers/input/touchscreen/Kconfig +7 -0
index ba7c565..8538abe 100644
@@ -187,6 +187,13 @@ config TOUCHSCREEN_DA9034
 	  Say Y here to enable the support for the touchscreen found
 	  on Dialog Semiconductor DA9034 PMIC.
 
+config TOUCHSCREEN_DA9052
+	tristate "Dialog DA9052/DA9053 TSI"
+	depends on PMIC_DA9052
+	help
+	  Say y here to support the touchscreen found on Dialog Semiconductor
+	  DA9052-BC and DA9053-AA/Bx PMICs.
+
 config TOUCHSCREEN_DYNAPRO
 	tristate "Dynapro serial touchscreen"
 	select SERIO
drivers/input/touchscreen/Makefile +1 -0
index 7cca7dd..eb8bfe1 100644
@@ -22,6 +22,7 @@ obj-$(CONFIG_TOUCHSCREEN_CYTTSP_CORE)	+= cyttsp_core.o
 obj-$(CONFIG_TOUCHSCREEN_CYTTSP_I2C)	+= cyttsp_i2c.o
 obj-$(CONFIG_TOUCHSCREEN_CYTTSP_SPI)	+= cyttsp_spi.o
 obj-$(CONFIG_TOUCHSCREEN_DA9034)	+= da9034-ts.o
+obj-$(CONFIG_TOUCHSCREEN_DA9052)	+= da9052_tsi.o
 obj-$(CONFIG_TOUCHSCREEN_DYNAPRO)	+= dynapro.o
 obj-$(CONFIG_TOUCHSCREEN_HAMPSHIRE)	+= hampshire.o
 obj-$(CONFIG_TOUCHSCREEN_GUNZE)		+= gunze.o
drivers/input/touchscreen/da9052_tsi.c new file +373 -0

373 lines not on this page · raw message

maintainer
#1 lore raw

Hi Ashish,

drivers/input/touchscreen/da9052_tsi.c line 49

Quoted 8 lines · Ashish Jangam
drivers/input/touchscreen/da9052_tsi.c new file +8 -0
+static irqreturn_t da9052_ts_pendwn_irq(int irq, void *data)
+{
+	struct da9052_tsi *tsi = data;
+
+	if (!tsi->stopped) {
+		/* Mask PEN_DOWN event and unmask TSI_READY event */
+		disable_irq_nosync(tsi->da9052->irq_base + tsi->irq_pendwn);
+		enable_irq(tsi->da9052->irq_base + tsi->irq_datardy);

Why did you switch to using irq_base here? da9052_onkey driver does not do that, should it?

Thanks.

Signature · 1 line
Dmitry
#2 lore raw
Quoted 12 lines · Ashish Jangam

drivers/input/touchscreen/da9052_tsi.c line 49

Quoted 8 lines
drivers/input/touchscreen/da9052_tsi.c new file +8 -0
+static irqreturn_t da9052_ts_pendwn_irq(int irq, void *data)
+{
+	struct da9052_tsi *tsi = data;
+
+	if (!tsi->stopped) {
+		/* Mask PEN_DOWN event and unmask TSI_READY event */
+		disable_irq_nosync(tsi->da9052->irq_base + tsi->irq_pendwn);
+		enable_irq(tsi->da9052->irq_base + tsi->irq_datardy);

Why did you switch to using irq_base here? da9052_onkey driver does not do that, should it?

On i.mx53 loco board irq_base was required so to keep driver working across boards this was introduced. Need to fix this in onkey driver.

Quoted 5 lines

Thanks.

--
Dmitry

#3 lore raw
In reply to Dmitry Torokhov
Quoted 7 lines
Quoted 3 lines · Ashish Jangam

Why did you switch to using irq_base here? da9052_onkey driver does not do that, should it?

On i.mx53 loco board irq_base was required so to keep driver working across boards this was introduced. Need to fix this in onkey driver.

Quoted 2 lines

Thanks.

If the patch looks good then please ACK it.

maintainer Applied
#4 lore raw
Quoted 8 lines · Ashish Jangam
Quoted 7 lines
Quoted 3 lines · Ashish Jangam

Why did you switch to using irq_base here? da9052_onkey driver does not do that, should it?

On i.mx53 loco board irq_base was required so to keep driver working across boards this was introduced. Need to fix this in onkey driver.

Quoted 2 lines

Thanks.

If the patch looks good then please ACK it.

Applied to the 3.5 queue, thank you.

Signature · 1 line
Dmitry