Bug 500024 - disconnecting/reconnecting power causes opposite state
Summary: disconnecting/reconnecting power causes opposite state
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: DeviceKit-power
Version: 11
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Richard Hughes
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-05-10 08:55 UTC by Jason Haar
Modified: 2009-08-01 00:25 UTC (History)
7 users (show)

Fixed In Version: 2.26.3-1.fc11
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-07-16 07:15:39 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
devkit-power dump on AC power (1.83 KB, text/plain)
2009-05-10 20:06 UTC, Jason Haar
no flags Details
devkit-power dump on battery (1.65 KB, application/octet-stream)
2009-05-10 20:06 UTC, Jason Haar
no flags Details
devkit-power -d output on AC (Clevo M720R) (1.55 KB, text/plain)
2009-06-02 09:27 UTC, James
no flags Details
devkit-power -d output on battery (Clevo M720R) (1.55 KB, text/plain)
2009-06-02 09:28 UTC, James
no flags Details

Description Jason Haar 2009-05-10 08:55:13 UTC
Description of problem:

When I unplug my Dell D430 FC11-preview laptop from power, gnome-power-manager does a popup telling me it's now on AC, and my screen brightens. Plugging the power back in makes it tell me its now on battery, and the screen dims - the exact opposite to what it should be doing. This has happened several times after reboots now - so it's not a one-off for me. Also, I used to run FC10 and this didn't happen - gnome-power-manager worked fine.

Weird thing is: if I'm on battery (and the applet symbol erroneously shows I'm on AC) and I'm running low - the final warning still pops up to tell me I've got 4 minutes left! 

I've found that if I do it several times over a period of a minute or so, it eventually corrects itself.

Version-Release number of selected component (if applicable):


How reproducible:

every time

Steps to Reproduce:
1.pull out power cable - I'm told I'm now on AC
2. plug AC back in - I'm told I'm on battery
3.
  
Actual results:


Expected results:


Additional info:

Comment 1 Richard Hughes 2009-05-10 13:26:12 UTC
Is the line-power status from DeviceKit-power --dump correct with both states?

Comment 2 Jason Haar 2009-05-10 20:05:19 UTC
Attached are the dumps. When I am on battery, gnome-power-manager shows the AC power icon and placing the mouse over it states "Laptop battery fully charged". When I plug it back into AC, the icon changes to a battery and initially says "Laptop discharging", but after 30+ sec changes to battery-with-AC icon and says "Laptop battery XXXX until recharged"

/proc/acpi/ac_adapter/AC/state shows the correct state of the AC, but devkit-power-battery.log says "power supply: yes" which can't be right

Comment 3 Jason Haar 2009-05-10 20:06:05 UTC
Created attachment 343295 [details]
devkit-power dump on AC power

Comment 4 Jason Haar 2009-05-10 20:06:43 UTC
Created attachment 343296 [details]
devkit-power dump on battery

Comment 5 Richard Hughes 2009-05-11 07:23:05 UTC
Wow, there's some pretty crazy stuff going on there. Could you please get me the daemon verbose log of DeviceKit-power please? You can do this by (as root):

(attach AC, wait 1 minute)
killall devkit-power-daemon
/usr/libexec/devkit-power-daemon -v

and then wait for 1 minute, remove AC, wait 1 minute, insert AC, wait 1 minute.

Then please attach the logs to this bug please. Thanks.

Comment 6 Richard Hughes 2009-06-02 08:19:06 UTC
Also, can you please test the gnome-power-manager and DeviceKit-power in updates-testing. Thanks!

Comment 7 Jason Haar 2009-06-02 08:40:27 UTC
Sorry, I forgot I had this ticket in. The problem is sporadic. It actually happened yesterday (ie it went battery-mode on AC, and visa-versa), and in the end I rebooted to fix it!

Now when I try to make it happen, it refuses to screw up. Typical.

I'll hold off updating until I can get you a report

Jason

Comment 8 James 2009-06-02 09:27:01 UTC
With

gnome-power-manager-2.26.2-1.fc11.x86_64
DeviceKit-power-008-1.fc11.x86_64

my notebook (Clevo M720R) reports (sporadically) that the battery is fully charged when I unplug the mains supply, and that it's operating on battery power when plugged back in. gKrellm's monitor always reflects the correct state.

devkit-power -d output attached later.

Comment 9 James 2009-06-02 09:27:30 UTC
Created attachment 346217 [details]
devkit-power -d output on AC (Clevo M720R)

Comment 10 James 2009-06-02 09:28:04 UTC
Created attachment 346218 [details]
devkit-power -d output on battery (Clevo M720R)

Comment 11 Richard Hughes 2009-06-03 09:52:54 UTC
Can you try installing https://admin.fedoraproject.org/updates/F11/FEDORA-2009-5728 and then reboot please. If it fixes things, please report that as positive karma for the update. Thanks.

Comment 12 Bug Zapper 2009-06-09 15:35:27 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 11 development cycle.
Changing version to '11'.

More information and reason for this action is here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 13 How 2009-06-18 00:09:33 UTC
do you realize this one is a duplicate bug of 496418 to do with ac detection and therefore wrong popup messages.

already tried update FEDORA-2009-5728 dont work

This is also weird.
while AC on and devkit-power --monitor running, I start the login screen and it says:
"Device Changed: /org/freedsktop/DeviceKit/Power/devices/battery_BAT0" 
repeatedly. The cpu fan is at full speed non stop.

Comment 14 Jason Haar 2009-06-20 09:31:36 UTC
Update

I am on a fully updated FC11 and am currently typing in this comment from my Dell DC430 laptop - on battery - and after 30 minutes the icon says I'm on AC and the battery is still 100% full!

/proc/acpi/battery/BAT0/state shows the correct information.



This is with DeviceKit-power-008-1.fc11.i586

Comment 15 How 2009-06-21 03:02:10 UTC
yes of course, same here. Battery icon dont give correct reading and 99% of the time doesnt update, had to re-plug several times for it to react. ACPI on the other hand always shows updates promptly and shows correct information and never faulty. For certain is bug with Devicekit and gpm. 

I have conky always showing correct BAT info and react as fast windows power manager. GPM dont react at all. Unacceptable !

Comment 16 How 2009-06-22 22:55:02 UTC
you should try gnome-power-manager 2.27 in rawhide. works so far for me now. solves lot of issues.

Comment 17 James 2009-06-23 18:54:14 UTC
(In reply to comment #16)
> you should try gnome-power-manager 2.27 in rawhide. works so far for me now.
> solves lot of issues.  

Not for me.

Comment 18 Jason Haar 2009-06-26 21:13:43 UTC
Same here. I've upgraded to the rawhide release and yet after several reboots, it still says I'm on AC when I'm on battery. 

Also, I've just noticed it's completely wrong about the battery life too! Yesterday it told me the battery was about to run out of juice and so I shut down. However, when I next rebooted I happened to go into the BIOS where there's a Battery screen (Dell D430) and it said I still had 44% battery charge left!

Jason

Comment 19 Armijn Hemel 2009-07-02 09:24:10 UTC
Is this perhaps the same bug as 495002?

Comment 20 Fedora Update System 2009-07-06 11:28:36 UTC
gnome-power-manager-2.26.3-1.fc11 has been submitted as an update for Fedora 11.
http://admin.fedoraproject.org/updates/gnome-power-manager-2.26.3-1.fc11

Comment 21 James 2009-07-11 09:03:43 UTC
Still seems broken in gnome-power-manager-2.26.3-1.fc11.x86_64, DeviceKit-power-008-1.fc11.x86_64.

Comment 22 Fedora Update System 2009-07-11 16:57:16 UTC
gnome-power-manager-2.26.3-1.fc11 has been pushed to the Fedora 11 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update gnome-power-manager'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F11/FEDORA-2009-7424

Comment 23 Fedora Update System 2009-07-16 07:15:33 UTC
gnome-power-manager-2.26.3-1.fc11 has been pushed to the Fedora 11 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 24 Pedro Matiello 2009-07-17 04:10:52 UTC
I'm still experiencing the issue here.

Comment 25 How 2009-07-17 09:47:39 UTC
version 2.26.3-1.fc11 seemed improved over previous one but still the reaction to ac detection is still slow, it would take more than 10 seconds.

Comment 26 James 2009-07-28 10:03:06 UTC
Still present in gnome-power-manager-2.27.3-0.4.20090727git.fc12.x86_64.

Comment 27 How 2009-08-01 00:25:30 UTC
still shuts down when AC is connected


Note You need to log in before you can comment on or make changes to this bug.