Welcome to our peer-to-peer forums, where owners help owners. Need help now? Visit eSupport here.

English Community

Linux Operating SystemsOther Linux Discussions
All Forum Topics
Options

407 Posts

03-06-2021

Germany

227 Signins

2420 Page Views

  • Posts: 407
  • Registered: ‎03-06-2021
  • Location: Germany
  • Views: 2420
  • Message 531 of 841

Re:T14 AMD battery drain in standby (Linux)

2021-07-11, 8:31 AM

@ CoranH wrote:

Just to add a bit of objective context to all the sleep drain numbers quoted in this thread. According to Microsoft, and how their Sleep Study tool reports sleep drain numbers:

>1wh = Red/High

0.33-1wh = Yellow/Moderate
<0.33wh = Green/Good

 

So current S0/Windows and S3/Linux numbers (1.26/1.67) are both well above what Microsoft consider "high", and in their highest category for drain.

Most (other) ThinkPads are bang on in the middle of moderate (around 0.6-0.7).

And if we can achieve numbers like @ahendriksen is seeing (what the rest of us can only dream of), then that would be borderline "Good".

 

Source:

https://docs.microsoft.com/en-us/windows-hardware/design/device-experiences/modern-standby-sleepstudy

 

Ok I got my P14s into Yellow/Moderate area, 7h S0ix sleep, with 0.761332W/h.

 

Some things I noticed:

 

Linux already fixing idle states ( firmware bug )

Firmware still is buggy with idle states I forced C3 from userspace before suspending to get these results.

CPU management ( like I noticed in my other tests )  is buggy too, I forced it to power save before suspending.

L0 probably is broken in some components or mismanaged, to somewhat workaround I run powertop with autotune

before suspending.

 

I do some more testing and force now _OSI to Linux, ( probably even by using a custom DSDT).

Also, I test that with my BAT disconnect method too.

 

I wonder if Lenovo is willing to replace my BAT, bc is basically toast already just alone from doing

unpaid debug work for them ;)

 

 

Reply
Options

37 Posts

09-08-2020

Germany

39 Signins

250 Page Views

  • Posts: 37
  • Registered: ‎09-08-2020
  • Location: Germany
  • Views: 250
  • Message 532 of 841

Re:T14 AMD battery drain in standby (Linux)

2021-07-11, 8:41 AM

I tested the workaround suggested by @blaumetallic 

 

https://forums.lenovo.com/t5/Other-Linux-Discussions/T14-AMD-battery-drain-in-standby-Linux/m-p/5037674?page=52#5371858

 

on my T14 AMD G1 and it actually seems to kind of work. I tried S3 only two times so far

(for 1.5h and for 10.5h) but in both cases the S3 drain was "only" 0.8 Wh. Which is much lower

than then the initial 1.5-2.0 Wh but also still almost twice of 0.3-0.4 Wh that 

@vitis and @ahendriksen observed with their P14s.

 

For the record, I got my T14 AMD G1 in September 2020, so it must be the very first hardware

revision that came out. I could totally imagine that Lenovo has several hardware revisions and that the S3 drain has

been adressed in the machines that were manufactured in the last months. And it may well
be that neither Mark nor the FW people he is communicating with are aware of that. Most likely
because there seems to be zero communication between different Lenovo units.

Reply
Options

3 Posts

07-01-2021

Netherlands

5 Signins

35 Page Views

  • Posts: 3
  • Registered: ‎07-01-2021
  • Location: Netherlands
  • Views: 35
  • Message 533 of 841

Re:T14 AMD battery drain in standby (Linux)

2021-07-11, 10:00 AM

So either I am missing something, or your P14s may have a different rev, with something fixed inside ;)

 

I rechecked my measurements this morning and they hold up. I do have a different
battery manufacturer though:

 

$ cat /sys/class/power_supply/BAT0/uevent
POWER_SUPPLY_NAME=BAT0
POWER_SUPPLY_TYPE=Battery
POWER_SUPPLY_STATUS=Discharging
POWER_SUPPLY_PRESENT=1
POWER_SUPPLY_TECHNOLOGY=Li-poly
POWER_SUPPLY_CYCLE_COUNT=7
POWER_SUPPLY_VOLTAGE_MIN_DESIGN=11520000
POWER_SUPPLY_VOLTAGE_NOW=11314000
POWER_SUPPLY_POWER_NOW=6030000
POWER_SUPPLY_ENERGY_FULL_DESIGN=51000000
POWER_SUPPLY_ENERGY_FULL=51650000
POWER_SUPPLY_ENERGY_NOW=22230000
POWER_SUPPLY_CAPACITY=43
POWER_SUPPLY_CAPACITY_LEVEL=Normal
POWER_SUPPLY_MODEL_NAME=5B10W518
POWER_SUPPLY_MANUFACTURER=Celxpert
POWER_SUPPLY_SERIAL_NUMBER= 2913

 

I forgot to include that certain modules must be enabled/disabled. Using

zcat /proc/config.gz 

I have: 

CONFIG_AMD_PMC=y
# CONFIG_HSA_AMD is not set
CONFIG_I2C_HID_ACPI=m 

 

 

Also, make sure to check out these files, to see if the system actually entered
the low power state: 

 

$ sudo cat /sys/kernel/debug/amd_pmc/smu_fw_info

=== SMU Statistics ===
Table Version: 3
Hint Count: 1
S0i3 Cycle Count: 1
Time (in us) to S0i3: 356331
Time (in us) in S0i3: 4339324

=== Active time (in us) ===
DISPLAY  : 0
CPU      : 244848
GFX      : 0
VDD      : 244843
ACP      : 0
VCN      : 0
DF       : 38457
USB0     : 2590
USB1     : 1456

$ sudo cat /sys/kernel/debug/amd_pmc/s0ix_stats
=== S0ix statistics ===
S0ix Entry Time: 49873754698680
S0ix Exit Time: 49873962986277
Residency Time: 4339324

 

 

Also, it takes ages to wake up and nvme still gives problems.

It takes ages to wake up for me as well. Fingerprint reader takes even longer. I
have an IO_PAGE_FAULT message/error for the nvme as well.

> What BIOS version are you running?

 

Version 1.32
Secure boot: off
Always on USB: off
Standby mode: Windows

 

> I run powertop with autotune before suspending.

 

This was not necessary for my results.

 

Reply
Options

37 Posts

05-06-2021

India

60 Signins

590 Page Views

  • Posts: 37
  • Registered: ‎05-06-2021
  • Location: India
  • Views: 590
  • Message 534 of 841

Re:T14 AMD battery drain in standby (Linux)

2021-07-11, 10:19 AM

I have a P14s AMD suffering the same battery drain issue during suspend(100% to 90% in around 7-8 hrs) and here are my results  (using Arch Linux with the latest 5.13.1 kernel)


❯ cat /sys/class/power_supply/BAT0/uevent
POWER_SUPPLY_NAME=BAT0
POWER_SUPPLY_TYPE=Battery
POWER_SUPPLY_STATUS=Full
POWER_SUPPLY_PRESENT=1
POWER_SUPPLY_TECHNOLOGY=Li-poly
POWER_SUPPLY_CYCLE_COUNT=79
POWER_SUPPLY_VOLTAGE_MIN_DESIGN=11550000
POWER_SUPPLY_VOLTAGE_NOW=13080000
POWER_SUPPLY_POWER_NOW=0
POWER_SUPPLY_ENERGY_FULL_DESIGN=50500000
POWER_SUPPLY_ENERGY_FULL=51480000
POWER_SUPPLY_ENERGY_NOW=51480000
POWER_SUPPLY_CAPACITY=100
POWER_SUPPLY_CAPACITY_LEVEL=Full
POWER_SUPPLY_MODEL_NAME=5B10W139
POWER_SUPPLY_MANUFACTURER=LGC
POWER_SUPPLY_SERIAL_NUMBER= 3458

 

I wonder should I try and get the battery replaced?

Reply
Options

5 Posts

05-19-2021

United States of America

8 Signins

45 Page Views

  • Posts: 5
  • Registered: ‎05-19-2021
  • Location: United States of America
  • Views: 45
  • Message 535 of 841

Re:T14 AMD battery drain in standby (Linux)

2021-07-11, 15:18 PM

To be frank I kind of gave up and just accepted that I screwed up buying a first gen unit. Like I never pre-order games for the same reasons. Except I didn't expect the same behavior from hardware manufacturer.

 

Anyhow, @osnix now I have more hope that community guys like you will figure something out. Can you elaborate please on what did you do?

Reply
Options

407 Posts

03-06-2021

Germany

227 Signins

2420 Page Views

  • Posts: 407
  • Registered: ‎03-06-2021
  • Location: Germany
  • Views: 2420
  • Message 536 of 841

Re:T14 AMD battery drain in standby (Linux)

2021-07-11, 15:34 PM

@ahendriksen,

 

Ty, for sharing what I've missed.

Now I am near your numbers.

 

Someone who was quiet on the thread :) contacted me so we test now with two P14s laptops.

 

Some remarks for @MarkRHPearson:

 

( I can only speak for my P14s, other models, revisions may see different numbers or even different bugs )

 

Some of my earlier findings are still true and to 100% firmware issues in my opinion:

 

1) Enabling TSME increases S{0ix,3} power consumption by up2 0.250W/h

 

2) Disabling devices increases S0ix power consummation by up2 !!!0.478W/h!!!

( not so high in S3, there it seems random )

Serious question, how is that even possible?

 

3) Letting USB always ON while 1) OR 2) results in random increase of power consummation

in either mode.

 

4) While 1) AND/OR 2) CPU power management suffers too by around 0.150W/h

 ( some workarounds from user space possible )

 

5) There is something wrong with the battery, PSU, or something in between firmware /components.

 I managed to get S3 down to 0.489W/h, which requires a battery disconnect with the right timing.

 

At this point, I will stop testing bc those are things everyone can reproduce, and focus on some patches, 

workarounds, so people with these broken laptops can have something working, at least in Linux.

 

To all others:

 

My S0ix testing is ongoing, and resume somewhat s*cks, but we are testing with two laptops now

so I expect more numbers in the following day(s).

 

I am on my hardware by 0.376W/h right now, the second laptop, newer revision, is by 0.353W/h.

 

I try to simulate short, long, mixed runs so it may take a while.

After that, I'm going to re-test the S3 battery disconnect method for S0ix too.

 

( And probably once I'm done I have to order a new battery :P )

 

If people want, I can provide an all-in-one patch against 5.13.1 and a small howto.

 

Best Regards,

 

Gabriel

 

Reply
Options

407 Posts

03-06-2021

Germany

227 Signins

2420 Page Views

  • Posts: 407
  • Registered: ‎03-06-2021
  • Location: Germany
  • Views: 2420
  • Message 537 of 841

Re:T14 AMD battery drain in standby (Linux)

2021-07-11, 15:44 PM

@ omdv wrote:

To be frank I kind of gave up and just accepted that I screwed up buying a first gen unit. Like I never pre-order games for the same reasons. Except I didn' expect the same behavior from hardware manufacturer.

 

Anyhow, @osnix now I have more hope that community guys like you will figure something out. Can you elaborate please on what did you do?

 

I can sure, just let me finish S0ix testing :-)

 

 

Reply
Options

407 Posts

03-06-2021

Germany

227 Signins

2420 Page Views

  • Posts: 407
  • Registered: ‎03-06-2021
  • Location: Germany
  • Views: 2420
  • Message 538 of 841

Re:T14 AMD battery drain in standby (Linux)

2021-07-11, 15:58 PM

@ Drishal wrote:

I have a P14s AMD suffering the same battery drain issue during suspend(100% to 90% in around 7-8 hrs) and here are my results  (using Arch Linux with the latest 5.13.1 kernel)


❯ cat /sys/class/power_supply/BAT0/uevent
POWER_SUPPLY_NAME=BAT0
POWER_SUPPLY_TYPE=Battery
POWER_SUPPLY_STATUS=Full
POWER_SUPPLY_PRESENT=1
POWER_SUPPLY_TECHNOLOGY=Li-poly
POWER_SUPPLY_CYCLE_COUNT=79
POWER_SUPPLY_VOLTAGE_MIN_DESIGN=11550000
POWER_SUPPLY_VOLTAGE_NOW=13080000
POWER_SUPPLY_POWER_NOW=0
POWER_SUPPLY_ENERGY_FULL_DESIGN=50500000
POWER_SUPPLY_ENERGY_FULL=51480000
POWER_SUPPLY_ENERGY_NOW=51480000
POWER_SUPPLY_CAPACITY=100
POWER_SUPPLY_CAPACITY_LEVEL=Full
POWER_SUPPLY_MODEL_NAME=5B10W139
POWER_SUPPLY_MANUFACTURER=LGC
POWER_SUPPLY_SERIAL_NUMBER= 3458

 

I wonder should I try and get the battery replaced?

 

Maybe, yes, maybe no.

 

We can try something, but you have to build your own kernel first.

 

You can write me a PM if you are willing to help testing :)

Reply
Options

15 Posts

06-22-2021

Germany

34 Signins

135 Page Views

  • Posts: 15
  • Registered: ‎06-22-2021
  • Location: Germany
  • Views: 135
  • Message 539 of 841

Re:T14 AMD battery drain in standby (Linux)

2021-07-11, 20:15 PM

@ osnix wrote:

...

( And probably once I' done I have to order a new battery :P )

 

If people want, I can provide an all-in-one patch against 5.13.1 and a small howto.

 

Best Regards,

 

Gabriel

 

 

an all in one patch and howto would be greatly appreciated ! id be eager to find out what the consumption is on the t14s with your patches !

 

im sure @MarkRHPearson will send a new battery to you.

Reply
Options

37 Posts

09-08-2020

Germany

39 Signins

250 Page Views

  • Posts: 37
  • Registered: ‎09-08-2020
  • Location: Germany
  • Views: 250
  • Message 540 of 841

Re:T14 AMD battery drain in standby (Linux)

2021-07-11, 20:51 PM

Now I've also tested the battery disconnect trick of @osnix : the S3 consumption after 11 hours still remains around

0.8 Wh. However, from what I understand, the emergency-reset hole from @blaumetallic 's workaround does nothing

else then disconnecting both batteries

https://support.lenovo.com/ec/en/solutions/ht510479-device-does-not-restart-after-bios-update/

 

So in this sense @osnix and @blaumetallic did the same thing by pressing the emergency button or using the battery
disconnect option in BIOS. And I can confirm that on T14 AMD G1 this indeed reduces the S3 drain. Hence, @osnix 's 

idea that the PSU firmware is faulty seems to make sense.

Reply
Forum Home

Community Guidelines

Please review our Guidelines before posting.

Learn More

Check out current deals!

Go Shop
X

Save

X

Delete

X

No, I don’t want to share ideas Yes, I agree to these terms