Thread (34 messages) 34 messages, 5 authors, 2014-03-24

Re: [PATCH 04/15] iio: adc: at91_adc: Add support for touchscreens without TSMR

From: Alexandre Belloni <hidden>
Date: 2014-03-16 19:16:44
Also in: linux-arm-kernel, linux-iio, lkml

On 16/03/2014 at 18:16:54 +0000, Jonathan Cameron wrote :
On 05/03/14 17:35, Alexandre Belloni wrote:
quoted
Old ADCs, as present on the sam9rl and the sam9g45 don't have a TSMR register
and the touchscreen support should be handled differently.

Signed-off-by: Alexandre Belloni <alexandre.belloni-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
One comment inline about handling of devices where the platform data doesn't
include the touchscreen type.  I'd expect zero to be the current default
rather than NONE...
quoted
diff --git a/include/linux/platform_data/at91_adc.h b/include/linux/platform_data/at91_adc.h
index fcf73879dbfe..7819fc787731 100644
--- a/include/linux/platform_data/at91_adc.h
+++ b/include/linux/platform_data/at91_adc.h
@@ -7,6 +7,12 @@
 #ifndef _AT91_ADC_H_
 #define _AT91_ADC_H_

+enum atmel_adc_ts_type {
This means that the default for existing touch screens (where the platform
data won't include setting this value) will be none.  Is that correct?
quoted
+	ATMEL_ADC_TOUCHSCREEN_NONE = 0,
+	ATMEL_ADC_TOUCHSCREEN_4WIRE = 4,
+	ATMEL_ADC_TOUCHSCREEN_5WIRE = 5,
+};
+
This is actually just a snippet that I moved from at91_adc.c to
at91_adc.h. I followed the current behavior.  Until now, using the
touchscreen was only supported through device tree and touchscreen
handling was not activated unless the atmel,adc-ts-wires property is
present.  I guess this is the sane way to go because when you use the
touchscreen, you lose the triggers.


-- 
Alexandre Belloni, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help