Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ThinkPad X1C6] Error: discharge BAT0 malfunction #395

Closed
LinuxOnTheDesktop opened this issue Mar 19, 2019 · 9 comments
Closed

[ThinkPad X1C6] Error: discharge BAT0 malfunction #395

LinuxOnTheDesktop opened this issue Mar 19, 2019 · 9 comments

Comments

@LinuxOnTheDesktop
Copy link

LinuxOnTheDesktop commented Mar 19, 2019

[x] I've read and accepted the Bug Reporting Howto

Describe the bug

$  sudo tlp recalibrate
Setting temporary charge thresholds for BAT0:
  stop  = 100
  start =  96
Error: discharge BAT0 malfunction.

Expected behavior

Reclibration, with no error messages.

To Reproduce

Steps to reproduce the unexpected behavior:

  1. Does the problem occur on battery or AC or both?

AC; the relevant command is not intended to run on battery power.

  1. Actions to reproduce the behaviour

sudo tlp recalibrate

  1. Shell commands entered and their output

$ sudo tlp recalibrate
Setting temporary charge thresholds for BAT0:
stop = 100
start = 96
Error: discharge BAT0 malfunction.
4. Full output of tlp-stat via https://gist.github.com/ for all cases of 1

Instruction seems ambiguous. But here is output for ac and here is output for battery.

Additional context

Kernel: 5.0.2
OS: Linux Mint 19.1 x64
DE: Cinnamon
ThinkPad X1CG6

@linrunner linrunner changed the title Recalibration: 'Error: discharge BAT0 malfunction' [ThinkPad X1C6] Error: discharge BAT0 malfunction Mar 19, 2019
@linrunner
Copy link
Owner

Hi,

my X1C6 (current development machine for TLP) shows the same error – welcome to the club!

It occurs with tpacpi-bat and natacpi (kernel with patches for force_discharge). I guess the ACPI call 'BDSS' used for force_discharge was changed by Lenovo.

@LinuxOnTheDesktop
Copy link
Author

LinuxOnTheDesktop commented Mar 19, 2019

Much as I dislike Lenovo for its near total lack of support for desktop Linux, I do find that, if I use tlp 1.1-2 (an older version), then the calibration works.

Also: may I ask whether you have the touchpad-stops-working-after-S3-sleep problem? For, tlp is one of the many ingredients in that problem? (And yes I do have the latest firmware for everything and a recent kernel and I have tried various - many - workarounds.)

@linrunner
Copy link
Owner

linrunner commented Mar 19, 2019

I do find that, if I use tlp 1.1-2 (an older version), then the calibration works.

To my considerable surprise: you're right. I'll look into that. Maybe a timing issue ...

@linrunner linrunner added bug and removed won't fix labels Mar 19, 2019
linrunner added a commit that referenced this issue Mar 19, 2019
Problem: the X1C6's battery controller returns the "discharging"
status very late. Up to 10 seconds pass after force_discharge has
been set, but sometimes only one second. The behaviour is identical
for tpacpi-bat and natacpi.

Solution: extend the timeout from 5 to 15 secs. Write a '.'
every second while waiting.

Reference:
* #395
@linrunner
Copy link
Owner

Well, i think i fixed it. See the above commit for details.

Please test – packages here.

@LinuxOnTheDesktop
Copy link
Author

That seems to work: recalibration functions again. I did have trouble installing the .debs, though, probably at least partly because of bugginess in the gdebi installer.

@linrunner
Copy link
Owner

I keep this open as a notice.

@linrunner
Copy link
Owner

Released with 1.2.2

@frauhottelmann
Copy link

frauhottelmann commented May 27, 2019

I do have the same problem on my X240 with tlp 1.2.2:
AC | battery

It occurs with BAT1. I don't have a BAT0 installed.

@linrunner
Copy link
Owner

@frauhottelmann : different hardware = different problem. Please open your own issue. I also need the exact command that failed and all of it's output.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants