Bug 113056 - Battery status can't be detected
Summary: Battery status can't be detected
Status: RESOLVED FIXED
Alias: None
Product: SUSE LINUX 10.0
Classification: openSUSE
Component: Mobile Devices (show other bugs)
Version: Beta 3
Hardware: Other All
: P5 - None : Normal
Target Milestone: ---
Assignee: Thomas Renninger
QA Contact: E-mail List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-08-25 16:00 UTC by Takashi Iwai
Modified: 2006-02-13 16:25 UTC (History)
2 users (show)

See Also:
Found By: Other
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments
Output of lshal (72.58 KB, text/plain)
2005-08-25 19:22 UTC, Takashi Iwai
Details
/proc/acpi/battery/BAT0/info (425 bytes, text/plain)
2005-08-26 10:22 UTC, Takashi Iwai
Details
/proc/acpi/battery/BAT0/state (195 bytes, text/plain)
2005-08-26 10:23 UTC, Takashi Iwai
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Takashi Iwai 2005-08-25 16:00:59 UTC
The battery status can't be detected properly with beta3 kernel on my laptop
AVERATEC AV3360.
kpowersave shows correctly whether the cable is plugged or not, but it shows
either battery 1% or else.

Did work fine with beta2.
Comment 1 Stefan Behlert 2005-08-25 16:18:33 UTC
Strange. Any idea, Thomas? 
Comment 2 Danny Al-Gaaf 2005-08-25 19:17:39 UTC
please add output of lshal.
Comment 3 Takashi Iwai 2005-08-25 19:22:02 UTC
Created attachment 47659 [details]
Output of lshal
Comment 4 Holger Macht 2005-08-25 21:16:54 UTC
Can you also please post the output of /proc/acpi/battery/*/state and
/proc/acpi/battery/C1B3/info ?
Comment 5 Takashi Iwai 2005-08-26 10:22:51 UTC
Created attachment 47741 [details]
/proc/acpi/battery/BAT0/info
Comment 6 Takashi Iwai 2005-08-26 10:23:18 UTC
Created attachment 47742 [details]
/proc/acpi/battery/BAT0/state
Comment 7 Takashi Iwai 2005-08-26 10:26:38 UTC
The proc directory is only /proc/acpi/battery/BAT0, not C1B3.

I found the following warnings/errors in syslog:

[powersave]: WARNING (initHal:59) could not init hal library: (null)
[powersave]: ERROR (getBatteryDetailedInfo:50) Could not get list of batteries
in system: The name org.freedesktop.Hal was not provided by any .service files

The last one is repeated 4 times.

Also, I found that the battery status was once displayed correctly somehow.  But
after reboot, it's broken again.
Comment 8 Holger Macht 2005-08-26 10:35:59 UTC
Of course I ment the battery in your system below /proc/acpi/battery/BAT0,
sorry, my fault.

state and info file seems ok. So once again, connection to hal seems to be the
problem. But maybe the above mentioned warning and error was during booting,
which is known and not critical.

Can you please rcpowersaved stop, rchal stop, rchal start wait a second and
rcpowersaved start?

After that:
Does /var/log/messages tell anything suspicious?
Is powersave -b and powersave -d showing somehow correct values now?
Comment 9 Takashi Iwai 2005-08-26 10:44:48 UTC
The stop -> start procedure helps.  Now kpowersave shows the correct status.

I see warnings:

[powersave]: WARNING (filter_function:250) Received message from invalid interface

(repeated twice)
Comment 10 Holger Macht 2005-08-29 08:18:09 UTC
So I have no clue at the moment what went wrong. Please try again with beta 4.
It is also possible that it lasts up to 2 Minutes after boot until the correct
information is available.
Comment 11 Takashi Iwai 2005-08-29 15:30:32 UTC
I found /proc/acpi/battery/BAT0/status shows also incorrect values.  So, the
problem might be in ACPI kernel support.

Nevertheless, reading info and status proc files takes 2 seconds (for each).
Is it normal?
Comment 12 Forgotten User ZhJd0F0L3x 2005-08-29 18:49:47 UTC
no, please try ec_burst={0,1} and see if it makes a difference. This is an ACPI
problem.
Comment 13 Takashi Iwai 2005-08-30 09:29:06 UTC
ec_burst=0 seems better for reading proc files.
Comment 14 Takashi Iwai 2005-08-30 11:18:35 UTC
The status is shown correclty after booting with ec_burst=0.  So, this looks
like the culprit.
Comment 15 Ulrich Lange 2005-08-31 03:30:31 UTC
I have a similar problem with a notebook HP Omnibook 6100, 1 Ghz
After plug off the indicator from kpowersave does´nt changed to battery status.
After 10 minutes I started kpowersave and changed "SetCPU Frequence Policy" from
"Dynamic" to "Performance".
After approx. 2 minutes the indicator changed to status battery with showing
95%. This status does´nt changed over testing 15 minutes.
After coldstart the status of the battery was 74%.
After plug in the indicator changed to plugged and battery loading and changed
to 80% and will never show more.
After a next cold start the status was 95%.

In logfile messages I can find some errors like:
Aug 31 08:27:30 linux [powersave]: ERROR (getBatteryDetailedInfo:50) Could not
get list of batteries in system:
The name org.freedesktop.Hal was not provided by any .service files

/proc/acpi/battery/BAT0/status was already identical to kpowersave information
Comment 16 Takashi Iwai 2005-09-01 15:40:26 UTC
ec_burst=0 is still required on beta4, too.

Comment 17 Holger Macht 2005-09-01 15:49:36 UTC
Ok. I do not really know to whom to assign this bug then. Taking trenn, he
surely knows more... ;-)
Comment 18 Thomas Renninger 2005-10-07 12:51:37 UTC
Is this one still valid? There was an enhancement of ec_burst mode in RCx (irqs
not disabled any more). Can you retry without ec_burst mode param, please.
Comment 19 Takashi Iwai 2005-10-07 14:34:07 UTC
Well, it seems becoming worse after RC1.

On 2.6.13-8 (RC1) kernel, ec_burst=0 works.

time cat /proc/acpi/battery/BAT0/state -> 0.06sec

On 2.6.13-15 (final), regardless of ec_burst=0 or not, it results in 0.5 to 1.4
sec per read...
Comment 20 Holger Macht 2006-02-13 11:28:41 UTC
Still the case with 10.1 Beta3 or even with a KOTD?
Comment 21 Takashi Iwai 2006-02-13 16:25:34 UTC
The latest kernel seems working fine.  Thanks.