Bug#783264: Bug#783247: Please don't install acpid and acpi-support-base

2015-04-29 Thread Bjørn Mork
Wouter Verhelst wou...@debian.org writes:

 On Fri, Apr 24, 2015 at 10:07:36PM +0200, Marco d'Itri wrote:
  I'm not sure, if the acpi command line utility is that useful which
  would warrant having it installed by default. The attached patch drops
  it as well. Incidentally, this was also suggested for the laptop-task,
  which still pulls it in.
 The acpi package is *totally useless* and should be immediately dropped 
 from hw-detect and task-laptop.

 Disagree.

 - Acpi is a useful command-line tool to easily read values of things
   like battery life expectancy and other ACPI power-related values,
   without having to dig through files in /sys.

I'd have to disagree after trying it out just now.

For command like usage I am used to looking at the sysfs files, doing
something like

 bjorn@nemi:~$ grep . 
/sys/class/power_supply/BAT0/{energy_,voltage_,power_,alarm}*
 /sys/class/power_supply/BAT0/energy_full:3948
 /sys/class/power_supply/BAT0/energy_full_design:4320
 /sys/class/power_supply/BAT0/energy_now:3898
 /sys/class/power_supply/BAT0/voltage_min_design:1080
 /sys/class/power_supply/BAT0/voltage_now:12455000
 /sys/class/power_supply/BAT0/power_now:0
 /sys/class/power_supply/BAT0/alarm:1964000

which gives me a nice overview over the battery status.  Note that the
design values (both capacity and voltage) match the DMI data from the
battery:

 nemi:/tmp# dmidecode -t 22
 # dmidecode 2.12
 SMBIOS 2.4 present.
 
 Handle 0x0034, DMI type 22, 26 bytes
 Portable Battery
 Location: Rear
 Manufacturer: SANYO
 Name: 42T4643
 Design Capacity: 43200 mWh
 Design Voltage: 10800 mV
 SBDS Version: 03.01
 Maximum Error: Unknown
 SBDS Serial Number: 0097
 SBDS Manufacture Date: 2014-03-03
 SBDS Chemistry: LION
 OEM-specific Information: 0x


I agree that acpi would have been a useful tool if it provided the same
(or equivalent) information without having to know which sysfs
attributes to look at.  But it doesn't.  The view it presents is
confusing and plain wrong:

 bjorn@nemi:~$ acpi -i -b
 Battery 0: Unknown, 98%
 Battery 0: design capacity 3468 mAh, last full capacity 3169 mAh = 91%

So what happened to the capacities presented by the battery firmware?
Looks like they were converted from their native µWh values to mAh,
apparently using the current voltage for the conversion.  Anyone
remotely familiar with battery charging will see the problem...  The
rest can study the numbers after unplugging AC (repeated a number of
times with a second or two between to help illustrate the point):

 bjorn@nemi:~$ acpi -i -b
 Battery 0: Discharging, 98%, discharging at zero rate - will never fully 
discharge.
 Battery 0: design capacity 3468 mAh, last full capacity 3169 mAh = 91%
 bjorn@nemi:~$ acpi -i -b
 Battery 0: Discharging, 98%, 03:00:13 remaining
 Battery 0: design capacity 3509 mAh, last full capacity 3206 mAh = 91%
 bjorn@nemi:~$ acpi -i -b
 Battery 0: Discharging, 98%, 02:41:10 remaining
 Battery 0: design capacity 3523 mAh, last full capacity 3219 mAh = 91%
 bjorn@nemi:~$ acpi -i -b
 Battery 0: Discharging, 98%, 02:33:16 remaining
 Battery 0: design capacity 3530 mAh, last full capacity 3226 mAh = 91%
 bjorn@nemi:~$ acpi -i -b
 Battery 0: Discharging, 98%, 02:32:43 remaining
 Battery 0: design capacity 3524 mAh, last full capacity 3221 mAh = 91%


So why do both capacities *increase* after unplugging AC?  You would
expect them to be stable.  The problem is of course that the voltage
decreases.  And it will continue to do so, although not at the alarming
rate we see here, until AC power is plugged in again.

Where does this leave acpi?  Lying.  The battery design capacity was
never 3468, 3509, 3523, 3530 or 3524 mAh.  It is 43200 mWh.  No need to
mess with that.

acpi does indeed look like a useless tool, not even usable by the few of
us wanting to look at this stuff from the command line.


Bjørn


--
To UNSUBSCRIBE, email to debian-boot-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: https://lists.debian.org/87bni7gwfs@nemi.mork.no



Bug#783264: Bug#783247: Please don't install acpid and acpi-support-base

2015-04-29 Thread Wouter Verhelst
On Tue, Apr 28, 2015 at 11:34:36PM +0200, Marco d'Itri wrote:
 On Apr 28, Wouter Verhelst wou...@debian.org wrote:
 
  - Acpi is a useful command-line tool to easily read values of things
 So basically you are saying that it is common use case is laptops with 
 no good management GUI.

No. I am saying that it is a good *baseline* tool, which does not do
much harm in terms of disk space usage[1], and that I therefore don't
see why you want to throw it out.

 This is not enough to make it a candidate for magic installation by 
 hw-detect, but maybe you can persuade the task-laptop maintainer that it 
 is actually useful.

Or maybe you can persuade the task-laptop maintainer that the status quo
needs to be changed, and that what's currently happening is positively
harmful. I disagree with that.

Remember that task-desktop-* and task-laptop are separate. The acpi
tool will be installed even if task-desktop-whatever isn't, and there
are valid use cases for such installations; I've seen people take an old
laptop, put in a more recent disk, and use that as a home server (it
draws less power than an equally old desktop, and has a builtin UPS!).
Such an installation would not have or need a GUI, but could still use a
tool to query battery usage.

If you can show me where it does harm to keep the status quo of having
the acpi tool installed, I'll concede the point. So far, though, all
I've seen is you stating your opinion as fact. I'm not saying it's an
invalid opinion, but just stating out of the blue that acpi is totally
useless doesn't make it so.

[1]
wouter@gangtai:~$ apt-cache show acpi | grep -E '(Installed-Size|Depends)'
Installed-Size: 71
Depends: libc6 (= 2.7)

i.e., it only adds 71k to the set of Essential packages.

-- 
It is easy to love a country that is famous for chocolate and beer

  -- Barack Obama, speaking in Brussels, Belgium, 2014-03-26


-- 
To UNSUBSCRIBE, email to debian-boot-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: https://lists.debian.org/20150429175329.ga1...@grep.be



Bug#783264: Bug#783247: Please don't install acpid and acpi-support-base

2015-04-28 Thread Wouter Verhelst
On Fri, Apr 24, 2015 at 10:07:36PM +0200, Marco d'Itri wrote:
  I'm not sure, if the acpi command line utility is that useful which
  would warrant having it installed by default. The attached patch drops
  it as well. Incidentally, this was also suggested for the laptop-task,
  which still pulls it in.
 The acpi package is *totally useless* and should be immediately dropped 
 from hw-detect and task-laptop.

Disagree.

- Acpi is a useful command-line tool to easily read values of things
  like battery life expectancy and other ACPI power-related values,
  without having to dig through files in /sys.
- It provides more detailed information than most graphical interfaces
  that I've seen (but I'd be happy to be corrected).
- Its dependencies are fairly light, so it does little harm.
- As a command-line tool, it is useful even when no GUI is available
  (for whatever reason).

-- 
It is easy to love a country that is famous for chocolate and beer

  -- Barack Obama, speaking in Brussels, Belgium, 2014-03-26


-- 
To UNSUBSCRIBE, email to debian-boot-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: https://lists.debian.org/20150428082216.gb2...@grep.be



Bug#783264: Bug#783247: Please don't install acpid and acpi-support-base

2015-04-28 Thread Marco d'Itri
On Apr 28, Wouter Verhelst wou...@debian.org wrote:

 - Acpi is a useful command-line tool to easily read values of things
So basically you are saying that it is common use case is laptops with 
no good management GUI.
This is not enough to make it a candidate for magic installation by 
hw-detect, but maybe you can persuade the task-laptop maintainer that it 
is actually useful.

-- 
ciao,
Marco


pgpsztf8CA6UM.pgp
Description: PGP signature