Re: Battery information in sysfs for userspace tools

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

 



On dim, 2009-05-17 at 01:06 +0400, Alexey Starikovskiy wrote:
> Currently, sysfs interface repeats brokenness of /proc/acpi/battery 
> interface.

Hmmh, ok, but it seems to have change recently (since powertop and
acpitools are definitely wrong when it comes to that)

[…]
> The proper way to handle it is to check for 'energy_now' and if it is 
> present, look for 'power_now'. It should be
> present in 2.6.30 and later kernels (remaining time 
> energy_now/power_now). If it is not present (as in 2.6.29), then you 
> should assume that 'current_now' has value in uW, and remaining time
> is energy_now/current_now.
> If you have 'charge_now', remaining time is charge_now/current_now 
> without any complications.

Wow. Thanks for the info, that's definitely not really easily
guessable :) It'd be nice to have that documented somewhere until things
settle down a bit and the situation becomes unbroken.

Cheers,
-- 
Yves-Alexis

--
To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux