Received: by 2002:ac0:da4c:0:0:0:0:0 with SMTP id a12csp334455imi; Thu, 21 Jul 2022 01:37:53 -0700 (PDT) X-Google-Smtp-Source: AGRyM1tgjSRLjWPqgDTg840hDJiuRJ6ve99bLqWrzjamqRfgocsa5VJhvFn6BRHJzQ5jwbiDc3k1 X-Received: by 2002:a17:90b:3507:b0:1f2:1b74:11d1 with SMTP id ls7-20020a17090b350700b001f21b7411d1mr8510576pjb.99.1658392673123; Thu, 21 Jul 2022 01:37:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1658392673; cv=none; d=google.com; s=arc-20160816; b=ZK+gnZtHykHM9SOp2j5ELGxuZvbnF86o9Vdd2Ej1xP2MlR5k3ftQAr4652tPVKlOja sru7Gb44iO8ex17eHKT0aJnJD0nLw2zn326VvhNcGsTkfwqjv9H0LdUatv4ZiFq47wEH CucglDef0+TDrpJnOnsHImT2pNPsU6Q7AjExTC6jSwqJ7SpUvbKY85VfAaSr2wLAU7Qq j/Nd2S9LqYnvZLK/rm53G/0cb/SXHU/2rkUvYCj337wKkV0Klz/W4GRG0q+zROyU4PVH F7Y89I6cVjZpwZzSL1p68ZKI1B6OdNCBCTkryfR9CBQ+YANl9wer5jHosj8A851dp3m5 9CJA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=AWa50Z3n/OW/pxkh4bsOeSMt1jMWo+yboFgvCPqDUIc=; b=d62ltDNkKIYd5X6nKwM/1mM2Hn/VfTcE5tQKGT30QF0uDJKkNC98oSnZ0E1Ddk+D8E FLwixyNGZFar98HA4Pw32pD65psSlwf/dsD23oJqZODaxu3TjpOcXpzx2XhVMt4jccs6 sHQpWVBgnck1f4ujdbLxaPC89W6I8NzjNdsQlheVvk7MzqD+uAxao/QYZhiCK0bg5lx2 Eu4oIOzYpVV0jaiZcjDGT0c1opd3p+OBYpJeV3dJDGxtHmt1kzk84kHKoGWvFwxE2x/N Xb2etBRt9OMk8GxzueJIjLsNO1ylakEk0wOuv8P1ZgGOV3ya/c9/42+27k5KkpJY1L+C ShNg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@aruba.it header.s=a1 header.b=Sy+c07Zc; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g1-20020a636b01000000b0041a88ab4ff7si391671pgc.72.2022.07.21.01.37.38; Thu, 21 Jul 2022 01:37:53 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@aruba.it header.s=a1 header.b=Sy+c07Zc; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232261AbiGUIgW (ORCPT + 99 others); Thu, 21 Jul 2022 04:36:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35220 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231591AbiGUIgR (ORCPT ); Thu, 21 Jul 2022 04:36:17 -0400 Received: from smtpcmd02101.aruba.it (smtpcmd02101.aruba.it [62.149.158.101]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 3714F22BC6 for ; Thu, 21 Jul 2022 01:36:15 -0700 (PDT) Received: from asem-TANK-H61.asem.intra ([151.1.184.193]) by Aruba Outgoing Smtp with ESMTPSA id ERe9oJVIEtk1HEReJojXoF; Thu, 21 Jul 2022 10:35:14 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=aruba.it; s=a1; t=1658392514; bh=tkpOYpCcZE1Bre0jpfaelBhmDtGIU38n7jAmgeM3WnE=; h=From:To:Subject:Date:MIME-Version; b=Sy+c07Zc0k3k3x0s26gPqkwImTlH9c7j1i23dYDy9pC5DNohk1MF4tbCZJH8ayd8n 6drRXXpgojntGk/ttyM+ZNuHv4TCwpJe70ALThC/6BI3oOXuOPgluUbQPcoAp8dko+ NNu43Vzvb4APSDgwAIGYQDoM3UGhV0XV44ptw/vmQpFK0wH3F+/Mz4LRm+R2KrSXGR YF2SoApn0T2JEnIfa3XXP+jdafOruzdi8UDmyRE7vhf68SS8wBU0xe1OvvlHKSSPkl tbdkeHUQVPKBqKi+0IxgzUVeJ4jyj5hBiJbrm7SN10CVsvete9JsfwXiDQ3fRwRRU5 EW68Cq/Le/+2A== From: Luca Ellero To: dmitry.torokhov@gmail.com, daniel@zonque.org, m.felsch@pengutronix.de, andriy.shevchenko@linux.intel.com, u.kleine-koenig@pengutronix.de, mkl@pengutronix.de, miquel.raynal@bootlin.com, imre.deak@nokia.com Cc: linux-input@vger.kernel.org, linux-kernel@vger.kernel.org, Luca Ellero Subject: [PATCH v2 1/3] ads7846: don't report pressure for ads7845 Date: Thu, 21 Jul 2022 10:34:56 +0200 Message-Id: <20220721083458.6412-2-luca.ellero@brickedbrain.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220721083458.6412-1-luca.ellero@brickedbrain.com> References: <20220721083458.6412-1-luca.ellero@brickedbrain.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-CMAE-Envelope: MS4xfO4plaYvd/DeQ97oMCVVt7FnIQg3nX7wTUDtAN49Y/Ac6fAjVU1BKV5UqYwa6hnQ/qiYBwYlGVUGU+dYdb6JN81WrbAeITsZuP61hdPIQTLsFm//pgIU bngsg0Kq1dnm6r7V9vNYMBlzbIn4MUOHBcifkRCe1Aw7S0QzMtUmg1Yj1OV9boY09T7A/FtzdMxOKmSIU432IJfmISb1QNMaWShNJHwlTFztuhoHIwFK60/R MsxuGXhpDy67/sl/28K5jW+SFtIrUPBO/ChuCLLp/RqmJnVguOEDdICX2F1LhUp2LrIOJyELDW2JHrPB88yH7ktUWgyPUt2EiLg1np9AjUDWsuSeswtAUmHL ZJaKc6OhcHC41FmUU9IA25fKwW5CnSJEVQm5jAwxp7D3lnLk9g6YW57w0+0g5McyNwaHi5PPZh+IVwFoEv10XPFdBpdRl/ot3lq5gsdjFX/xc4fx6D/krl9U nhNdFVenX5o6EOd0uTOmSEyqh+6T3zvNYgcMF7KrtTrgZv99jP0GV6YQkH4BSBv9g9bVCTR6aqHtGv2AT1cxKhCuuBIvdsfL2x//uBn9SRIFngK3ovTadvo0 uS8= X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIMWL_WL_MED, DKIM_SIGNED,DKIM_VALID,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Luca Ellero ADS7845 doesn't support pressure. This patch avoids the following error reported by libinput-list-devices: "ADS7845 Touchscreen: kernel bug: device has min == max on ABS_PRESSURE". Signed-off-by: Luca Ellero --- Changes for v2: - add missing period in commit message drivers/input/touchscreen/ads7846.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/input/touchscreen/ads7846.c b/drivers/input/touchscreen/ads7846.c index bed68a68f330..24605c40d039 100644 --- a/drivers/input/touchscreen/ads7846.c +++ b/drivers/input/touchscreen/ads7846.c @@ -1316,8 +1316,9 @@ static int ads7846_probe(struct spi_device *spi) pdata->y_min ? : 0, pdata->y_max ? : MAX_12BIT, 0, 0); - input_set_abs_params(input_dev, ABS_PRESSURE, - pdata->pressure_min, pdata->pressure_max, 0, 0); + if (ts->model != 7845) + input_set_abs_params(input_dev, ABS_PRESSURE, + pdata->pressure_min, pdata->pressure_max, 0, 0); /* * Parse common framework properties. Must be done here to ensure the -- 2.25.1