From patchwork Thu Nov 10 16:35:13 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mugunthan V N X-Patchwork-Id: 9421899 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id E99E4601C0 for ; Thu, 10 Nov 2016 18:18:20 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id F3525297F6 for ; Thu, 10 Nov 2016 18:18:20 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E80F2297F9; Thu, 10 Nov 2016 18:18:20 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 973DE297F6 for ; Thu, 10 Nov 2016 18:18:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755741AbcKJSSI (ORCPT ); Thu, 10 Nov 2016 13:18:08 -0500 Received: from fllnx209.ext.ti.com ([198.47.19.16]:48018 "EHLO fllnx209.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754703AbcKJSSG (ORCPT ); Thu, 10 Nov 2016 13:18:06 -0500 Received: from dlelxv90.itg.ti.com ([172.17.2.17]) by fllnx209.ext.ti.com (8.15.1/8.15.1) with ESMTP id uAAGZQsT004047; Thu, 10 Nov 2016 10:35:26 -0600 Received: from DLEE71.ent.ti.com (dlee71.ent.ti.com [157.170.170.114]) by dlelxv90.itg.ti.com (8.14.3/8.13.8) with ESMTP id uAAGZQvh013475; Thu, 10 Nov 2016 10:35:26 -0600 Received: from dlep33.itg.ti.com (157.170.170.75) by DLEE71.ent.ti.com (157.170.170.114) with Microsoft SMTP Server id 14.3.294.0; Thu, 10 Nov 2016 10:35:25 -0600 Received: from a0131834lt.india.ti.com (ileax41-snat.itg.ti.com [10.172.224.153]) by dlep33.itg.ti.com (8.14.3/8.13.8) with ESMTP id uAAGZHqR007056; Thu, 10 Nov 2016 10:35:22 -0600 From: Mugunthan V N To: CC: Dmitry Torokhov , Jonathan Cameron , Rob Herring , Mark Rutland , Lee Jones , Sekhar Nori , Vignesh R , , , , Mugunthan V N Subject: [PATCH v2 1/3] dt/binding: ti-tsc-adc: deprecate ti, charge-delay and add binding doc for ti, charge-delay-ns Date: Thu, 10 Nov 2016 22:05:13 +0530 Message-ID: <20161110163515.27598-2-mugunthanvnm@ti.com> X-Mailer: git-send-email 2.11.0.rc0.7.gbe5a750 In-Reply-To: <20161110163515.27598-1-mugunthanvnm@ti.com> References: <20161110163515.27598-1-mugunthanvnm@ti.com> MIME-Version: 1.0 Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP ti,charge-delay represents the duration that ADC should wait before sampling the ADC line to detect the touch location and pen up/downs. Currently the ADC clock is set at 3MHz. The device-tree entry for ti,charge-delay is based on assumption of ADC clock at 3MHz, but it can be operated up to 24MHz clock. Representing the charge delay of touchscreen in terms of ADC clocks is incorrect. So change this representation to ti,charge-delay-ns, which driver can convert it to number clock cycles based on ref clock frequency. Signed-off-by: Mugunthan V N Acked-by: Rob Herring --- .../bindings/input/touchscreen/ti-tsc-adc.txt | 32 ++++++++++++++-------- 1 file changed, 21 insertions(+), 11 deletions(-) diff --git a/Documentation/devicetree/bindings/input/touchscreen/ti-tsc-adc.txt b/Documentation/devicetree/bindings/input/touchscreen/ti-tsc-adc.txt index b1163bf97146..83570776c804 100644 --- a/Documentation/devicetree/bindings/input/touchscreen/ti-tsc-adc.txt +++ b/Documentation/devicetree/bindings/input/touchscreen/ti-tsc-adc.txt @@ -30,17 +30,27 @@ Required properties: Optional properties: - child "tsc" - ti,charge-delay: Length of touch screen charge delay step in terms of - ADC clock cycles. Charge delay value should be large - in order to avoid false pen-up events. This value - effects the overall sampling speed, hence need to be - kept as low as possible, while avoiding false pen-up - event. Start from a lower value, say 0x400, and - increase value until false pen-up events are avoided. - The pen-up detection happens immediately after the - charge step, so this does in fact function as a - hardware knob for adjusting the amount of "settling - time". + ti,charge-delay-ns: Length of touch screen charge delay step in terms of + nano Seconds. Charge delay value should be large + in order to avoid false pen-up events. This value + effects the overall sampling speed, hence need to be + kept as low as possible, while avoiding false pen-up + event. Start from a lower value, say 41000nS, and + increase value until false pen-up events are avoided. + The pen-up detection happens immediately after the + charge step, so this does in fact function as a + hardware knob for adjusting the amount of "settling + time". + ti,charge-delay: Deprecated as representing charge delay should be + represented in time as the ADC clock may be different. + Currently this value is calculated based on 3MHz ADC + ref clock, but ADC clock can operate upto 24MHz clock. + ADC clock will be changed to 24MHz to increase the + number of ADC samples. So to keep the backward + compatibility, driver will consider this value is + calculated for 3MHz clock so the value will be + multiplied by 8 to compensate the change in reference + clock. - child "adc" ti,chan-step-opendelay: List of open delays for each channel of