linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rob Herring <robh-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
To: "H. Nikolaus Schaller" <hns-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>
Cc: "Dmitry Torokhov"
	<dmitry.torokhov-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
	"Mark Rutland" <mark.rutland-5wv7dgnIgG8@public.gmane.org>,
	"Benoît Cousson"
	<bcousson-rdvid1DuHRBWk0Htik3J/w@public.gmane.org>,
	"Tony Lindgren" <tony-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org>,
	"Russell King" <linux-I+IVW8TIWO2tmTQ+vhA3Yw@public.gmane.org>,
	"Arnd Bergmann" <arnd-r2nGTMty4D4@public.gmane.org>,
	"Michael Welling" <mwelling-EkmVulN54Sk@public.gmane.org>,
	"Mika Penttilä"
	<mika.penttila-MRsr7dthA9VWk0Htik3J/w@public.gmane.org>,
	"Javier Martinez Canillas"
	<javier-JPH+aEBZ4P+UEJcrhfAQsw@public.gmane.org>,
	"Igor Grinberg"
	<grinberg-UTxiZqZC01RS1MOuV/RT9w@public.gmane.org>,
	"Sebastian Reichel" <sre-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
	"Andrew F. Davis" <afd-l0cyMroinI0@public.gmane.org>,
	linux-input-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	letux-kernel-S0jZdbWzriLCfDggNXIi3w@public.gmane.org,
	linux-iio-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH v3 1/8] drivers:input:tsc2007: add new common binding names, pre-calibration, flipping and rotation
Date: Fri, 23 Sep 2016 17:47:26 -0500	[thread overview]
Message-ID: <20160923224726.GA4639@rob-hp-laptop> (raw)
In-Reply-To: <1409ed9845f17445a8a67bd6fb16c902c3e4f69c.1474634475.git.hns-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>

On Fri, Sep 23, 2016 at 02:41:09PM +0200, H. Nikolaus Schaller wrote:
> commit b98abe52fa8e ("Input: add common DT binding for touchscreens")
> introduced common DT bindings for touchscreens [1] and a helper function to
> parse the DT.
> 
> commit ed7c9870c9bc ("Input: of_touchscreen - add support for inverted / swapped axes")
> added another helper for parsing axis inversion and swapping
> and applying them to x and y coordinates.
> 
> Both helpers have been integrated to accommodate any orientation of the
> touch panel in relation to the LCD.
> 
> A new feature is to introduce scaling the min/max ADC values to the screen
> size.
> 
> This makes it possible to pre-calibrate the touch so that is (almost)
> exactly matches the LCD pixel coordinates it is glued onto. This allows to
> well enough operate the touch before a user space calibration step can
> improve the precision.
> 
> Finally, calculate_pressure has been renamed to calculate_resistance
> because that is what it is doing.

Seems like you are breaking compatibility with old DTs. I can't tell for 
sure though.

> 
> [1]: Documentation/devicetree/bindings/input/touchscreen/touchscreen.txt
> 
> Signed-off-by: H. Nikolaus Schaller <hns-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>
> ---
>  .../bindings/input/touchscreen/tsc2007.txt         |  20 ++--
>  drivers/input/touchscreen/tsc2007.c                | 126 +++++++++++++++++----
>  include/linux/i2c/tsc2007.h                        |   8 ++
>  3 files changed, 123 insertions(+), 31 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/input/touchscreen/tsc2007.txt b/Documentation/devicetree/bindings/input/touchscreen/tsc2007.txt
> index ec365e1..6e9fd55 100644
> --- a/Documentation/devicetree/bindings/input/touchscreen/tsc2007.txt
> +++ b/Documentation/devicetree/bindings/input/touchscreen/tsc2007.txt
> @@ -6,6 +6,7 @@ Required properties:
>  - ti,x-plate-ohms: X-plate resistance in ohms.
>  
>  Optional properties:
> +- generic touch screen properties: see touchscreen binding [2].
>  - gpios: the interrupt gpio the chip is connected to (trough the penirq pin).
>    The penirq pin goes to low when the panel is touched.
>    (see GPIO binding[1] for more details).
> @@ -13,17 +14,20 @@ Optional properties:
>    (see interrupt binding[0]).
>  - interrupts: (gpio) interrupt to which the chip is connected
>    (see interrupt binding[0]).
> -- ti,max-rt: maximum pressure.
> -- ti,fuzzx: specifies the absolute input fuzz x value.
> -  If set, it will permit noise in the data up to +- the value given to the fuzz
> -  parameter, that is used to filter noise from the event stream.
> -- ti,fuzzy: specifies the absolute input fuzz y value.
> -- ti,fuzzz: specifies the absolute input fuzz z value.
> +- ti,max-rt: maximum pressure resistance above which samples are ignored
> +  (default: 4095).
> +- ti,report-resistance: report resistance (no pressure = max_rt) instead
> +  of pressure (no pressure = 0).
> +- ti,min-x: minimum value reported by X axis ADC (default 0).
> +- ti,max-x: maximum value reported by X axis ADC (default 4095).
> +- ti,min-y: minimum value reported by Y axis ADC (default 0).
> +- ti,max-y: maximum value reported by Y axis ADC (default 4095).

Seems like these could be common too. They make more sense than giving x 
and y sizes in pixel units which really should come from the panel.

>  - ti,poll-period: how much time to wait (in milliseconds) before reading again the
> -  values from the tsc2007.
> +  values from the tsc2007 (default 1).
>  
>  [0]: Documentation/devicetree/bindings/interrupt-controller/interrupts.txt
>  [1]: Documentation/devicetree/bindings/gpio/gpio.txt
> +[2]: Documentation/devicetree/bindings/input/touchscreen/touchscreen.txt
>  
>  Example:
>  	&i2c1 {
> @@ -35,6 +39,8 @@ Example:
>  			interrupts = <0x0 0x8>;
>  			gpios = <&gpio4 0 0>;
>  			ti,x-plate-ohms = <180>;
> +			touchscreen-size-x = <640>;
> +			touchscreen-size-y = <480>;
>  		};
>  
>  		/* ... */
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2016-09-23 22:47 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-23 12:41 [PATCH v3 0/8] drivers: touchscreen: tsc2007 and ads7846/tsc2046 improvements (use common touchscreen bindings, pre-calibration, spi fix and provide iio raw values) H. Nikolaus Schaller
2016-09-23 12:41 ` [PATCH v3 1/8] drivers:input:tsc2007: add new common binding names, pre-calibration, flipping and rotation H. Nikolaus Schaller
     [not found]   ` <1409ed9845f17445a8a67bd6fb16c902c3e4f69c.1474634475.git.hns-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>
2016-09-23 22:47     ` Rob Herring [this message]
2016-09-24  0:31       ` Sebastian Reichel
2016-09-24  5:55         ` H. Nikolaus Schaller
     [not found]           ` <E8C59C6C-23D4-4417-8A9E-3E9AE5D2D100-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>
2016-09-30 14:16             ` Sebastian Reichel
2016-09-30 14:40               ` H. Nikolaus Schaller
     [not found]                 ` <29036A28-9997-4ED6-81FE-3ABC659EEEEB-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>
2016-10-17 13:57                   ` H. Nikolaus Schaller
2016-09-24  5:28       ` H. Nikolaus Schaller
2016-09-30 16:23     ` [Letux-kernel] " Christ van Willegen
     [not found]       ` <CA+Ot1Owa_evu62LJpH+TdUkLWd0n+0Dm30Q1-5KFJ6w_UBPfQQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2016-09-30 16:36         ` H. Nikolaus Schaller
2016-09-23 12:41 ` [PATCH v3 2/8] drivers:input:tsc2007: send pendown and penup only once like ads7846(+tsc2046) driver does H. Nikolaus Schaller
     [not found] ` <cover.1474634475.git.hns-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>
2016-09-23 12:41   ` [PATCH v3 3/8] drivers:input:tsc2007: add iio interface to read external ADC input, temperature and raw conversion values H. Nikolaus Schaller
     [not found]     ` <909d06d4f54359c7ac0dcf36a49cbd3ff7e8ebf2.1474634475.git.hns-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>
2016-09-24 16:07       ` Jonathan Cameron
2016-09-24 17:07         ` H. Nikolaus Schaller
     [not found]           ` <8A30B517-FE25-418B-9921-407243B0B72B-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>
2016-09-24 17:26             ` Jonathan Cameron
2016-09-24 17:42               ` H. Nikolaus Schaller
2016-09-24 17:44           ` Dmitry Torokhov
     [not found]             ` <CAKdAkRS3OhUp=WXtrLxQSJAvtgt24jo2W8Nw_NwR4O=R9jboaA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2016-09-24 17:51               ` H. Nikolaus Schaller
2016-09-23 12:41   ` [PATCH v3 5/8] DT:omap3+tsc2007: use new common touchscreen bindings H. Nikolaus Schaller
2016-09-23 12:41 ` [PATCH v3 4/8] drivers:input:tsc2007: check for presence and power down tsc2007 during probe H. Nikolaus Schaller
2016-09-23 12:41 ` [PATCH v3 6/8] drivers:input:ads7846(+tsc2046): add new common binding names, pre-calibration and flipping H. Nikolaus Schaller
2016-09-23 22:50   ` Rob Herring
2016-09-23 12:41 ` [PATCH v3 7/8] drivers:input:ads7846(+tsc2046): fix spi module table H. Nikolaus Schaller
2016-09-23 12:41 ` [PATCH v3 8/8] DT:omap3+ads7846: use new common touchscreen bindings H. Nikolaus Schaller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160923224726.GA4639@rob-hp-laptop \
    --to=robh-dgejt+ai2ygdnm+yrofe0a@public.gmane.org \
    --cc=afd-l0cyMroinI0@public.gmane.org \
    --cc=arnd-r2nGTMty4D4@public.gmane.org \
    --cc=bcousson-rdvid1DuHRBWk0Htik3J/w@public.gmane.org \
    --cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=dmitry.torokhov-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=grinberg-UTxiZqZC01RS1MOuV/RT9w@public.gmane.org \
    --cc=hns-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org \
    --cc=javier-JPH+aEBZ4P+UEJcrhfAQsw@public.gmane.org \
    --cc=letux-kernel-S0jZdbWzriLCfDggNXIi3w@public.gmane.org \
    --cc=linux-I+IVW8TIWO2tmTQ+vhA3Yw@public.gmane.org \
    --cc=linux-iio-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-input-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=mark.rutland-5wv7dgnIgG8@public.gmane.org \
    --cc=mika.penttila-MRsr7dthA9VWk0Htik3J/w@public.gmane.org \
    --cc=mwelling-EkmVulN54Sk@public.gmane.org \
    --cc=sre-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
    --cc=tony-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).