Thread: [ibm-acpi-devel] HKEY version 0x200
Linux kernel driver for ThinkPad laptops
Brought to you by:
akw,
hmholschuh
|
From: Yrjan S. <yr...@st...> - 2016-04-03 13:30:16
|
Hi, I get the following message when booting 4.6-rc1 on my Thinkpad T460s: [ 4.067246] thinkpad_acpi: unknown version of the HKEY interface: 0x200 [ 4.068819] thinkpad_acpi: please report this to ibm...@li... I also have a number of hotkeys that will not work unless I change the code. The code changes I did to test this was very similar to this patch from 2014: https://sourceforge.net/p/ibm-acpi/mailman/ibm-acpi-devel/thread/531F0073.7060103%40canonical.com/#msg32086976 However, this patch was never merged and I cannot find the reason for this. Is there a chance this patch or a similar patch could be accepted? It seems that multiple of the newer Thinkpads report an HKEY interface version of 0x200, so this would likely be very useful to a number of users. On a sidenote: the feature "has_adaptive_kbd" gets set on this laptop (possibly all hkeyv 0x200 Thinkpads?). This laptop does not have an adaptive keyboard, so this seems unintentional. Would there be a way to better detect if there is an adaptive keyboard? - Yrjan |
|
From: Henrique de M. H. <hm...@hm...> - 2016-04-09 17:13:06
|
On Sun, 03 Apr 2016, Yrjan Skrimstad wrote: > I get the following message when booting 4.6-rc1 on my Thinkpad T460s: > [ 4.067246] thinkpad_acpi: unknown version of the HKEY interface: 0x200 > [ 4.068819] thinkpad_acpi: please report this to ibm...@li... > > I also have a number of hotkeys that will not work unless I change the > code. The code changes I did to test this was very similar to this > patch from 2014: > > https://sourceforge.net/p/ibm-acpi/mailman/ibm-acpi-devel/thread/531F0073.7060103%40canonical.com/#msg32086976 > > However, this patch was never merged and I cannot find the reason for > this. Is there a chance this patch or a similar patch could be > accepted? Yes, but it needs someone that accepts to be responsible for it (i.e. handle bug reports by helping with the testing) at least until I get a thinkpad that has HKEY 0x200... > It seems that multiple of the newer Thinkpads report an HKEY interface > version of 0x200, so this would likely be very useful to a number of > users. Yes. > On a sidenote: the feature "has_adaptive_kbd" gets set on this laptop > (possibly all hkeyv 0x200 Thinkpads?). This laptop does not have an > adaptive keyboard, so this seems unintentional. Would there be a way > to better detect if there is an adaptive keyboard? Probably it can be detected through either ACPI method calls, or the presence or non-presence of some ACPI identifier/method. Fix this requires the cooperation of someone with HKEY 0x200 and an adaptative keyboard, and someone with HKEY 0x200 without an adaptative keyboard. Also, it is possible that the thinkpad does have an adaptative keyboard as far as the firmware is concerned, but no hardware interfaces that expose it. In that case, you'd have to test the resulting behavior, and report it in details. Worse comes to worst case, we can add a whitelist/blacklist to the driver and keep it up-to-date. I hope the behavior is "it doesn't do anything nasty" so it becomes a cosmetic issue... -- "One disk to rule them all, One disk to find them. One disk to bring them all and in the darkness grind them. In the Land of Redmond where the shadows lie." -- The Silicon Valley Tarot Henrique Holschuh |
|
From: Yrjan S. <yr...@st...> - 2016-04-09 20:31:40
|
On Sat, Apr 09, 2016 at 01:54:01PM -0300, Henrique de Moraes Holschuh wrote: > On Sun, 03 Apr 2016, Yrjan Skrimstad wrote: > > I get the following message when booting 4.6-rc1 on my Thinkpad T460s: > > [ 4.067246] thinkpad_acpi: unknown version of the HKEY interface: 0x200 > > [ 4.068819] thinkpad_acpi: please report this to ibm...@li... > > > > I also have a number of hotkeys that will not work unless I change the > > code. The code changes I did to test this was very similar to this > > patch from 2014: > > > > https://sourceforge.net/p/ibm-acpi/mailman/ibm-acpi-devel/thread/531F0073.7060103%40canonical.com/#msg32086976 > > > > However, this patch was never merged and I cannot find the reason for > > this. Is there a chance this patch or a similar patch could be > > accepted? > > Yes, but it needs someone that accepts to be responsible for it (i.e. handle > bug reports by helping with the testing) at least until I get a thinkpad > that has HKEY 0x200... I would very much like to assist here. I'm currently using the patch on 4.6-rc2, but I wouldn't mind testing it anywhere else it might be needed. > > On a sidenote: the feature "has_adaptive_kbd" gets set on this laptop > > (possibly all hkeyv 0x200 Thinkpads?). This laptop does not have an > > adaptive keyboard, so this seems unintentional. Would there be a way > > to better detect if there is an adaptive keyboard? > > Probably it can be detected through either ACPI method calls, or the > presence or non-presence of some ACPI identifier/method. > > Fix this requires the cooperation of someone with HKEY 0x200 and an > adaptative keyboard, and someone with HKEY 0x200 without an adaptative > keyboard. > > Also, it is possible that the thinkpad does have an adaptative keyboard as > far as the firmware is concerned, but no hardware interfaces that expose it. > In that case, you'd have to test the resulting behavior, and report it in > details. Worse comes to worst case, we can add a whitelist/blacklist to the > driver and keep it up-to-date. I hope the behavior is "it doesn't do > anything nasty" so it becomes a cosmetic issue... I have not seen anything nasty that I suspect have anything to do with this other than errors like this: [ 1259.945126] thinkpad_acpi: Cannot read adaptive keyboard mode. and this: [ 1260.910584] thinkpad_acpi: Cannot set adaptive keyboard mode. |
|
From: Dennis W. <den...@se...> - 2016-04-13 13:01:47
|
Hi, I read your messages regarding hkeyv 0x200 Thinkpads... I would like to contribute to this topic as well. I believe (don't know, just guessing) that we should not make the feature "has_adaptive_kbd" depend on hkeyv 0x200. Instead we should use the "MHKA" method to evaluate if there is a flags mask set for the adaptive keyboard. I assume that if we pass "1" to the MHKA method we will get the hotkey_all_mask. If we pass "2" to the MHKA mask we will get the hotkey_all_adaptive_mask. Thats my assumption which is based on the observation of current Lenovo Skylake devices and the Thinkpad X1 Carbon (2014). I checked it with T460, T460p, T460s, T560, X260 and X1 Tablet (2016). All of these devices return 0 in that case. Only the X1 Carbon (2014) will return 0x1FFFFFFF. The Thinkpads L460 and L560 are not covered by this because they have hkeyv 0x100. I prepared a patch which does what I described above (attachment). This works fine in my case with kernel >= 4.3 until 4.6-rc3 for T460, T460p, T460s, T560, X260. All hkeyv 0x100 Thinkpads should not be affected by this change. Whats your opinion about this patch? Testing this with Lenovo Thinkpad X1 Tablet (2016) will make the hotkeys generate an event but currently there seems to be a mapping issue because the most events are "KEY_UNKNOWN". Additionally I observed that the new Skylake Thinkpads have no HKEY methods GDFR, STRW, GTRW, SBMI, SVOI, GVOI, GCGI, GHOV, NALL, SAPI, GAPI, SMNC, GMNC, SCMI, GCMI, SCMD, GCMD, GMMS, UAND, DGBL, SDHK, GDHK, SDFL, GDFL, SDAM, GDAM in contrast to X1 Carbon (2014) with HKEY 0x200. Best regards, Dennis > On Sat, Apr 09, 2016 at 01:54:01PM -0300, Henrique de Moraes Holschuh > wrote: > > On Sun, 03 Apr 2016, Yrjan Skrimstad wrote: > > > I get the following message when booting 4.6-rc1 on my Thinkpad T460s: > > [ 4.067246] thinkpad_acpi: unknown version of the HKEY interface: 0x200 > > > [ 4.068819] thinkpad_acpi: please report this to ibm-acpi-devel@... > > > > > > I also have a number of hotkeys that will not work unless I change the > > > code. The code changes I did to test this was very similar to this > > > patch from 2014: > > > > > > https://sourceforge.net/p/ibm-acpi/mailman/ibm-acpi-devel/thread/531F0073.7060103%40canonical.com/#msg32086976 > > > > > > However, this patch was never merged and I cannot find the reason for > > > this. Is there a chance this patch or a similar patch could be > > > accepted? > > > > Yes, but it needs someone that accepts to be responsible for it (i.e. handle > > bug reports by helping with the testing) at least until I get a thinkpad > > that has HKEY 0x200... > I would very much like to assist here. I'm currently using the patch on 4.6-rc2, but I wouldn't mind testing it anywhere else it might be needed. > > > On a sidenote: the feature "has_adaptive_kbd" gets set on this laptop > > > (possibly all hkeyv 0x200 Thinkpads?). This laptop does not have an > > > adaptive keyboard, so this seems unintentional. Would there be a way > > > to better detect if there is an adaptive keyboard? > > > > Probably it can be detected through either ACPI method calls, or the > > presence or non-presence of some ACPI identifier/method. > > > > Fix this requires the cooperation of someone with HKEY 0x200 and an > > adaptative keyboard, and someone with HKEY 0x200 without an adaptative > > keyboard. > > > > Also, it is possible that the thinkpad does have an adaptative keyboard as > > far as the firmware is concerned, but no hardware interfaces that expose it. > > In that case, you'd have to test the resulting behavior, and report it in > > details. Worse comes to worst case, we can add a whitelist/blacklist to the > > driver and keep it up-to-date. I hope the behavior is "it doesn't do > > anything nasty" so it becomes a cosmetic issue... > I have not seen anything nasty that I suspect have anything to do with this other than errors like this: > [ 1259.945126] thinkpad_acpi: Cannot read adaptive keyboard mode. > > and this: > > [ 1260.910584] thinkpad_acpi: Cannot set adaptive keyboard mode. |
|
From: Henrique de M. H. <hm...@hm...> - 2016-04-13 14:48:32
|
On Wed, Apr 13, 2016, at 09:28, Dennis Wassenberg wrote: > I would like to contribute to this topic as well. Thanks! > I believe (don't know, just guessing) that we should not make the > feature "has_adaptive_kbd" depend on hkeyv 0x200. Instead we should use > the "MHKA" method to evaluate if there is a flags mask set for the > adaptive keyboard. I assume that if we pass "1" to the MHKA method we > will get the hotkey_all_mask. If we pass "2" to the MHKA mask we will > get the hotkey_all_adaptive_mask. Thats my assumption which is based on > the observation of current Lenovo Skylake devices and the Thinkpad X1 > Carbon (2014). It might need to depend on both. Are there any adaptive keyboards with HKEY 0x100? If so, do they have the full ACPI interface for the adaptative keyboard, or do they like something, e.g. MHKA(0x2) ? Because HKEY returning 0x200 should actually be the marker that the MHK* methods have changed to support the adaptive keyboard better... > I checked it with T460, T460p, T460s, T560, X260 and X1 Tablet (2016). > All of these devices return 0 in that case. Only the X1 Carbon (2014) > will return 0x1FFFFFFF. The Thinkpads L460 and L560 are not covered by > this because they have hkeyv 0x100. Seems like it would also work if we detect by HKEY 0x200 + MHKA(2) != 0... > I prepared a patch which does what I described above (attachment). This > works fine in my case with kernel >= 4.3 until 4.6-rc3 for T460, T460p, > T460s, T560, X260. All hkeyv 0x100 Thinkpads should not be affected by > this change. Whats your opinion about this patch? I will likely be able to only look at it in detail during the weekend. > Testing this with Lenovo Thinkpad X1 Tablet (2016) will make the hotkeys > generate an event but currently there seems to be a mapping issue > because the most events are "KEY_UNKNOWN". Ok. This needs a fix, but I will only know which one after I have time to look over the current adaptive code and your patch in detail. We likely need to extend the keymap. > Additionally I observed that the new Skylake Thinkpads have no HKEY > methods GDFR, STRW, GTRW, SBMI, SVOI, GVOI, GCGI, GHOV, NALL, SAPI, > GAPI, SMNC, GMNC, SCMI, GCMI, SCMD, GCMD, GMMS, UAND, DGBL, SDHK, GDHK, > SDFL, GDFL, SDAM, GDAM in contrast to X1 Carbon (2014) with HKEY 0x200. Can you send to me in private mail the full acpidump (i.e. every table) and dmidecode output for all these thinkpads you tested with? Please cross-out any UUIDs and serial numbers... -- "One disk to rule them all, One disk to find them. One disk to bring them all and in the darkness grind them. In the Land of Redmond where the shadows lie." -- The Silicon Valley Tarot Henrique Holschuh |
|
From: Dennis W. <den...@se...> - 2016-04-14 10:16:48
|
Hi, On 13.04.2016 16:48, Henrique de Moraes Holschuh wrote: > On Wed, Apr 13, 2016, at 09:28, Dennis Wassenberg wrote: >> I would like to contribute to this topic as well. > > Thanks! > >> I believe (don't know, just guessing) that we should not make the >> feature "has_adaptive_kbd" depend on hkeyv 0x200. Instead we should use >> the "MHKA" method to evaluate if there is a flags mask set for the >> adaptive keyboard. I assume that if we pass "1" to the MHKA method we >> will get the hotkey_all_mask. If we pass "2" to the MHKA mask we will >> get the hotkey_all_adaptive_mask. Thats my assumption which is based on >> the observation of current Lenovo Skylake devices and the Thinkpad X1 >> Carbon (2014). > > It might need to depend on both. Are there any adaptive keyboards with > HKEY 0x100? > > If so, do they have the full ACPI interface for the adaptative keyboard, > or do they like something, e.g. MHKA(0x2) ? I don't know if there are any adaptive keyboards with HKEY 0x100. The only adaptive keyboard which I know is the X1 Carbon 2014. As far as I know this was the first HKEY 0x200 device. Thats why I assumed that the HKEY 0x200 is only a necessary condition. If HKEY 0x200 is used it is possible to query method MHKA with parameter 0x2. If there is something set != 0 this would be the sufficient condition for adaptive keyboards. But there might be other adaptive keybaords with HKEY 0x100, which I don't know? > > Because HKEY returning 0x200 should actually be the marker that the MHK* > methods have changed to support the adaptive keyboard better... > >> I checked it with T460, T460p, T460s, T560, X260 and X1 Tablet (2016). >> All of these devices return 0 in that case. Only the X1 Carbon (2014) >> will return 0x1FFFFFFF. The Thinkpads L460 and L560 are not covered by >> this because they have hkeyv 0x100. > > Seems like it would also work if we detect by HKEY 0x200 + MHKA(2) != > 0... > Unfortunately, I don't know the correct interpretation of MHKA(2). HKEY 0x200 + MHKA(2) != 0 is what I used in the patch I send yesterday. >> I prepared a patch which does what I described above (attachment). This >> works fine in my case with kernel >= 4.3 until 4.6-rc3 for T460, T460p, >> T460s, T560, X260. All hkeyv 0x100 Thinkpads should not be affected by >> this change. Whats your opinion about this patch? > > I will likely be able to only look at it in detail during the weekend. > >> Testing this with Lenovo Thinkpad X1 Tablet (2016) will make the hotkeys >> generate an event but currently there seems to be a mapping issue >> because the most events are "KEY_UNKNOWN". > > Ok. This needs a fix, but I will only know which one after I have time > to look over the current adaptive code and your patch in detail. > > We likely need to extend the keymap. > Ok, I will let you know the results of my investigation regarding the key mapping during the next days. >> Additionally I observed that the new Skylake Thinkpads have no HKEY >> methods GDFR, STRW, GTRW, SBMI, SVOI, GVOI, GCGI, GHOV, NALL, SAPI, >> GAPI, SMNC, GMNC, SCMI, GCMI, SCMD, GCMD, GMMS, UAND, DGBL, SDHK, GDHK, >> SDFL, GDFL, SDAM, GDAM in contrast to X1 Carbon (2014) with HKEY 0x200. > > Can you send to me in private mail the full acpidump (i.e. every table) > and dmidecode output for all these thinkpads you tested with? Please > cross-out any UUIDs and serial numbers... > |
|
From: Marco T. <ma...@3v...> - 2016-05-19 00:44:43
|
Dennis Wassenberg <dennis.wassenberg@...> writes: > >> I prepared a patch which does what I described above (attachment). This > >> works fine in my case with kernel >= 4.3 until 4.6-rc3 for T460, T460p, > >> T460s, T560, X260. All hkeyv 0x100 Thinkpads should not be affected by > >> this change. Whats your opinion about this patch? My T460p (with fully updated bios) doesn't seem to have this HKEY version (and I see it working fine), while the T460s has. > >> Testing this with Lenovo Thinkpad X1 Tablet (2016) will make the hotkeys > >> generate an event but currently there seems to be a mapping issue > >> because the most events are "KEY_UNKNOWN". > > > > Ok. This needs a fix, but I will only know which one after I have time > > to look over the current adaptive code and your patch in detail. > > > > We likely need to extend the keymap. > > > Ok, I will let you know the results of my investigation regarding the > key mapping during the next days. Hey, any news on this? It seems to fix my hotkeys for the T460s (like the missing Fn+4 or Fn+F[9-12]). |
|
From: Dennis W. <den...@se...> - 2016-05-19 05:06:32
|
Hi, On 19.05.2016 02:44, Marco Trevisan wrote: > Dennis Wassenberg <dennis.wassenberg@...> writes: >>>> I prepared a patch which does what I described above (attachment). This >>>> works fine in my case with kernel >= 4.3 until 4.6-rc3 for T460, T460p, >>>> T460s, T560, X260. All hkeyv 0x100 Thinkpads should not be affected by >>>> this change. Whats your opinion about this patch? > > My T460p (with fully updated bios) doesn't seem to have this HKEY version > (and I see it working fine), while the T460s has. I have no T460p available at the moment. I made the observation at a preproduction sample. Maybe there is something different at the final version. The L460 for example has KEY 0x100 too and worked out of the box. > >>>> Testing this with Lenovo Thinkpad X1 Tablet (2016) will make the hotkeys >>>> generate an event but currently there seems to be a mapping issue >>>> because the most events are "KEY_UNKNOWN". >>> >>> Ok. This needs a fix, but I will only know which one after I have time >>> to look over the current adaptive code and your patch in detail. >>> >>> We likely need to extend the keymap. >>> >> Ok, I will let you know the results of my investigation regarding the >> key mapping during the next days. > > > Hey, any news on this? > It seems to fix my hotkeys for the T460s (like the missing Fn+4 or Fn+F[9-12]). No, unfortunately there are no news on this. I as long as there is no upstream patch I will use this patch too. > > > ------------------------------------------------------------------------------ > Mobile security can be enabling, not merely restricting. Employees who > bring their own devices (BYOD) to work are irked by the imposition of MDM > restrictions. Mobile Device Manager Plus allows you to control only the > apps on BYO-devices by containerizing them, leaving personal data untouched! > https://ad.doubleclick.net/ddm/clk/304595813;131938128;j > _______________________________________________ > ibm-acpi-devel mailing list > ibm...@li... > https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel > |