From patchwork Sat Mar 30 13:37:35 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: 10878493 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 C63631669 for ; Sat, 30 Mar 2019 13:37:52 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B2AE828727 for ; Sat, 30 Mar 2019 13:37:52 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id A582F28E44; Sat, 30 Mar 2019 13:37:52 +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 49D6528727 for ; Sat, 30 Mar 2019 13:37:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730849AbfC3Nhv (ORCPT ); Sat, 30 Mar 2019 09:37:51 -0400 Received: from mx1.redhat.com ([209.132.183.28]:33626 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730784AbfC3Nhv (ORCPT ); Sat, 30 Mar 2019 09:37:51 -0400 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 7083430821F7; Sat, 30 Mar 2019 13:37:51 +0000 (UTC) Received: from shalem.localdomain.com (ovpn-116-76.ams2.redhat.com [10.36.116.76]) by smtp.corp.redhat.com (Postfix) with ESMTP id 2D79E1001E8A; Sat, 30 Mar 2019 13:37:50 +0000 (UTC) From: Hans de Goede To: Jiri Kosina , Benjamin Tissoires , Dmitry Torokhov Cc: Hans de Goede , Peter Hutterer , linux-input@vger.kernel.org Subject: [RFC 6/6] Bluetooth: hidp: Stop using deprecated BTN_EXTRA, _SIDE defines Date: Sat, 30 Mar 2019 14:37:35 +0100 Message-Id: <20190330133735.14681-7-hdegoede@redhat.com> In-Reply-To: <20190330133735.14681-1-hdegoede@redhat.com> References: <20190330133735.14681-1-hdegoede@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.47]); Sat, 30 Mar 2019 13:37:51 +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 Because the name of the BTN_EXTRA and BTN_SIDE defines was a mismatch with how their values were actually being used, they have been deprecated. This commit moves the bluetooth-hidp code over to the new defines with the _same_ value. This commit does not cause any functional changes, after this userspace will see the exact same input_event codes as before. Signed-off-by: Hans de Goede --- net/bluetooth/hidp/core.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/net/bluetooth/hidp/core.c b/net/bluetooth/hidp/core.c index a442e21f3894..f1905930ceea 100644 --- a/net/bluetooth/hidp/core.c +++ b/net/bluetooth/hidp/core.c @@ -211,8 +211,8 @@ static void hidp_input_report(struct hidp_session *session, struct sk_buff *skb) input_report_key(dev, BTN_LEFT, sdata[0] & 0x01); input_report_key(dev, BTN_RIGHT, sdata[0] & 0x02); input_report_key(dev, BTN_MIDDLE, sdata[0] & 0x04); - input_report_key(dev, BTN_SIDE, sdata[0] & 0x08); - input_report_key(dev, BTN_EXTRA, sdata[0] & 0x10); + input_report_key(dev, BTN_BACKWRD, sdata[0] & 0x08); + input_report_key(dev, BTN_FORWRD, sdata[0] & 0x10); input_report_rel(dev, REL_X, sdata[1]); input_report_rel(dev, REL_Y, sdata[2]); @@ -690,8 +690,8 @@ static int hidp_setup_input(struct hidp_session *session, input->keybit[BIT_WORD(BTN_MOUSE)] = BIT_MASK(BTN_LEFT) | BIT_MASK(BTN_RIGHT) | BIT_MASK(BTN_MIDDLE); input->relbit[0] = BIT_MASK(REL_X) | BIT_MASK(REL_Y); - input->keybit[BIT_WORD(BTN_MOUSE)] |= BIT_MASK(BTN_SIDE) | - BIT_MASK(BTN_EXTRA); + input->keybit[BIT_WORD(BTN_MOUSE)] |= BIT_MASK(BTN_BACKWRD) | + BIT_MASK(BTN_FORWRD); input->relbit[0] |= BIT_MASK(REL_WHEEL); }