Re: [External] Re: [PATCH v5] platform/x86: thinkpad_acpi: lap or desk mode interface

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Den mån 3 aug. 2020 kl 16:27 skrev Mark Pearson <markpearson@xxxxxxxxxx>:
>
> Hi Elvis,
>
> On 8/3/2020 9:20 AM, Elvis Stansvik wrote:
> >
> > Den sön 2 aug. 2020 kl 23:10 skrev Elvis Stansvik
> > <elvstone@xxxxxxxxx>:
> >>
> >> (Apologies in advance for missing In-Reply-To header in this
> >> reply. I subscribed to the list just now.)
> >>
> >> Den fre 3 juli 2020 kl 01:24 skrev Mark Pearson
> >> <markpearson@xxxxxxxxxx>:
> >>> Newer Lenovo Thinkpad platforms have support to identify whether
> >>> the system is on-lap or not using an ACPI DYTC event from the
> >>> firmware.
> >>>
> >>> This patch provides the ability to retrieve the current mode via
> >>> sysfs entrypoints and will be used by userspace for thermal mode
> >>> and WWAN functionality
> >>
> >> I tried the patch out on my X1C6 (20KH007BMX), running Lenovo
> >> firmware version 0.1.49.
> >>
> >> The sysfs path /sys/devices/platform/thinkpad_acpi/dytc_lapmode is
> >> showing up, but it's reporting 0 regardless if the laptop is in my
> >> lap or on a desk.
> >>
> >> I tested this by having the laptop in my lap for five minutes, and
> >> then on a desk for five minutes. The value reported through
> >> /sys/devices/platform/thinkpad_acpi/dytc_lapmode was always 0.
> >>
> Thanks for the update.
> The X1C6 doesn't have support for the new thermal mode implementation so
> I'm wondering if the lapmode being available could be related to the
> version of DYTC is available. I'll check with the firmware team and get
> back to you on that - they hadn't listed it to me as a limitation
> previously and unfortunately I don't have an X1C6 so didn't test on that
> platform.
>
> As a note - the lapmode is primarily for the thermal modes (it is also
> being used for WWAN power control but that is not supported for Linux on
> the X1C6 either for other reasons). I'm afraid the interface is of
> limited use to you anyway....

Thanks Mark. I know the X1C6 firmware did not get the new thermal mode
implementation, but thought that I would still be able to query its
lap mode.

The reason I wanted query the lap mode is actually because I'm trying
to help Matthew Garrett out in adding support for the adaptive DPTF
performance policy on the thermald side, instead of on the firmware
side like Lenovo decided to do for more recent models. See that effort
here https://github.com/mjg59/thermal_daemon/issues/7). We were
surprised to find that all of the OEM conditions in the APCT table
remained unchanged when the laptop was taken between lap and desk. So
I started suspecting that perhaps the X1C6 and its firmware simply
does not have the ability to detect lap vs desk. That's why I wanted
to use this patch to query the lap mode, as a debugging aid.

If X1C6 does not have the ability to detect lap mode, then that would
obviously explain why the firmware does not change any APCT condition
when put on/off lap, and any effort to get adaptive performance policy
working on the thermald side is probably doomed :(

Elvis

>
> Mark


_______________________________________________
ibm-acpi-devel mailing list
ibm-acpi-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/ibm-acpi-devel




[Index of Archives]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Photo]     [Yosemite Photos]     [Yosemite Advice]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]

  Powered by Linux