Hello,
Running top command with idlestat tool doesn't show any frequency
information sometimes. I have run the program with the following
command -
#sudo idlestat --trace -t 5 -f /tmp/myoutput /usr/bin/top
and it ended up with the following output where there is no frequency
state information. The file "myoutput" doesn't have any cpu_frequency
entry either.
Total trace buffer: 153896 kB
Log is 4.999488 secs long with 675 events
clusterA@state hits total(us) avg(us) min(us) max(us)
C6-SNB 163 4955450.00 30401.53 0.00 141946.00
cpu0@state hits total(us) avg(us) min(us) max(us)
C1-SNB 1 912.00 912.00 912.00 912.00
C6-SNB 115 4996270.00 43445.83 67.00 211819.00
cpu0 wakeups name count
irq040 eth0 50
cpu1@state hits total(us) avg(us) min(us) max(us)
C1-SNB 3 10809.00 3603.00 27.00 10742.00
C6-SNB 62 4985746.00 80415.26 59.00 223952.00
cpu1 wakeups name count
irq018 ata_piix 6
cpu2@state hits total(us) avg(us) min(us) max(us)
C1-SNB 3 10800.00 3600.00 26.00 10745.00
C6-SNB 52 4986684.00 95897.77 5724.00 223957.00
cpu2 wakeups name count
cpu3@state hits total(us) avg(us) min(us) max(us)
C1-SNB 20 15123.00 756.15 121.00 10895.00
C6-SNB 47 4962591.00 105587.04 1.00 223950.00
cpu3 wakeups name count
Does that mean processors spent all time in idle state and none in active state?
--
Best Regards
Salman Ahmed
== Progress ==
CARD-1489: Migrating the arndale android builds to 4.9 toolchain. Built the
code. need to verify on the HW.
== Plans ==
CARD-1489: Test verify the binaries which got built with linaro toolchain
v4.9.
== Issues ==
None
--
Thanks and Regards,
HariGopal G
Android Engineer
Recently there was a patch (commit
f5b9bdcb530a8871e6c65a617d41001b39bf4912), to fix
resource leak on dir_topology.
Now, the below code segment is either unnecessary or it should call
opendir on 'newpath' instead of 'path'?
dir_topology = opendir(path);
if (!dir_topology)
continue;
closedir(dir_topology);
Please comment.
--
Thanks,
-Meraj
Fix for the below issues -
1. valgrind reports memory leaks in
export_free_gpios. 'line' pointer was never freed.
==5732== 120 bytes in 1 blocks are definitely lost in loss record 130 of 271
==5732== at 0x482CBB8: malloc (vg_replace_malloc.c:270)
==5732== by 0x48CC633: getdelim (iogetdelim.c:67)
==5732== by 0xB303: export_free_gpios (stdio.h:117)
==5732== by 0xB3DD: gpio_init (gpio.c:376)
==5732== by 0x97F5: main (powerdebug.c:264)
2. Open files need to be closed.
diff --git a/gpio.c b/gpio.c
index 39480b0..076b260 100644
--- a/gpio.c
+++ b/gpio.c
@@ -353,7 +353,15 @@ void export_free_gpios(void)
if (system(command) < 0)
printf("error: failed to export gpio-%d\n", i);
}
+
+ free(line);
out:
+ if(fgpio)
+ fclose(fgpio);
+
+ if(fgpio_export)
+ fclose(fgpio_export);
+
return;
}
--
Thanks,
-Meraj