From: "Pali Rohár" <pali.rohar@gmail.com>
To: Oleksandr Natalenko <oleksandr@natalenko.name>
Cc: Mario Limonciello <mario_limonciello@dell.com>,
platform-driver-x86@vger.kernel.org,
linux-kernel@vger.kernel.org,
Matthew Garrett <mjg59@srcf.ucam.org>,
Darren Hart <dvhart@infradead.org>,
Andy Shevchenko <andy@infradead.org>,
Dmitry Torokhov <dmitry.torokhov@gmail.com>
Subject: Re: Dell Vostro 3360 multimedia keys
Date: Sat, 27 Jan 2018 15:05:57 +0100 [thread overview]
Message-ID: <20180127140557.xa3bdoouk5whhtbx@pali> (raw)
In-Reply-To: <1629929.m6cr89zbSo@natalenko.name>
[-- Attachment #1: Type: text/plain, Size: 3464 bytes --]
On Tuesday 21 November 2017 19:58:24 Oleksandr Natalenko wrote:
> Hi.
>
> On úterý 21. listopadu 2017 19:36:24 CET Pali Rohár wrote:
> > Ok, if wmi_requires_smbios_request is really doing nothing, then it
> > should not be used. It enables some QSET feature in Dell SMM mode which
> > is for 2 laptops.
>
> It is also used to filter 0xe025 key code which is generated by 3rd key and is
> visible via both atkbd and wmi:
>
> ===
> 343 if (type == 0x0000 && code == 0xe025 && !wmi_requires_smbios_request)
> 344 return;
> ===
>
> (see commit 13f5059ac5a6b)
Yes, this filtering is enabled and needed only when QSET feature was
activated. And is needed only for machines which need QSET feature.
> > Looks like that Dell Vostro 3360 have this meaning for multimedia keys:
> >
> > first key: Mobility Center
> > second key: Dell Support Center
> > third key: Dell Instant Launch Manager
> >
> > (same as other Vostro laptops)
>
> Likely, yes. At least, for Launch Manager (key "3") there is a record in the
> table:
>
> ===
> 135 /* Dell Instant Launch key */
> 136 { KE_KEY, 0xe025, { KEY_PROG4 } },
> ===
>
> As for Mobility Center, relevant key is commented out and has completely
> different keycode:
>
> ===
> 150 /* Untested, Windows Mobility Center button on Inspiron 7520 */
> 151 /* { KE_IGNORE, 0xe02a, { KEY_RESERVED } }, */
> ===
>
> For Support Center, it is not commented, but still reserved:
>
> ===
> 189 /* Dell Support Center key */
> 190 { KE_IGNORE, 0xe06e, { KEY_RESERVED } },
> ===
In both cases important is KE_IGNORE, which fully drops those events. So
IIRC we used KEY_RESERVED as it is irrelevant which key code is defined for
dropped events.
> > But do not know what KEY_* are used on other Vostro laptops for those
> > keys. It would be great to use same KEY_*...
>
> So, according to what I see above, it looks like KEY_PROG(X) pattern should be
> followed.
>
> > > Well, I've tried. The problem is that if I even configure this key
> > > via setkeycodes, it doesn't work.
> >
> > Hm... why it does not work?
> >
> > CCing Dmitry, can you tell us what needs to be done to "active" key from
> > AT Keyboard driver which prints following messages to dmesg?
>
> Just to note what I did. Here is my custom /etc/udev/hwdb.d/90-dell-
> vostro-3360.hwdb:
>
> ===
> evdev:atkbd:dmi:bvnDellInc.:bvrA18:bd09/25/2013:svnDellInc.:pnVostro3360:pvr:rvnDellInc.:rn0F5DWF:rvrA00:cvnDellInc.:ct8:cvr0.1:
> KEYBOARD_KEY_60=prog4
> ===
>
> Here is how this key press is being detected by evtest via atkbd:
>
> ===
> Event: time 1511289883.083968, type 4 (EV_MSC), code 4 (MSC_SCAN), value 60
> Event: time 1511289883.083968, type 1 (EV_KEY), code 203 (KEY_PROG4), value 2
> Event: time 1511289883.083968, -------------- SYN_REPORT ------------
> ===
So, it is working fine and there is no problem in kernel.
> But xev shows nothing when I press this key. Am I doing something wrong?
This is bug in X Server or so. You would need to remap keycode to
something different as a workaround for X Server.
> > In dell-wmi we filter all key events which are also delivered via PS/2
> > AT Keyboard driver. So filtering PS/2 keys instead of WMI is anti-design
> > solution.
>
> Well, sounds reasonable...
>
> Thanks.
>
> Regards,
> Oleksandr
--
Pali Rohár
pali.rohar@gmail.com
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]
next prev parent reply other threads:[~2018-01-27 14:06 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-20 15:08 Dell Vostro 3360 multimedia keys Oleksandr Natalenko
2017-11-20 17:05 ` Pali Rohár
2017-11-20 21:31 ` Oleksandr Natalenko
2017-11-21 13:51 ` Pali Rohár
2017-11-21 14:52 ` Oleksandr Natalenko
2017-11-21 18:36 ` Pali Rohár
2017-11-21 18:58 ` Oleksandr Natalenko
2018-01-27 14:05 ` Pali Rohár [this message]
2018-01-28 4:39 ` Dmitry Torokhov
2017-11-27 16:56 ` Mario.Limonciello
2017-11-27 18:32 ` Oleksandr Natalenko
2017-11-27 19:21 ` Mario.Limonciello
2017-11-21 14:52 ` Oleksandr Natalenko
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180127140557.xa3bdoouk5whhtbx@pali \
--to=pali.rohar@gmail.com \
--cc=andy@infradead.org \
--cc=dmitry.torokhov@gmail.com \
--cc=dvhart@infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mario_limonciello@dell.com \
--cc=mjg59@srcf.ucam.org \
--cc=oleksandr@natalenko.name \
--cc=platform-driver-x86@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).