From patchwork Wed Jan 30 06:48:28 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Vasut X-Patchwork-Id: 10787747 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 2B99A184E for ; Wed, 30 Jan 2019 06:48:48 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1B9C42D407 for ; Wed, 30 Jan 2019 06:48:48 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 103EE2E083; Wed, 30 Jan 2019 06:48:48 +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=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, 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 AD50D2D407 for ; Wed, 30 Jan 2019 06:48:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726452AbfA3Gsr (ORCPT ); Wed, 30 Jan 2019 01:48:47 -0500 Received: from mail-out.m-online.net ([212.18.0.9]:53180 "EHLO mail-out.m-online.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725836AbfA3Gsr (ORCPT ); Wed, 30 Jan 2019 01:48:47 -0500 Received: from frontend01.mail.m-online.net (unknown [192.168.8.182]) by mail-out.m-online.net (Postfix) with ESMTP id 43qDV52Xqhz1qvvy; Wed, 30 Jan 2019 07:48:45 +0100 (CET) Received: from localhost (dynscan1.mnet-online.de [192.168.6.70]) by mail.m-online.net (Postfix) with ESMTP id 43qDV52JJNz1rVwb; Wed, 30 Jan 2019 07:48:45 +0100 (CET) X-Virus-Scanned: amavisd-new at mnet-online.de Received: from mail.mnet-online.de ([192.168.8.182]) by localhost (dynscan1.mail.m-online.net [192.168.6.70]) (amavisd-new, port 10024) with ESMTP id yMzYhQGrsEFu; Wed, 30 Jan 2019 07:48:44 +0100 (CET) X-Auth-Info: MSya6HbwYIB7gfOL48sATPB+8R7h/878Xo/xdoZP1Yw= Received: from kurokawa.lan (ip-86-49-110-70.net.upcbroadband.cz [86.49.110.70]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.mnet-online.de (Postfix) with ESMTPSA; Wed, 30 Jan 2019 07:48:44 +0100 (CET) From: Marek Vasut To: linux-input@vger.kernel.org Cc: Marek Vasut , Dmitry Torokhov , Henrik Rydberg , Olivier Sobrie , Philipp Puschmann Subject: [PATCH V4 03/10] input: touchscreen: ili210x: Drop get_pendown_state Date: Wed, 30 Jan 2019 07:48:28 +0100 Message-Id: <20190130064835.8418-4-marex@denx.de> X-Mailer: git-send-email 2.19.2 In-Reply-To: <20190130064835.8418-1-marex@denx.de> References: <20190130064835.8418-1-marex@denx.de> MIME-Version: 1.0 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 .get_pendown_state callback is set only by the platform data code, which was just removed. Thus, get_pendown_state() always returns false, so drop that altogether. Signed-off-by: Marek Vasut Cc: Dmitry Torokhov Cc: Henrik Rydberg Cc: Olivier Sobrie Cc: Philipp Puschmann To: linux-input@vger.kernel.org --- V2: New patch V3: No change V4: No change --- drivers/input/touchscreen/ili210x.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/drivers/input/touchscreen/ili210x.c b/drivers/input/touchscreen/ili210x.c index 25b0ca6c07d9..11007bf8113c 100644 --- a/drivers/input/touchscreen/ili210x.c +++ b/drivers/input/touchscreen/ili210x.c @@ -43,7 +43,6 @@ struct firmware_version { struct ili210x { struct i2c_client *client; struct input_dev *input; - bool (*get_pendown_state)(void); unsigned int poll_period; struct delayed_work dwork; }; @@ -102,16 +101,6 @@ static void ili210x_report_events(struct input_dev *input, input_sync(input); } -static bool get_pendown_state(const struct ili210x *priv) -{ - bool state = false; - - if (priv->get_pendown_state) - state = priv->get_pendown_state(); - - return state; -} - static void ili210x_work(struct work_struct *work) { struct ili210x *priv = container_of(work, struct ili210x, @@ -130,7 +119,7 @@ static void ili210x_work(struct work_struct *work) ili210x_report_events(priv->input, &touchdata); - if ((touchdata.status & 0xf3) || get_pendown_state(priv)) + if (touchdata.status & 0xf3) schedule_delayed_work(&priv->dwork, msecs_to_jiffies(priv->poll_period)); }