All of lore.kernel.org
 help / color / mirror / Atom feed
From: Marc MERLIN <marc_powertop at merlins.org>
To: powertop@lists.01.org
Subject: Re: [Powertop] USB devices get wrong power use values
Date: Thu, 17 Oct 2013 17:24:41 -0700	[thread overview]
Message-ID: <20131018002441.GB5362@merlins.org> (raw)
In-Reply-To: 20131018000154.GA5362@merlins.org

[-- Attachment #1: Type: text/plain, Size: 4079 bytes --]

On Thu, Oct 17, 2013 at 05:01:54PM -0700, Marc MERLIN wrote:
> On Sun, Oct 13, 2013 at 09:22:12AM -0700, Marc MERLIN wrote:
> > On Sun, Oct 13, 2013 at 08:33:51AM -0700, Arjan van de Ven wrote:
> > > On 9/22/2013 4:54 PM, Marc MERLIN wrote:
> > > >So, I asked on the linux-usb list, and one thing I quickly found out is that the
> > > >Watt value given by powertop 2.4 is way off for USB devices:
> > > 
> > > what makes you think the value is off?
> > > 
> > > >>Power est.  Events/s    Category       Description
> > > >>   8.18 W    100.0%      Device         USB device: Yubico Yubikey II (Yubico)
> > > >>   8.13 W    100.0%      Device         USB device: Integrated Camera (Chicony Electronics Co., Ltd.)
> > > 
> > > having a USB device active also generally makes the CPU/etc use much more power,
> > > which Powertop "charges" to the USB device in question.
> > > 
> > > 8 Watts sounds entirely reasonable for that to me...
> > 
> > Aah, if the CPU gets involved, then yes, it's a bit more possible.
> > So, a simple USB keyboard that's unused can keep one core awake and burn 8
> > watts if something else goes wrong in the kernel to cause that?
> 
> So, I just upgraded to 3.11.5, and see things like this below. Can alsa sound
> really take 10W when I'm batteries?
> Let me put it another way, it just cannot be correct. Full power use is 15W and
> if you removed 10W for audio (I'm sure that's wrong) and 3W for wifi (that may be correct)
> it means my quad core laptop is running at 2W with the screen on?
> Not possible at all.

> So there has to be a bug in powertop 2.4 USB device power calculation.
> 
> For what it's worth, I got the data below right after running
> powertop --calibrate and letting it go through a full cycle.
> 
> ----------------------------------------------------------------------------
> The battery reports a discharge rate of 15.1 W
> The estimated remaining time is 4 hours, 53 minutes
> 
> Summary: 572.4 wakeups/second,  18.3 GPU ops/seconds, 0.0 VFS ops/sec and 8.3% CPU use
> 
> Power est.              Usage       Events/s    Category       Description
>   10.5 W    100.0%                      Device         Audio codec alsa:hwC0D0: thinkpad (Realtek)
>   3.10 W      7.0 pkts/s                Device         Network interface: wlan0 (iwlwifi)
>   772 mW     25.1 ms/s     208.4        Process        /usr/bin/enlightenment
>  13.4 mW      1.2 ms/s       8.5        Process        xfce4-terminal -T window10 --role=window10 --tab
> (...)
> ----------------------------------------------------------------------------

Just after I wrote this, I'm now seeing my yubikey back to 10W when it was
alsa holding the slot earlier.
 
> ----------------------------------------------------------------------------
The battery reports a discharge rate of 21.3 W
The estimated remaining time is 3 hours, 0 minutes

Summary: 2685.1 wakeups/second,  149.8 GPU ops/seconds, 0.0 VFS ops/sec and 31.2% CPU use

Power est.              Usage       Events/s    Category       Description
  10.4 W    100.0%                      Device         USB device: Yubico Yubikey II (Yubico)
  5.50 W     13.0%                      Device         Display backlight
  1.51 W     17.4 pkts/s                Device         Network interface: wlan0 (iwlwifi)
  566 mW     85.8 ms/s     1520.4       Process        /usr/bin/enlightenment
  109 mW    100.0%                      Device         Audio codec alsa:hwC0D0: thinkpad (Realtek)
 43.2 mW      5.2 ms/s      72.9        Process        xfce4-terminal -T window5 --role=window5
 25.9 mW      0.8 ms/s      14.8        Process        xfce4-terminal -T window9 --role=window9 --tab
> ----------------------------------------------------------------------------

I hope this is useful.

Marc
-- 
"A mouse is a device used to point at the xterm you want to type in" - A.S.R.
Microsoft is to operating systems ....
                                      .... what McDonalds is to gourmet cooking
Home page: http://marc.merlins.org/  

             reply	other threads:[~2013-10-18  0:24 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-18  0:24 Marc MERLIN [this message]
  -- strict thread matches above, loose matches on Subject: below --
2013-10-18  0:01 [Powertop] USB devices get wrong power use values Marc MERLIN
2013-10-13 22:38 Arjan van de Ven
2013-10-13 22:10 Marc MERLIN
2013-10-13 18:48 Arjan van de Ven
2013-10-13 16:22 Marc MERLIN
2013-10-13 15:33 Arjan van de Ven
2013-10-12 11:16 Sergey Senozhatsky
2013-09-22 23:54 Marc MERLIN

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20131018002441.GB5362@merlins.org \
    --to=powertop@lists.01.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.