From patchwork Wed Apr 10 14:54:25 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans de Goede X-Patchwork-Id: 10894077 X-Patchwork-Delegate: jikos@jikos.cz 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 929EB922 for ; Wed, 10 Apr 2019 14:55:17 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7BD0E286A4 for ; Wed, 10 Apr 2019 14:55:17 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7011B28733; Wed, 10 Apr 2019 14:55:17 +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 1BB1A286A4 for ; Wed, 10 Apr 2019 14:55:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732909AbfDJOzQ (ORCPT ); Wed, 10 Apr 2019 10:55:16 -0400 Received: from mx1.redhat.com ([209.132.183.28]:58712 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732725AbfDJOzQ (ORCPT ); Wed, 10 Apr 2019 10:55:16 -0400 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 422D6A090E; Wed, 10 Apr 2019 14:55:16 +0000 (UTC) Received: from shalem.localdomain.com (ovpn-116-249.ams2.redhat.com [10.36.116.249]) by smtp.corp.redhat.com (Postfix) with ESMTP id 2A4CF619A6; Wed, 10 Apr 2019 14:55:15 +0000 (UTC) From: Hans de Goede To: Jiri Kosina , Benjamin Tissoires Cc: Hans de Goede , Nestor Lopez Casado , linux-input@vger.kernel.org Subject: [PATCH v2 03/37] HID: logitech-dj: reshuffle logi_dj_recv_forward_* Date: Wed, 10 Apr 2019 16:54:25 +0200 Message-Id: <20190410145459.11430-4-hdegoede@redhat.com> In-Reply-To: <20190410145459.11430-1-hdegoede@redhat.com> References: <20190410145459.11430-1-hdegoede@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.39]); Wed, 10 Apr 2019 14:55:16 +0000 (UTC) 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 From: Benjamin Tissoires logi_dj_recv_forward_report() was only intended for DJ reports. logi_dj_recv_forward_hidpp() is more generic at forwarding random HID reports. So rename logi_dj_recv_forward_report() into logi_dj_recv_forward_dj() and logi_dj_recv_forward_hidpp() into logi_dj_recv_forward_report(). Signed-off-by: Benjamin Tissoires --- drivers/hid/hid-logitech-dj.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/hid/hid-logitech-dj.c b/drivers/hid/hid-logitech-dj.c index a75101293755..f2e994d11b70 100644 --- a/drivers/hid/hid-logitech-dj.c +++ b/drivers/hid/hid-logitech-dj.c @@ -552,8 +552,8 @@ static void logi_dj_recv_forward_null_report(struct dj_receiver_dev *djrcv_dev, } } -static void logi_dj_recv_forward_report(struct dj_receiver_dev *djrcv_dev, - struct dj_report *dj_report) +static void logi_dj_recv_forward_dj(struct dj_receiver_dev *djrcv_dev, + struct dj_report *dj_report) { /* We are called from atomic context (tasklet && djrcv->lock held) */ struct dj_device *dj_device; @@ -573,8 +573,8 @@ static void logi_dj_recv_forward_report(struct dj_receiver_dev *djrcv_dev, } } -static void logi_dj_recv_forward_hidpp(struct dj_device *dj_dev, u8 *data, - int size) +static void logi_dj_recv_forward_report(struct dj_device *dj_dev, u8 *data, + int size) { /* We are called from atomic context (tasklet && djrcv->lock held) */ if (hid_input_report(dj_dev->hdev, HID_INPUT_REPORT, data, size, 1)) @@ -893,7 +893,7 @@ static int logi_dj_dj_event(struct hid_device *hdev, } break; default: - logi_dj_recv_forward_report(djrcv_dev, dj_report); + logi_dj_recv_forward_dj(djrcv_dev, dj_report); } out: @@ -948,8 +948,8 @@ static int logi_dj_hidpp_event(struct hid_device *hdev, /* received an event for an unknown device, bail out */ goto out; - logi_dj_recv_forward_hidpp(djrcv_dev->paired_dj_devices[device_index], - data, size); + logi_dj_recv_forward_report(djrcv_dev->paired_dj_devices[device_index], + data, size); out: spin_unlock_irqrestore(&djrcv_dev->lock, flags);