maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Nokia N900 (https://talk.maemo.org/forumdisplay.php?f=44)
-   -   [HELP] 50% CPU Use When "Off", Constant CPU Use ~10% (https://talk.maemo.org/showthread.php?t=69219)

Switch_ 2011-02-01 12:33

[HELP] 50% CPU Use When "Off", Constant CPU Use ~10%
 
I have searched as I recall seeing recently a thread where someone else had the same 50% CPU Use when device is off reported through Battery Graph but I can't find the bloody thread..... As a last resort I am positing this new thread with the clue in the title, so that future searches may throw it up faster.

Please see the attached "Battery Graph snapshot;

http://i208.photobucket.com/albums/b...0201112454.png

Ok, so for the past week you can see constant CPU usage - not massively bothered about this, probably got some daemons and widgets constantly churning through the proc, and used to it at this point. Would be nice to resolve, but that's very much secondary.

However, when you scroll to the right hand side of the graph and check out the time period between 12am and 6am this morning you see a rapid reduction in mAh, caused by having the bleeding edge WiFi drivers still running in the background - but at 4am when my phone was complaining of low battery I got up, got the charger, switched it off and plugged it in next to my bed. From the moment I switched it off, I had 50% processor usage until the moment I switched it back on.....

Now that's wierd. Any comments, explanations, things to try out, or iser people out there who can explain this....? TIA.....

ndi 2011-02-01 14:59

Re: [HELP] 50% CPU Use When "Off", Constant CPU Use ~10%
 
Try searching forums for Conky, top and tracker.

E.g., searching for "conky battery" got me 3 threads about the issue in the first page (I have large pages).

I'm a bait clumsy now, I'm mobile, but search works.

vi_ 2011-02-01 15:19

Re: [HELP] 50% CPU Use When "Off", Constant CPU Use ~10%
 
also grap powertop from development repos and post output. That will give us a clear output of what is going on. Also run 'top' as root, organise by cpu and write down the process you see chewing up power the most.

Further to this what kernel are you using?

We need hard info bro!

Switch_ 2011-02-01 15:33

Re: [HELP] 50% CPU Use When "Off", Constant CPU Use ~10%
 
Thanks lads for the replies, although I fail to see what goodness either powertop, htop or top would be able to deliver considering the damn thing was switched off, ie; hard off, not soft off, loooong press of power button!!! I'll get the apps down and give you some more info.

@ndi, I'm like you mate, I like to keep the forums clean, but the booleans I looked for were more along the lines of "50% CPU when switched off", 50% CPU Use charging, %0% CPU use idle" etc as I know I saw a thread with that in it but I couldn't find it for the life of me. 40 minutes searching TALK is enough for anyone I would say.....

Running on Titans kernel-power 46 from extras-devel, modified with the bleeding edge WiFi driver mods from lxp.

top from root output:

Code:

Mem: 234408K used, 11004K free, 0K shrd, 1936K buff, 76744K
CPU: 15.3% usr 10.0% sys  0.0% nice 74.6% idle  0.0% io  0.
Load average: 1.27 0.68 0.90
  PID  PPID USER    STAT  RSS %MEM %CPU COMMAND
 1297  1189 user    R    13244  5.3  7.0 /usr/bin/hildon-ho
 1035  701 root    S <  15324  6.2  5.1 /usr/bin/Xorg -log
 1300  1189 user    S    9792  3.9  3.5 /usr/bin/hildon-de
 1291  1189 user    S    12148  4.9  2.1 /usr/bin/hildon-st
  944    1 pulse    S <  3200  1.3  1.9 /usr/bin/pulseaudi
 8759  1189 user    S    10240  4.1  1.3 /usr/bin/osso-xter
 8864  8840 root    R      740  0.3  0.9 top
  968  701 root    S <  2312  0.9  0.7 /sbin/mce --force-
 8766    1 root    S    2880  1.1  0.5 /usr/sbin/fmtxd
  765    1 messageb S <  2032  0.8  0.3 /usr/bin/dbus-daem

powertop from root output:
Code:

Nokia-N900:~# powertop
Powertop 1.13.3
status: Unknown job: pmtrackerdaemon
Sleeping for 11 seconds before sampling
Collecting data for 30 seconds
Sample interval was 00m 30s 16510us

C#      | Ratio  | Avg/dura | Frequency | Ratio
--------+--------+----------+-----------+--------+
    C0 |  21.1% |          |  1150 MHz |  nan% |
    C1 |  0.5% |    0.5ms |
    C2 |  78.3% |    4.0ms |
    C3 |  0.0% |    2.1ms |
    C4 |  0.0% |          |

IRQ#    | Activity  | Type          | Name
--------+------------+----------------+---------------------------
    61 |      11953 |          INTC | i2c_omap
    37 |      5036 |          INTC | gp
    11 |      4211 |          INTC | prcm
    56 |      2911 |          INTC | i2c_omap
    57 |        257 |          INTC | i2c_omap
    21 |        196 |          INTC | SGX
    12 |        65 |          INTC | DMA
    86 |        64 |          INTC | mmc1
    225 |        11 |          GPIO | omap2-onenand
    67 |          5 |          INTC | ssi_p1_mpu_irq0
    71 |          4 |          INTC | ssi_gdd
    202 |          3 |          GPIO | wl1251
    311 |          2 |          GPIO | ssi_p1_cawake_gpio

PID#    | Activity  | Name          | Function Entry (Expire)
--------+------------+----------------+---------------------------
      0 |      3726 |  <kernel core> | tick_nohz_restart_sched_tick (tick_sched_timer)
  1297 |      1146 |    hildon-home | schedule_hrtimeout_range (hrtimer_wakeup)
    38 |        192D|            awk | cpufreq_governor_dbs (delayed_work_timer_fn)
    968 |        138 |            mce | schedule_hrtimeout_range (hrtimer_wakeup)
  1291 |        60 |hildon-status-m | schedule_hrtimeout_range (hrtimer_wakeup)
    740 |        33 |      bme_RX-51 | sys_timer_settime (posix_timer_fn)
  8759 |        18 |    osso-xterm | schedule_hrtimeout_range (hrtimer_wakeup)
    740 |        18 |      bme_RX-51 | schedule_timeout (process_timeout)
  1260 |        15 |          iphbd | schedule_hrtimeout_range (hrtimer_wakeup)
    591 |        13 |          mmcqd | schedule_timeout (process_timeout)
    591 |          6 |          mmcqd | queue_delayed_work (delayed_work_timer_fn)
  1035 |          4 |          Xorg | queue_delayed_work (delayed_work_timer_fn)
    968 |          4 |            mce | tsc2005_start_scan (tsc2005_esd_timer_handler)
  8873 |          4 |      browserd | futex_wait (hrtimer_wakeup)
  1035 |          3 |          Xorg | hrtimer_start (it_real_fn)
    992 |          3 |      sgx_perf | queue_delayed_work (delayed_work_timer_fn)
    689 |          3 |          dsme | do_nanosleep (hrtimer_wakeup)
  8605 |          3 |        wl12xx | queue_delayed_work (delayed_work_timer_fn)
    689 |          3 |          dsme | __enqueue_rt_entity (sched_rt_period_timer)
      1 |          3D|  <kernel core> | queue_delayed_work (delayed_work_timer_fn)
  8605 |          2 |        wl12xx | schedule_timeout (process_timeout)
    740 |          2 |      bme_RX-51 | do_nanosleep (hrtimer_wakeup)
      0 |          2 |  <kernel core> | queue_delayed_work (delayed_work_timer_fn)
    716 |          2D|<kernel module> | queue_delayed_work (delayed_work_timer_fn)
    30 |          2 |          mount | setup_wb_timer (wb_timer_fn)
  1349 |          1 |      wlancond | ieee80211_ioctl_siwpower (ieee80211_dynamic_ps_timer)
  1073 |          1 | hald-addon-bme | schedule_hrtimeout_range (hrtimer_wakeup)
  1367 |          1 |  BatteryGraphd | schedule_timeout (process_timeout)
    591 |          1 |          mmcqd | schedule_timeout (process_timeout)
  1367 |          1 |  BatteryGraphd | ubifs_wbuf_write_nolock (wbuf_timer_callback_nolock)
    14 |          1 |        pdflush | blk_plug_device (blk_unplug_timeout)
  8897 |          1 |      powertop | do_nanosleep (hrtimer_wakeup)

Power domain activity breakdown
Domain  | % of time spent in states
--------+---------+---------+---------+---------+----------
usbhost |OFF: 100%|RET:  0%|INA:  0%| ON:  0%| now:(OFF)
    sgx |OFF:  81%|RET:  0%|INA:  0%| ON:  18%| now:(OFF)
    per |OFF:  0%|RET:  76%|INA:  0%| ON:  23%| now:(ON)
    dss |OFF:  0%|RET:  0%|INA:  0%| ON: 100%| now:(ON)
    cam |OFF: 100%|RET:  0%|INA:  0%| ON:  0%| now:(OFF)
  core |OFF:  0%|RET:  0%|INA:  61%| ON:  38%| now:(ON)
  neon |OFF:  0%|RET:  0%|INA:  76%| ON:  23%| now:(ON)
    mpu |OFF:  0%|RET:  0%|INA:  76%| ON:  23%| now:(ON)
  iva2 |OFF: 100%|RET:  0%|INA:  0%| ON:  0%| now:(OFF)

Clock activity breakdown at end of period
Domain  | Active clocks
--------+---------------+---------------+------------------
  core |          SDRC | HSOTGUSB_IDLE |      OMAPCTRL
        |    MAILBOXES |
  wkup |          GPT1 |      32KSYNC |        GPIO1
        |
  ckgen |          CORE |          PERI |          96M
        |          48M |          12M |          54M
        |      EMU_CORE |
    dss |      DSS_IDLE
    per |        GPIO2 |        GPIO3 |        GPIO4
        |        GPIO5 |        GPIO6 |

Total wakeups  30130, 1004.3/s | IRQ 24718, 823.9/s | Timers 5412, 180.4/s
HW wakeups      115,  3.8/s |    Real gp_timers expired  172,  5.7/s
Nokia-N900:~#

Do you want to see these outputs with as many other processes killed as possible, as these wefre taken just now with WiFi connected, web open, FAM open etc...?

Switch_ 2011-02-01 18:49

Re: [HELP] 50% CPU Use When "Off", Constant CPU Use ~10%
 
unethical I know but buuuump!

vi_ 2011-02-01 19:11

Re: [HELP] 50% CPU Use When "Off", Constant CPU Use ~10%
 
oops, should have seen that. does it really matter if your cpu is running while charging? mine says that somtimes too. perhaps it is a bug in batterygraph...

I think a more serious damage is you frankly unbelievable 30000 wake ups a second on powertop! do you have a battery life of about 15 minutes?

Switch_ 2011-02-02 07:50

Re: [HELP] 50% CPU Use When "Off", Constant CPU Use ~10%
 
I do have a relatively poor battery life - some people say that they can get 36 hours out of their phone but mine, lucky to get 24 hours to be honest.

Any ideas what could be causing it....?

vi_ 2011-02-02 08:11

Re: [HELP] 50% CPU Use When "Off", Constant CPU Use ~10%
 
I can get a full day, connected to the net all day (albeit through wifi with touches of 3G when I am outta range).

As I dont know your particular setup this could be tough however I do have a penchant for battery life extension.

This is a radical approach but can you give me the powertop output from about 3 minutes after a fresh reboot? I want you to ONLY load xterm, start powertop then quickly press the screen lock key and leave it for 41 seconds. Do this with wifi disconnected and on 2G mode.

The reason I ask for this is I am familiar with what the device should show when idiling with nothing.

From the above PT there are some bad things a-foot. The fact your CPU never reaches C4 sleep and you have over 15000 wakeups on the I2C bus means you phone is never going to sleep. This in turn is face r*ping your battery life.

Also I checked 'charging while turned off' on my phone last night and the CPU was also being used 50% so I wouldnt worry about that so much.

Switch_ 2011-02-02 08:52

Re: [HELP] 50% CPU Use When "Off", Constant CPU Use ~10%
 
Nice one fella. Here's the powertop output (bearing in mind I have lots of widgets like pedometer / digital clock that are updating every n milliseconds on my desktop(s), three minutes after boot once system has settled in straight GSM without WiFi or any other tethered connections. Bleeding edge drivers are not loaded either. Standard O/C, 250Mhz lower and 1Ghz higher clock speeds on CPU. Switch to N900 for ouput, will update post in about 5 minutes...............

EDIT: Powertop output from device;

Code:

Powertop 1.13.3
status: Unknown job: pmtrackerdaemon
Sleeping for 11 seconds before sampling
Collecting data for 30 seconds
Sample interval was 00m 30s 28839us

C#      | Ratio  | Avg/dura | Frequency | Ratio
--------+--------+----------+-----------+--------+
    C0 |  0.8% |          |  1150 MHz |  nan% |
    C1 |  0.0% |    0.2ms |
    C2 |  3.7% |    7.7ms |
    C3 |  27.4% |  191.4ms |
    C4 |  68.1% |  817.6ms |

IRQ#    | Activity  | Type          | Name
--------+------------+----------------+---------------------------
    37 |        211 |          INTC | gp
    11 |        203 |          INTC | prcm
    56 |        125 |          INTC | i2c_omap
    57 |        34 |          INTC | i2c_omap
    21 |        10 |          INTC | SGX
    12 |          5 |          INTC | DMA
    225 |          4 |          GPIO | omap2-onenand

PID#    | Activity  | Name          | Function Entry (Expire)
--------+------------+----------------+---------------------------
      0 |        116 |  <kernel core> | tick_nohz_restart_sched_tick (tick_sched_timer)
    38 |        48D|            awk | cpufreq_governor_dbs (delayed_work_timer_fn)
  1274 |        30 | hildon-desktop | schedule_hrtimeout_range (hrtimer_wakeup)
  1406 |        29 |          fmtxd | schedule_hrtimeout_range (hrtimer_wakeup)
  1588 |        19 |    osso-xterm | schedule_hrtimeout_range (hrtimer_wakeup)
    732 |          8 |      bme_RX-51 | sys_timer_settime (posix_timer_fn)
      0 |          5 |  <kernel core> | hrtimer_start (tick_sched_timer)
    732 |          3 |      bme_RX-51 | schedule_timeout (process_timeout)
      1 |          3D|  <kernel core> | queue_delayed_work (delayed_work_timer_fn)
    690 |          3 |          dsme | __enqueue_rt_entity (sched_rt_period_timer)
  1021 |          2 |          Xorg | queue_delayed_work (delayed_work_timer_fn)
    991 |          2 |      sgx_perf | queue_delayed_work (delayed_work_timer_fn)
    732 |          2 |      bme_RX-51 | do_nanosleep (hrtimer_wakeup)
    690 |          2 |          dsme | do_nanosleep (hrtimer_wakeup)
    718 |          2D|<kernel module> | queue_delayed_work (delayed_work_timer_fn)
  1021 |          1 |          Xorg | hrtimer_start (it_real_fn)
    30 |          1 |          mount | setup_wb_timer (wb_timer_fn)
    936 |          1 |          ohmd | schedule_hrtimeout_range (hrtimer_wakeup)
    14 |          1 |        pdflush | ubifs_wbuf_write_nolock (wbuf_timer_callback_nolock)
    14 |          1 |        pdflush | ubifs_wbuf_write_nolock (wbuf_timer_callback_nolock)
  1231 |          1 |mission-control | schedule_hrtimeout_range (hrtimer_wakeup)
  1426 |          1 |    gconftool-2 | queue_delayed_work (delayed_work_timer_fn)
    968 |          1 |            csd | schedule_hrtimeout_range (hrtimer_wakeup)
  1266 |          1 |hildon-status-m | schedule_hrtimeout_range (hrtimer_wakeup)
  1611 |          1 |      powertop | do_nanosleep (hrtimer_wakeup)

Power domain activity breakdown
Domain  | % of time spent in states
--------+---------+---------+---------+---------+----------
usbhost |OFF: 100%|RET:  0%|INA:  0%| ON:  0%| now:(OFF)
    sgx |OFF:  97%|RET:  0%|INA:  0%| ON:  2%| now:(OFF)
    per |OFF:  95%|RET:  3%|INA:  0%| ON:  0%| now:(ON)
    dss |OFF: 100%|RET:  0%|INA:  0%| ON:  0%| now:(OFF)
    cam |OFF: 100%|RET:  0%|INA:  0%| ON:  0%| now:(OFF)
  core |OFF:  68%|RET:  26%|INA:  2%| ON:  2%| now:(ON)
  neon |OFF:  68%|RET:  27%|INA:  3%| ON:  0%| now:(ON)
    mpu |OFF:  68%|RET:  27%|INA:  3%| ON:  0%| now:(ON)
  iva2 |OFF: 100%|RET:  0%|INA:  0%| ON:  0%| now:(OFF)

Clock activity breakdown at end of period
Domain  | Active clocks
--------+---------------+---------------+------------------
  core |          SDRC | HSOTGUSB_IDLE |      OMAPCTRL
        |    MAILBOXES |
  wkup |          GPT1 |      32KSYNC |        GPIO1
        |
  ckgen |          CORE |          PERI |          96M
        |          48M |          12M |          54M
        |      EMU_CORE |
    per |        GPIO2 |        GPIO3 |        GPIO4
        |        GPIO5 |        GPIO6 |

Total wakeups  876,  29.2/s | IRQ  592,  19.7/s | Timers  284,  9.5/s
HW wakeups      203,  6.8/s |    Real gp_timers expired  211,  7.0/s

As I suspected it looks a helluva lot cleaner from fresh boot, so something is chewing up the system when programs are run and then close - guess it's just not a clean close. I'm no linux buff so the question is, is there anything like "Windo$e Task Manager" that I can kill processes and process trees with intergrated in this OS, or an equivalent app?

Switch_ 2011-02-02 09:22

Re: [HELP] 50% CPU Use When "Off", Constant CPU Use ~10%
 
After turning on the pedometer and having a 5 minute blast on Angry Birds I'm back to 22,400 wakeups and 0.8% time in C4 sleep mode.

Turning off the pedometer without a reboot inbetween returns the wakeups down to 852, with 82.8% time spent in C4 sleep for the CPU.

Therefore, the unusual number of wakeups is down to the pedometer. I'll leave it off for a while and see what happens to the battery life.

Thanks for the info on the 50% CPU use when charging vi_, nice one :D


All times are GMT. The time now is 10:20.

vBulletin® Version 3.8.8