From patchwork Sat Mar 25 00:58:59 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nick Dyer X-Patchwork-Id: 9644325 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 3E6706020B for ; Sat, 25 Mar 2017 01:06:56 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 312F825F31 for ; Sat, 25 Mar 2017 01:06:56 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 25F9326E48; Sat, 25 Mar 2017 01:06:56 +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=ham 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 BB2D525F31 for ; Sat, 25 Mar 2017 01:06:55 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755869AbdCYBGz (ORCPT ); Fri, 24 Mar 2017 21:06:55 -0400 Received: from avasout06.plus.net ([212.159.14.18]:54883 "EHLO avasout06.plus.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754414AbdCYBGz (ORCPT ); Fri, 24 Mar 2017 21:06:55 -0400 X-Greylist: delayed 456 seconds by postgrey-1.27 at vger.kernel.org; Fri, 24 Mar 2017 21:06:49 EDT Received: from lava ([80.229.148.18]) by avasout06 with smtp id 00zA1v0040Q3Geg010zBWn; Sat, 25 Mar 2017 00:59:11 +0000 X-CM-Score: 0.00 X-CNFS-Analysis: v=2.2 cv=QoEu5R6d c=1 sm=1 tr=0 a=o7Djd4SkmPXITDn8qH+ssQ==:117 a=o7Djd4SkmPXITDn8qH+ssQ==:17 a=6Iz7jQTuP9IA:10 a=beXlt2xKAAAA:8 a=2AAkmHg3sA_EGEoN7vsA:9 a=gcY2M4Ci8LIz02MwfSIM:22 Received: from nick by lava with local (Exim 4.86_2) (envelope-from ) id 1cra2v-0008Dk-LE; Sat, 25 Mar 2017 00:59:09 +0000 From: Nick Dyer To: Dmitry Torokhov Cc: Benjamin Tissoires , Andrew Duggan , Christopher Heiny , linux-input@vger.kernel.org, Chris Healy , Lucas Stach , Nick Dyer Subject: [PATCH 2/3] Input: synaptics-rmi4 - change F12 clip to inactive border debug Date: Sat, 25 Mar 2017 00:58:59 +0000 Message-Id: <1490403540-31425-3-git-send-email-nick@shmanahar.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1490403540-31425-1-git-send-email-nick@shmanahar.org> References: <1490403540-31425-1-git-send-email-nick@shmanahar.org> Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The data in F12_2D_Ctrl8 corresponds to the inactive border width used by the RMI device. It is not in pixel units and should not be treated as a clip value. Signed-off-by: Nick Dyer Tested-by: Chris Healy --- drivers/input/rmi4/rmi_f12.c | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) diff --git a/drivers/input/rmi4/rmi_f12.c b/drivers/input/rmi4/rmi_f12.c index 07aff43..8b0db08 100644 --- a/drivers/input/rmi4/rmi_f12.c +++ b/drivers/input/rmi4/rmi_f12.c @@ -113,20 +113,16 @@ static int rmi_f12_read_sensor_tuning(struct f12_data *f12) } if (rmi_register_desc_has_subpacket(item, 2)) { - sensor->axis_align.clip_x_low = buf[offset]; - sensor->axis_align.clip_x_high = sensor->max_x - - buf[offset + 1]; - sensor->axis_align.clip_y_low = buf[offset + 2]; - sensor->axis_align.clip_y_high = sensor->max_y - - buf[offset + 3]; + /* Units 1/128 sensor pitch */ + rmi_dbg(RMI_DEBUG_FN, &fn->dev, + "%s: Inactive Border xlo:%d xhi:%d ylo:%d yhi:%d\n", + __func__, + buf[offset], buf[offset + 1], + buf[offset + 2], buf[offset + 3]); + offset += 4; } - rmi_dbg(RMI_DEBUG_FN, &fn->dev, "%s: x low: %d x high: %d y low: %d y high: %d\n", - __func__, - sensor->axis_align.clip_x_low, sensor->axis_align.clip_x_high, - sensor->axis_align.clip_y_low, sensor->axis_align.clip_y_high); - if (rmi_register_desc_has_subpacket(item, 3)) { rx_receivers = buf[offset]; tx_receivers = buf[offset + 1];