From patchwork Sat Oct 8 10:38:56 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Tunin X-Patchwork-Id: 9368101 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 B808F6075E for ; Sat, 8 Oct 2016 10:39:16 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 93AFA28954 for ; Sat, 8 Oct 2016 10:39:16 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 74A8D29414; Sat, 8 Oct 2016 10:39:16 +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.3 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID 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 0C03628954 for ; Sat, 8 Oct 2016 10:39:15 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756068AbcJHKjL (ORCPT ); Sat, 8 Oct 2016 06:39:11 -0400 Received: from mail-lf0-f67.google.com ([209.85.215.67]:32982 "EHLO mail-lf0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756513AbcJHKjK (ORCPT ); Sat, 8 Oct 2016 06:39:10 -0400 Received: by mail-lf0-f67.google.com with SMTP id l131so3869129lfl.0; Sat, 08 Oct 2016 03:39:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=emaSvdSdlbUmfSkgz7HML+gvJ1HAvBcK36WJdlc7X6g=; b=slpTipW+kNkj5uVBM/BNVOaT6i/17vQrlkxnA/LxW4GTkwRQtB38g2bRJuCoitZdAz VtZtRiKXD/EjBOOl3E9XdbdyJEDSrtM5jPxraewLH9aByLfxVqoopaf9CA5+LX06SsxV 8z/Fq86CacyqeKK+JGXxowxTqxKLmaz6XhPRFwE5wKki2xhfZX52EFTQUmbT/jpwNUhX UEJVIzrQawzhiXcGiChO9yDRfdjbEskcOQBBb53jvcZyZk393gW2MJoTpSPqcsEaBaGF DHYTIJHy9j0xmYBE1tPAnZ8MHtLx+TTubPPvsQZKBCpbFMYwkhGtR8IVSMh1qjR47q8H aMbw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=emaSvdSdlbUmfSkgz7HML+gvJ1HAvBcK36WJdlc7X6g=; b=TxeHfv7YLwE+2bHYDF4FgfCwrMjbz+r7UGsFYRVrwGoydb0tqBctzXf7ddrj5jI1PB xyCryiMZGYh7tHvO4MURWLnwxTWCDSkr/hgKEEQZhq1r/t3o4LmVuVn9mcGQ0qZu32va 86rzqok4wpnuosesSurJAaJVVLnuKnihFQUsRG86py24p3u/XQOYyW9765hMJpBtxh6R Jb26hLIVmQjOHBYQ+cAdprdZrdZdsKGSla91TUR9eYYbEWvUABF3XhOK9/HJogRitgrV EJ1Bn3snuovz4qCTZDpzng6ZhU4nC8H+HjemJCy5rFJY+lA8/kcVdH5oJ/OZUgVKgZmp Dbyw== X-Gm-Message-State: AA6/9RkLmpJeCb64CnzVSpPlubYWDqLQePwoUDnh1jr+sNbPUcfXCXek2L1luMJltyg2fQ== X-Received: by 10.25.17.208 with SMTP id 77mr9932261lfr.51.1475923148238; Sat, 08 Oct 2016 03:39:08 -0700 (PDT) Received: from localhost.localdomain ([176.15.57.141]) by smtp.googlemail.com with ESMTPSA id t78sm4309125lfi.43.2016.10.08.03.39.07 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 08 Oct 2016 03:39:07 -0700 (PDT) From: Dmitry Tunin To: Dmitry Torokhov Cc: linux-input@vger.kernel.org, linux-kernel@vger.kernel.org, Mathias Gottschlag , Dmitry Tunin Subject: [PATCH] Input: psmouse - cleanup Focaltech code Date: Sat, 8 Oct 2016 13:38:56 +0300 Message-Id: <1475923136-6046-1-git-send-email-hanipouspilot@gmail.com> X-Mailer: git-send-email 2.7.4 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 psmouse->name "Focaltech Touchpad" is an overkill. In xinput it is too long as "FocaltechPS/2 Focaltech Focaltech Touchpad" In focaltech_report_state() pointer to psmouse->dev is already stored as *dev Signed-off-by: Dmitry Tunin --- drivers/input/mouse/focaltech.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/input/mouse/focaltech.c b/drivers/input/mouse/focaltech.c index c8c6a8c..49a56f655 100644 --- a/drivers/input/mouse/focaltech.c +++ b/drivers/input/mouse/focaltech.c @@ -43,7 +43,7 @@ int focaltech_detect(struct psmouse *psmouse, bool set_properties) if (set_properties) { psmouse->vendor = "FocalTech"; - psmouse->name = "FocalTech Touchpad"; + psmouse->name = "Touchpad"; } return 0; @@ -146,8 +146,8 @@ static void focaltech_report_state(struct psmouse *psmouse) } input_mt_report_pointer_emulation(dev, true); - input_report_key(psmouse->dev, BTN_LEFT, state->pressed); - input_sync(psmouse->dev); + input_report_key(dev, BTN_LEFT, state->pressed); + input_sync(dev); } static void focaltech_process_touch_packet(struct psmouse *psmouse,