Received: by 10.223.164.202 with SMTP id h10csp983724wrb; Thu, 9 Nov 2017 18:45:14 -0800 (PST) X-Google-Smtp-Source: ABhQp+TPToIncLow+3tSVtBmIsJPNObD+1yYWXrj3qoCTUtkAt/WGhPqfJhFO1uTWLMCTTH/zI5w X-Received: by 10.159.206.131 with SMTP id bg3mr2560221plb.124.1510281914280; Thu, 09 Nov 2017 18:45:14 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1510281914; cv=none; d=google.com; s=arc-20160816; b=Sm452QDiIT36XSOXKVrCdViz1414VG2C+eYVCyus/j8ziq5VMJ+vCbfbghj45BSxhi RLuVCXyVgFfmhJgslQPbeKbXm5yL+7V9JIhZ6M/I74pRd4EYp7ZMRQuc4srk0C3NMRRu dRJKrWkTQvcUPZcoKYZWhOODpfTnksGWXE9nIISpjHQTyva7Tfrwbk046b21M1TEtb4+ 2sNs/PET26CLTcZH7fCalz4rcjq162zuBOGKnxBKCUHmf2nzafCk2CXe1rkczPjq7LZ8 8aWFvtPjHFyOFW9660FVDA3XaabzvwnFdoB64qQbamsQjOCngrNrdyK5stDdCxXCsgEw v5uQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:arc-authentication-results; bh=0E1q1d6oqVxmSHyg7XFCkQAnzhSewAX4JmHuxjUREdo=; b=mfZfu1eJmoiWpDLiAvw79Ztj8PTldL9a568wNpwHEDbfTeK0b9vUdXX/EIq5PMvX0k F8FMpLvhQVY9Gael0svE0TEuWAkfPmXPo1mEwxiX7E4yn9km1Lo+U5csg2FWCrvKtPlF +rmlYyPituFmDmPj/ZF+jSHN2TqoN+3Si3nNyxoxtZrZktWIzNG+3LFIsMhCZn9Fqk/I aft7VwHvtic3zuE4R0p8SUBGE/wSo1Is+lCxDs0kVQ4ZpBRQqT7pVt9HC6Kdr2D1FMhO TYxNXIuyjeAFrYV0esQCsXjMgjPsbzj/InjULHmuM8GelTU76QFmmxF06AYRTBF7O0ww ilag== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b4si7719005plb.202.2017.11.09.18.45.02; Thu, 09 Nov 2017 18:45:14 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S964792AbdKJCoQ (ORCPT + 83 others); Thu, 9 Nov 2017 21:44:16 -0500 Received: from mail-out-1.itc.rwth-aachen.de ([134.130.5.46]:7151 "EHLO mail-out-1.itc.rwth-aachen.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S964779AbdKJCoP (ORCPT ); Thu, 9 Nov 2017 21:44:15 -0500 X-IronPort-AV: E=Sophos;i="5.44,372,1505772000"; d="asc'?scan'208";a="22978337" Received: from rwthex-w2-a.rwth-ad.de ([134.130.26.158]) by mail-in-1.itc.rwth-aachen.de with ESMTP; 10 Nov 2017 03:44:13 +0100 Received: from pebbles.localnet (78.49.52.200) by rwthex-w2-a.rwth-ad.de (2002:8682:1a9e::8682:1a9e) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1034.26; Fri, 10 Nov 2017 03:44:12 +0100 From: Stefan =?ISO-8859-1?Q?Br=FCns?= To: Darren Hart CC: , , AceLan Kao , Andy Shevchenko , Subject: Re: [PATCH v2 2/5] platform/x86: intel-vbtn: Support separate press/release events Date: Fri, 10 Nov 2017 03:44:08 +0100 Message-ID: <6160107.5aeZWuaZvU@pebbles> In-Reply-To: <20171110021137.GE9783@fury> References: <20171109224436.16472-1-stefan.bruens@rwth-aachen.de> <1637751.MqEGyCB5Qi@pebbles> <20171110021137.GE9783@fury> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart2675023.LTSkr8gxWR"; micalg=pgp-sha1; protocol="application/pgp-signature" X-Originating-IP: [78.49.52.200] X-ClientProxiedBy: rwthex-s2-a.rwth-ad.de (2002:8682:1a9a::8682:1a9a) To rwthex-w2-a.rwth-ad.de (2002:8682:1a9e::8682:1a9e) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --nextPart2675023.LTSkr8gxWR Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="iso-8859-1" On Friday, November 10, 2017 3:11:37 AM CET Darren Hart wrote: > On Fri, Nov 10, 2017 at 02:58:36AM +0100, Stefan Br=FCns wrote: > > On Friday, November 10, 2017 2:34:17 AM CET Darren Hart wrote: > > > On Thu, Nov 09, 2017 at 11:44:33PM +0100, Stefan Br=FCns wrote: > > > > Currently all key events use autorelease, but this forbids use as a > > > > modifier key. > > > >=20 > > > > As all event codes come in even/odd pairs, we can lookup the key ty= pe > > > > (KE_KEY/KE_IGNORE) for the key up event corresponding to the curren= tly > > > > handled key down event. If the key up is ignored, we keep setting t= he > > > > autorelease flag for the key down. > > >=20 > > > What is the use-case for using these buttons as modifiers? I'm pictur= ing > > > one of these devices in tablet mode, with a physical Windows button. > > > What other action does a user want to modify by holding the Windows > > > button down? Or is there another scenario we're trying to support her= e? > >=20 > > Windows/KEY_LEFTMETA can be used as a modifier key, e.g. in combination > > with the Volume Up/Down keys. On Windows, the default for Win + VolumeUp > > creates a screenshot. > >=20 > > You can also use this in combination with an onscreen keyboard. Pressing > > the hardware button with the hand holding the tablet and typing with the > > other hand on the OSK is probably easier than hitting both keys on the > > OSK. > This all makes sense - good context for the commit message. If no other > changes end up being needed, I'm happy to paste it in at merge. If changes > are required, please add it in v3. >=20 > > Additionally, the Volume Up/Down currently do not autorepeat, as the key > > is > > autoreleased on the press event. The XPS 12 does issue distinct > > press/release events, so this could be done properly. The same apparent= ly > > holds for some other convertibles, see the links in Patch 1/5. >=20 > It sounds like this is spotty across intel-vbtn implementations? Some > devices emit release, others do not? How would you teach the driver about > the differences? Assume autorelease and change the sparse keymap entry for > DMI matched platforms with release? Doable... sounds unpleasant to mainta= in > and update. Do we support this fully in userspace already? =2D 0xcc/0xcd SW_TABLET mode seems to be consistent and widespread =2D 0xc4-0xc7 KEY_VOLUME_{UP,DOWN} seems to be consistent, although not use= d=20 very often (Lenovo Helix 2, XPS 12, other Dell XPS), others probably use WMI =2D 0xc2/0xc3 KEY_LEFTMETA is used on Helix 2 and XPS 12, but only the XPS= =20 issues 0xc2 on press and 0xc3 on release, the Helix 2 issues both codes on= =20 release and none on press. The statements above are verified on the XPS 12, the other findings are fro= m=20 the Internet, search for "unknown event index" + "intel-vbtn". As far as I can see, there are no implementation which do not issue the eve= nts=20 in pairs, so currently the quirks table would be empty. Kind regards, Stefan =2D-=20 Stefan Br=FCns / Bergstra=DFe 21 / 52062 Aachen home: +49 241 53809034 mobile: +49 151 50412019 --nextPart2675023.LTSkr8gxWR Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part. Content-Transfer-Encoding: 7Bit -----BEGIN PGP SIGNATURE----- iF0EABECAB0WIQSwWRWIpJbl0W4DemNvf0o9jP6qUwUCWgUSeAAKCRBvf0o9jP6q UweFAKCoMD5ZxmBTCdz/IhqmtxAHvR5mlQCeJjPyVsD2Wj9q6jC3cF7IBPyDA6c= =fOop -----END PGP SIGNATURE----- --nextPart2675023.LTSkr8gxWR-- From 1583643581362594597@xxx Fri Nov 10 02:16:49 +0000 2017 X-GM-THRID: 1583630420340555824 X-Gmail-Labels: Inbox,Category Forums,HistoricalUnread