From patchwork Fri Mar 30 23:54:54 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alex Hung X-Patchwork-Id: 10318465 X-Patchwork-Delegate: andy.shevchenko@gmail.com 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 943CF602D6 for ; Fri, 30 Mar 2018 23:55:00 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 73A8B2A617 for ; Fri, 30 Mar 2018 23:55:00 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 522382A61B; Fri, 30 Mar 2018 23:55:00 +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.9 required=2.0 tests=BAYES_00,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 ACABB2A617 for ; Fri, 30 Mar 2018 23:54:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752678AbeC3Xy7 (ORCPT ); Fri, 30 Mar 2018 19:54:59 -0400 Received: from youngberry.canonical.com ([91.189.89.112]:41397 "EHLO youngberry.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752384AbeC3Xy6 (ORCPT ); Fri, 30 Mar 2018 19:54:58 -0400 Received: from 2.general.alexhung.us.vpn ([10.172.65.255] helo=canonical.com) by youngberry.canonical.com with esmtpsa (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.76) (envelope-from ) id 1f23rE-0006zE-MN; Fri, 30 Mar 2018 23:54:57 +0000 From: Alex Hung To: alex.hung@canonical.com, dvhart@infradead.org, andy@infradead.org, platform-driver-x86@vger.kernel.org, jason.gerecke@wacom.com Subject: [PATCH][V3] intel-hid: support KEY_ROTATE_LOCK_TOGGLE Date: Fri, 30 Mar 2018 16:54:54 -0700 Message-Id: <20180330235454.15972-1-alex.hung@canonical.com> X-Mailer: git-send-email 2.14.1 Sender: platform-driver-x86-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: platform-driver-x86@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP KEY_ROTATE_LOCK_TOGGLE is introduced in 4.16 rc1 and this key event is emitted on Wacom MobileStudio Pro 13. Signed-off-by: Alex Hung Co-developed-by: Jason Gerecke Signed-off-by: Jason Gerecke --- drivers/platform/x86/intel-hid.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/platform/x86/intel-hid.c b/drivers/platform/x86/intel-hid.c index 5e3df194723e..93f62d0e2b47 100644 --- a/drivers/platform/x86/intel-hid.c +++ b/drivers/platform/x86/intel-hid.c @@ -67,8 +67,8 @@ static const struct key_entry intel_array_keymap[] = { { KE_IGNORE, 0xC5, { KEY_VOLUMEUP } }, /* Release */ { KE_KEY, 0xC6, { KEY_VOLUMEDOWN } }, /* Press */ { KE_IGNORE, 0xC7, { KEY_VOLUMEDOWN } }, /* Release */ - { KE_SW, 0xC8, { .sw = { SW_ROTATE_LOCK, 1 } } }, /* Press */ - { KE_SW, 0xC9, { .sw = { SW_ROTATE_LOCK, 0 } } }, /* Release */ + { KE_KEY, 0xC8, { KEY_ROTATE_LOCK_TOGGLE } }, /* Press */ + { KE_IGNORE, 0xC9, { KEY_ROTATE_LOCK_TOGGLE } }, /* Release */ { KE_KEY, 0xCE, { KEY_POWER } }, /* Press */ { KE_IGNORE, 0xCF, { KEY_POWER } }, /* Release */ { KE_END },