diffstat of debian/ for linux-tools_3.7.1-1~experimental.1 linux-tools_3.7.5-SprezzOS1 debian/changelog | 6 debian/control.md5sum | 2 tools/power/cpupower/bench/debian/tmp/etc/cpufreq-bench.conf | 11 tools/power/cpupower/bench/debian/tmp/usr/bin/cpufreq-bench_plot.sh | 104 ++++ tools/power/cpupower/bench/debian/tmp/usr/share/doc/packages/cpupower/README-BENCH | 124 +++++ tools/power/cpupower/bench/debian/tmp/usr/share/doc/packages/cpupower/cpufreq-bench_script.sh | 101 ++++ tools/power/cpupower/debian/tmp/usr/include/cpufreq.h | 223 ++++++++++ tools/power/cpupower/debian/tmp/usr/man/man1/cpupower-frequency-info.1 | 74 +++ tools/power/cpupower/debian/tmp/usr/man/man1/cpupower-frequency-set.1 | 52 ++ tools/power/cpupower/debian/tmp/usr/man/man1/cpupower-info.1 | 19 tools/power/cpupower/debian/tmp/usr/man/man1/cpupower-monitor.1 | 179 ++++++++ tools/power/cpupower/debian/tmp/usr/man/man1/cpupower-set.1 | 94 ++++ tools/power/cpupower/debian/tmp/usr/man/man1/cpupower.1 | 72 +++ 13 files changed, 1060 insertions(+), 1 deletion(-) --- linux-tools-3.7.1/debian/changelog 2012-12-28 17:29:55.000000000 +0000 +++ linux-tools-3.7.5/debian/changelog 2013-01-29 02:36:11.000000000 +0000 @@ -1,3 +1,9 @@ +linux-tools (3.7.5-SprezzOS1) unstable; urgency=low + + * New upstream + + -- Nick Black Mon, 28 Jan 2013 21:36:07 -0500 + linux-tools (3.7.1-1~experimental.1) experimental; urgency=low * New upstream release --- linux-tools-3.7.1/debian/control.md5sum 2012-12-28 17:31:01.000000000 +0000 +++ linux-tools-3.7.5/debian/control.md5sum 2013-01-29 02:40:19.000000000 +0000 @@ -1,4 +1,4 @@ 57fe7e40fc35dbfe4f05a2a2fb2ca3a7 debian/bin/gencontrol.py -50d1b7bba37367bca740551da7af1ffb debian/changelog +4ce8ac6b58b7a51d517044b085f928de debian/changelog 5673569283f76650b5ebd0eb51e5cb0b debian/templates/control.main.in af707f57d79ffa49d8c1a02521fcf908 debian/templates/control.source.in --- linux-tools-3.7.1/tools/power/cpupower/bench/debian/tmp/etc/cpufreq-bench.conf 1970-01-01 00:00:00.000000000 +0000 +++ linux-tools-3.7.5/tools/power/cpupower/bench/debian/tmp/etc/cpufreq-bench.conf 2013-01-29 02:37:35.000000000 +0000 @@ -0,0 +1,11 @@ +sleep = 50000 +load = 50000 +cpu = 0 +priority = LOW +output = /var/log/cpufreq-bench +sleep_step = 50000 +load_step = 50000 +cycles = 20 +rounds = 40 +verbose = 0 +governor = ondemand --- linux-tools-3.7.1/tools/power/cpupower/bench/debian/tmp/usr/bin/cpufreq-bench_plot.sh 1970-01-01 00:00:00.000000000 +0000 +++ linux-tools-3.7.5/tools/power/cpupower/bench/debian/tmp/usr/bin/cpufreq-bench_plot.sh 2013-01-29 02:37:35.000000000 +0000 @@ -0,0 +1,104 @@ +#!/bin/bash + +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. + +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +# 02110-1301, USA. + +# Author/Copyright(c): 2009, Thomas Renninger , Novell Inc. + +# Helper script to easily create nice plots of your cpufreq-bench results + +dir=`mktemp -d` +output_file="cpufreq-bench.png" +global_title="cpufreq-bench plot" +picture_type="jpeg" +file[0]="" + +function usage() +{ + echo "cpufreq-bench_plot.sh [OPTIONS] logfile [measure_title] [logfile [measure_title]] ...]" + echo + echo "Options" + echo " -o output_file" + echo " -t global_title" + echo " -p picture_type [jpeg|gif|png|postscript|...]" + exit 1 +} + +if [ $# -eq 0 ];then + echo "No benchmark results file provided" + echo + usage +fi + +while getopts o:t:p: name ; do + case $name in + o) + output_file="$OPTARG".$picture_type + ;; + t) + global_title="$OPTARG" + ;; + p) + picture_type="$OPTARG" + ;; + ?) + usage + ;; + esac +done +shift $(($OPTIND -1)) + +plots=0 +while [ "$1" ];do + if [ ! -f "$1" ];then + echo "File $1 does not exist" + usage + fi + file[$plots]="$1" + title[$plots]="$2" + # echo "File: ${file[$plots]} - ${title[plots]}" + shift;shift + plots=$((plots + 1)) +done + +echo "set terminal $picture_type" >> $dir/plot_script.gpl +echo "set output \"$output_file\"" >> $dir/plot_script.gpl +echo "set title \"$global_title\"" >> $dir/plot_script.gpl +echo "set xlabel \"sleep/load time\"" >> $dir/plot_script.gpl +echo "set ylabel \"Performance (%)\"" >> $dir/plot_script.gpl + +for((plot=0;plot<$plots;plot++));do + + # Sanity check + ###### I am to dump to get this redirected to stderr/stdout in one awk call... ##### + cat ${file[$plot]} |grep -v "^#" |awk '{if ($2 != $3) printf("Error in measure %d:Load time %s does not equal sleep time %s, plot will not be correct\n", $1, $2, $3); ERR=1}' + ###### I am to dump to get this redirected in one awk call... ##### + + # Parse out load time (which must be equal to sleep time for a plot), divide it by 1000 + # to get ms and parse out the performance in percentage and write it to a temp file for plotting + cat ${file[$plot]} |grep -v "^#" |awk '{printf "%lu %.1f\n",$2/1000, $6}' >$dir/data_$plot + + if [ $plot -eq 0 ];then + echo -n "plot " >> $dir/plot_script.gpl + fi + echo -n "\"$dir/data_$plot\" title \"${title[$plot]}\" with lines" >> $dir/plot_script.gpl + if [ $(($plot + 1)) -ne $plots ];then + echo -n ", " >> $dir/plot_script.gpl + fi +done +echo >> $dir/plot_script.gpl + +gnuplot $dir/plot_script.gpl +rm -r $dir \ No newline at end of file --- linux-tools-3.7.1/tools/power/cpupower/bench/debian/tmp/usr/share/doc/packages/cpupower/README-BENCH 1970-01-01 00:00:00.000000000 +0000 +++ linux-tools-3.7.5/tools/power/cpupower/bench/debian/tmp/usr/share/doc/packages/cpupower/README-BENCH 2013-01-29 02:37:35.000000000 +0000 @@ -0,0 +1,124 @@ +This is cpufreq-bench, a microbenchmark for the cpufreq framework. + +Purpose +======= + +What is this benchmark for: + - Identify worst case performance loss when doing dynamic frequency + scaling using Linux kernel governors + - Identify average reaction time of a governor to CPU load changes + - (Stress) Testing whether a cpufreq low level driver or governor works + as expected + - Identify cpufreq related performance regressions between kernels + - Possibly Real time priority testing? -> what happens if there are + processes with a higher prio than the governor's kernel thread + - ... + +What this benchmark does *not* cover: + - Power saving related regressions (In fact as better the performance + throughput is, the worse the power savings will be, but the first should + mostly count more...) + - Real world (workloads) + + +Description +=========== + +cpufreq-bench helps to test the condition of a given cpufreq governor. +For that purpose, it compares the performance governor to a configured +powersave module. + + +How it works +============ +You can specify load (100% CPU load) and sleep (0% CPU load) times in us which +will be run X time in a row (cycles): + + sleep=25000 + load=25000 + cycles=20 + +This part of the configuration file will create 25ms load/sleep turns, +repeated 20 times. + +Adding this: + sleep_step=25000 + load_step=25000 + rounds=5 +Will increase load and sleep time by 25ms 5 times. +Together you get following test: +25ms load/sleep time repeated 20 times (cycles). +50ms load/sleep time repeated 20 times (cycles). +.. +100ms load/sleep time repeated 20 times (cycles). + +First it is calibrated how long a specific CPU intensive calculation +takes on this machine and needs to be run in a loop using the performance +governor. +Then the above test runs are processed using the performance governor +and the governor to test. The time the calculation really needed +with the dynamic freq scaling governor is compared with the time needed +on full performance and you get the overall performance loss. + + +Example of expected results with ondemand governor: + +This shows expected results of the first two test run rounds from +above config, you there have: + +100% CPU load (load) | 0 % CPU load (sleep) | round + 25 ms | 25 ms | 1 + 50 ms | 50 ms | 2 + +For example if ondemand governor is configured to have a 50ms +sampling rate you get: + +In round 1, ondemand should have rather static 50% load and probably +won't ever switch up (as long as up_threshold is above). + +In round 2, if the ondemand sampling times exactly match the load/sleep +trigger of the cpufreq-bench, you will see no performance loss (compare with +below possible ondemand sample kick ins (1)): + +But if ondemand always kicks in in the middle of the load sleep cycles, it +will always see 50% loads and you get worst performance impact never +switching up (compare with below possible ondemand sample kick ins (2)):: + + 50 50 50 50ms ->time +load -----| |-----| |-----| |-----| + | | | | | | | +sleep |-----| |-----| |-----| |---- + |-----|-----|-----|-----|-----|-----|-----|---- ondemand sampling (1) + 100 0 100 0 100 0 100 load seen by ondemand(%) + |-----|-----|-----|-----|-----|-----|-----|-- ondemand sampling (2) + 50 50 50 50 50 50 50 load seen by ondemand(%) + +You can easily test all kind of load/sleep times and check whether your +governor in average behaves as expected. + + +ToDo +==== + +Provide a gnuplot utility script for easy generation of plots to present +the outcome nicely. + + +cpufreq-bench Command Usage +=========================== +-l, --load= initial load time in us +-s, --sleep= initial sleep time in us +-x, --load-step= time to be added to load time, in us +-y, --sleep-step= time to be added to sleep time, in us +-c, --cpu= CPU Number to use, starting at 0 +-p, --prio= scheduler priority, HIGH, LOW or DEFAULT +-g, --governor= cpufreq governor to test +-n, --cycles= load/sleep cycles to get an avarage value to compare +-r, --rounds load/sleep rounds +-f, --file= config file to use +-o, --output= output dir, must exist +-v, --verbose verbose output on/off + +Due to the high priority, the application may not be responsible for some time. +After the benchmark, the logfile is saved in OUTPUTDIR/benchmark_TIMESTAMP.log + --- linux-tools-3.7.1/tools/power/cpupower/bench/debian/tmp/usr/share/doc/packages/cpupower/cpufreq-bench_script.sh 1970-01-01 00:00:00.000000000 +0000 +++ linux-tools-3.7.5/tools/power/cpupower/bench/debian/tmp/usr/share/doc/packages/cpupower/cpufreq-bench_script.sh 2013-01-29 02:37:35.000000000 +0000 @@ -0,0 +1,101 @@ +#!/bin/bash + +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. + +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +# 02110-1301, USA. + +# Author/Copyright(c): 2009, Thomas Renninger , Novell Inc. + +# Ondemand up_threshold and sampling rate test script for cpufreq-bench +# mircobenchmark. +# Modify the general variables at the top or extend or copy out parts +# if you want to test other things +# + +# Default with latest kernels is 95, before micro account patches +# it was 80, cmp. with git commit 808009131046b62ac434dbc796 +UP_THRESHOLD="60 80 95" +# Depending on the kernel and the HW sampling rate could be restricted +# and cannot be set that low... +# E.g. before git commit cef9615a853ebc4972084f7 one could only set +# min sampling rate of 80000 if CONFIG_HZ=250 +SAMPLING_RATE="20000 80000" + +function measure() +{ + local -i up_threshold_set + local -i sampling_rate_set + + for up_threshold in $UP_THRESHOLD;do + for sampling_rate in $SAMPLING_RATE;do + # Set values in sysfs + echo $up_threshold >/sys/devices/system/cpu/cpu0/cpufreq/ondemand/up_threshold + echo $sampling_rate >/sys/devices/system/cpu/cpu0/cpufreq/ondemand/sampling_rate + up_threshold_set=$(cat /sys/devices/system/cpu/cpu0/cpufreq/ondemand/up_threshold) + sampling_rate_set=$(cat /sys/devices/system/cpu/cpu0/cpufreq/ondemand/sampling_rate) + + # Verify set values in sysfs + if [ ${up_threshold_set} -eq ${up_threshold} ];then + echo "up_threshold: $up_threshold, set in sysfs: ${up_threshold_set}" + else + echo "WARNING: Tried to set up_threshold: $up_threshold, set in sysfs: ${up_threshold_set}" + fi + if [ ${sampling_rate_set} -eq ${sampling_rate} ];then + echo "sampling_rate: $sampling_rate, set in sysfs: ${sampling_rate_set}" + else + echo "WARNING: Tried to set sampling_rate: $sampling_rate, set in sysfs: ${sampling_rate_set}" + fi + + # Benchmark + cpufreq-bench -o /var/log/cpufreq-bench/up_threshold_${up_threshold}_sampling_rate_${sampling_rate} + done + done +} + +function create_plots() +{ + local command + + for up_threshold in $UP_THRESHOLD;do + command="cpufreq-bench_plot.sh -o \"sampling_rate_${SAMPLING_RATE}_up_threshold_${up_threshold}\" -t \"Ondemand sampling_rate: ${SAMPLING_RATE} comparison - Up_threshold: $up_threshold %\"" + for sampling_rate in $SAMPLING_RATE;do + command="${command} /var/log/cpufreq-bench/up_threshold_${up_threshold}_sampling_rate_${sampling_rate}/* \"sampling_rate = $sampling_rate\"" + done + echo $command + eval "$command" + echo + done + + for sampling_rate in $SAMPLING_RATE;do + command="cpufreq-bench_plot.sh -o \"up_threshold_${UP_THRESHOLD}_sampling_rate_${sampling_rate}\" -t \"Ondemand up_threshold: ${UP_THRESHOLD} % comparison - sampling_rate: $sampling_rate\"" + for up_threshold in $UP_THRESHOLD;do + command="${command} /var/log/cpufreq-bench/up_threshold_${up_threshold}_sampling_rate_${sampling_rate}/* \"up_threshold = $up_threshold\"" + done + echo $command + eval "$command" + echo + done + + command="cpufreq-bench_plot.sh -o \"up_threshold_${UP_THRESHOLD}_sampling_rate_${SAMPLING_RATE}\" -t \"Ondemand up_threshold: ${UP_THRESHOLD} and sampling_rate ${SAMPLING_RATE} comparison\"" + for sampling_rate in $SAMPLING_RATE;do + for up_threshold in $UP_THRESHOLD;do + command="${command} /var/log/cpufreq-bench/up_threshold_${up_threshold}_sampling_rate_${sampling_rate}/* \"up_threshold = $up_threshold - sampling_rate = $sampling_rate\"" + done + done + echo "$command" + eval "$command" +} + +measure +create_plots \ No newline at end of file --- linux-tools-3.7.1/tools/power/cpupower/debian/tmp/usr/include/cpufreq.h 1970-01-01 00:00:00.000000000 +0000 +++ linux-tools-3.7.5/tools/power/cpupower/debian/tmp/usr/include/cpufreq.h 2013-01-29 02:37:35.000000000 +0000 @@ -0,0 +1,223 @@ +/* + * cpufreq.h - definitions for libcpufreq + * + * Copyright (C) 2004-2009 Dominik Brodowski + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, version 2 of the License. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +#ifndef _CPUFREQ_H +#define _CPUFREQ_H 1 + +struct cpufreq_policy { + unsigned long min; + unsigned long max; + char *governor; +}; + +struct cpufreq_available_governors { + char *governor; + struct cpufreq_available_governors *next; + struct cpufreq_available_governors *first; +}; + +struct cpufreq_available_frequencies { + unsigned long frequency; + struct cpufreq_available_frequencies *next; + struct cpufreq_available_frequencies *first; +}; + + +struct cpufreq_affected_cpus { + unsigned int cpu; + struct cpufreq_affected_cpus *next; + struct cpufreq_affected_cpus *first; +}; + +struct cpufreq_stats { + unsigned long frequency; + unsigned long long time_in_state; + struct cpufreq_stats *next; + struct cpufreq_stats *first; +}; + + + +#ifdef __cplusplus +extern "C" { +#endif + +/* + * returns 0 if the specified CPU is present (it doesn't say + * whether it is online!), and an error value if not. + */ + +extern int cpufreq_cpu_exists(unsigned int cpu); + +/* determine current CPU frequency + * - _kernel variant means kernel's opinion of CPU frequency + * - _hardware variant means actual hardware CPU frequency, + * which is only available to root. + * + * returns 0 on failure, else frequency in kHz. + */ + +extern unsigned long cpufreq_get_freq_kernel(unsigned int cpu); + +extern unsigned long cpufreq_get_freq_hardware(unsigned int cpu); + +#define cpufreq_get(cpu) cpufreq_get_freq_kernel(cpu); + + +/* determine CPU transition latency + * + * returns 0 on failure, else transition latency in 10^(-9) s = nanoseconds + */ +extern unsigned long cpufreq_get_transition_latency(unsigned int cpu); + + +/* determine hardware CPU frequency limits + * + * These may be limited further by thermal, energy or other + * considerations by cpufreq policy notifiers in the kernel. + */ + +extern int cpufreq_get_hardware_limits(unsigned int cpu, + unsigned long *min, + unsigned long *max); + + +/* determine CPUfreq driver used + * + * Remember to call cpufreq_put_driver when no longer needed + * to avoid memory leakage, please. + */ + +extern char *cpufreq_get_driver(unsigned int cpu); + +extern void cpufreq_put_driver(char *ptr); + + +/* determine CPUfreq policy currently used + * + * Remember to call cpufreq_put_policy when no longer needed + * to avoid memory leakage, please. + */ + + +extern struct cpufreq_policy *cpufreq_get_policy(unsigned int cpu); + +extern void cpufreq_put_policy(struct cpufreq_policy *policy); + + +/* determine CPUfreq governors currently available + * + * may be modified by modprobe'ing or rmmod'ing other governors. Please + * free allocated memory by calling cpufreq_put_available_governors + * after use. + */ + + +extern struct cpufreq_available_governors +*cpufreq_get_available_governors(unsigned int cpu); + +extern void cpufreq_put_available_governors( + struct cpufreq_available_governors *first); + + +/* determine CPU frequency states available + * + * Only present on _some_ ->target() cpufreq drivers. For information purposes + * only. Please free allocated memory by calling + * cpufreq_put_available_frequencies after use. + */ + +extern struct cpufreq_available_frequencies +*cpufreq_get_available_frequencies(unsigned int cpu); + +extern void cpufreq_put_available_frequencies( + struct cpufreq_available_frequencies *first); + + +/* determine affected CPUs + * + * Remember to call cpufreq_put_affected_cpus when no longer needed + * to avoid memory leakage, please. + */ + +extern struct cpufreq_affected_cpus *cpufreq_get_affected_cpus(unsigned + int cpu); + +extern void cpufreq_put_affected_cpus(struct cpufreq_affected_cpus *first); + + +/* determine related CPUs + * + * Remember to call cpufreq_put_related_cpus when no longer needed + * to avoid memory leakage, please. + */ + +extern struct cpufreq_affected_cpus *cpufreq_get_related_cpus(unsigned + int cpu); + +extern void cpufreq_put_related_cpus(struct cpufreq_affected_cpus *first); + + +/* determine stats for cpufreq subsystem + * + * This is not available in all kernel versions or configurations. + */ + +extern struct cpufreq_stats *cpufreq_get_stats(unsigned int cpu, + unsigned long long *total_time); + +extern void cpufreq_put_stats(struct cpufreq_stats *stats); + +extern unsigned long cpufreq_get_transitions(unsigned int cpu); + + +/* set new cpufreq policy + * + * Tries to set the passed policy as new policy as close as possible, + * but results may differ depending e.g. on governors being available. + */ + +extern int cpufreq_set_policy(unsigned int cpu, struct cpufreq_policy *policy); + + +/* modify a policy by only changing min/max freq or governor + * + * Does not check whether result is what was intended. + */ + +extern int cpufreq_modify_policy_min(unsigned int cpu, unsigned long min_freq); +extern int cpufreq_modify_policy_max(unsigned int cpu, unsigned long max_freq); +extern int cpufreq_modify_policy_governor(unsigned int cpu, char *governor); + + +/* set a specific frequency + * + * Does only work if userspace governor can be used and no external + * interference (other calls to this function or to set/modify_policy) + * occurs. Also does not work on ->range() cpufreq drivers. + */ + +extern int cpufreq_set_frequency(unsigned int cpu, + unsigned long target_frequency); + +#ifdef __cplusplus +} +#endif + +#endif /* _CPUFREQ_H */ --- linux-tools-3.7.1/tools/power/cpupower/debian/tmp/usr/man/man1/cpupower-frequency-info.1 1970-01-01 00:00:00.000000000 +0000 +++ linux-tools-3.7.5/tools/power/cpupower/debian/tmp/usr/man/man1/cpupower-frequency-info.1 2013-01-29 02:37:35.000000000 +0000 @@ -0,0 +1,74 @@ +.TH "CPUPOWER\-FREQUENCY\-INFO" "1" "0.1" "" "cpupower Manual" +.SH "NAME" +.LP +cpupower frequency\-info \- Utility to retrieve cpufreq kernel information +.SH "SYNTAX" +.LP +cpupower [ \-c cpulist ] frequency\-info [\fIoptions\fP] +.SH "DESCRIPTION" +.LP +A small tool which prints out cpufreq information helpful to developers and interested users. +.SH "OPTIONS" +.LP +.TP +\fB\-e\fR \fB\-\-debug\fR +Prints out debug information. +.TP +\fB\-f\fR \fB\-\-freq\fR +Get frequency the CPU currently runs at, according to the cpufreq core. +.TP +\fB\-w\fR \fB\-\-hwfreq\fR +Get frequency the CPU currently runs at, by reading it from hardware (only available to root). +.TP +\fB\-l\fR \fB\-\-hwlimits\fR +Determine the minimum and maximum CPU frequency allowed. +.TP +\fB\-d\fR \fB\-\-driver\fR +Determines the used cpufreq kernel driver. +.TP +\fB\-p\fR \fB\-\-policy\fR +Gets the currently used cpufreq policy. +.TP +\fB\-g\fR \fB\-\-governors\fR +Determines available cpufreq governors. +.TP +\fB\-a\fR \fB\-\-related\-cpus\fR +Determines which CPUs run at the same hardware frequency. +.TP +\fB\-a\fR \fB\-\-affected\-cpus\fR +Determines which CPUs need to have their frequency coordinated by software. +.TP +\fB\-s\fR \fB\-\-stats\fR +Shows cpufreq statistics if available. +.TP +\fB\-y\fR \fB\-\-latency\fR +Determines the maximum latency on CPU frequency changes. +.TP +\fB\-o\fR \fB\-\-proc\fR +Prints out information like provided by the /proc/cpufreq interface in 2.4. and early 2.6. kernels. +.TP +\fB\-m\fR \fB\-\-human\fR +human\-readable output for the \-f, \-w, \-s and \-y parameters. +.TP +.SH "REMARKS" +.LP +By default only values of core zero are displayed. How to display settings of +other cores is described in the cpupower(1) manpage in the \-\-cpu option section. +.LP +You can't specify more than one of the output specific options \-o \-e \-a \-g \-p \-d \-l \-w \-f \-y. +.LP +You also can't specify the \-o option combined with the \-c option. +.SH "FILES" +.nf +\fI/sys/devices/system/cpu/cpu*/cpufreq/\fP +\fI/proc/cpufreq\fP (deprecated) +\fI/proc/sys/cpu/\fP (deprecated) +.fi +.SH "AUTHORS" +.nf +Dominik Brodowski \- author +Mattia Dongili \- first autolibtoolization +.fi +.SH "SEE ALSO" +.LP +cpupower\-frequency\-set(1), cpupower(1) --- linux-tools-3.7.1/tools/power/cpupower/debian/tmp/usr/man/man1/cpupower-frequency-set.1 1970-01-01 00:00:00.000000000 +0000 +++ linux-tools-3.7.5/tools/power/cpupower/debian/tmp/usr/man/man1/cpupower-frequency-set.1 2013-01-29 02:37:35.000000000 +0000 @@ -0,0 +1,52 @@ +.TH "CPUPOWER\-FREQUENCY\-SET" "1" "0.1" "" "cpupower Manual" +.SH "NAME" +.LP +cpupower frequency\-set \- A small tool which allows to modify cpufreq settings. +.SH "SYNTAX" +.LP +cpupower [ \-c cpu ] frequency\-set [\fIoptions\fP] +.SH "DESCRIPTION" +.LP +cpupower frequency\-set allows you to modify cpufreq settings without having to type e.g. "/sys/devices/system/cpu/cpu0/cpufreq/scaling_set_speed" all the time. +.SH "OPTIONS" +.LP +.TP +\fB\-d\fR \fB\-\-min\fR +new minimum CPU frequency the governor may select. +.TP +\fB\-u\fR \fB\-\-max\fR +new maximum CPU frequency the governor may select. +.TP +\fB\-g\fR \fB\-\-governor\fR +new cpufreq governor. +.TP +\fB\-f\fR \fB\-\-freq\fR +specific frequency to be set. Requires userspace governor to be available and loaded. +.TP +\fB\-r\fR \fB\-\-related\fR +modify all hardware-related CPUs at the same time +.TP +.SH "REMARKS" +.LP +By default values are applied on all cores. How to modify single core +configurations is described in the cpupower(1) manpage in the \-\-cpu option section. +.LP +The \-f FREQ, \-\-freq FREQ parameter cannot be combined with any other parameter. +.LP +FREQuencies can be passed in Hz, kHz (default), MHz, GHz, or THz by postfixing the value with the wanted unit name, without any space (frequency in kHz =^ Hz * 0.001 =^ MHz * 1000 =^ GHz * 1000000). +.LP +On Linux kernels up to 2.6.29, the \-r or \-\-related parameter is ignored. +.SH "FILES" +.nf +\fI/sys/devices/system/cpu/cpu*/cpufreq/\fP +\fI/proc/cpufreq\fP (deprecated) +\fI/proc/sys/cpu/\fP (deprecated) +.fi +.SH "AUTHORS" +.nf +Dominik Brodowski \- author +Mattia Dongili \- first autolibtoolization +.fi +.SH "SEE ALSO" +.LP +cpupower\-frequency\-info(1), cpupower(1) --- linux-tools-3.7.1/tools/power/cpupower/debian/tmp/usr/man/man1/cpupower-info.1 1970-01-01 00:00:00.000000000 +0000 +++ linux-tools-3.7.5/tools/power/cpupower/debian/tmp/usr/man/man1/cpupower-info.1 2013-01-29 02:37:35.000000000 +0000 @@ -0,0 +1,19 @@ +.TH CPUPOWER\-INFO "1" "22/02/2011" "" "cpupower Manual" +.SH NAME +cpupower\-info \- Shows processor power related kernel or hardware configurations +.SH SYNOPSIS +.ft B +.B cpupower info [ \-b ] [ \-s ] [ \-m ] + +.SH DESCRIPTION +\fBcpupower info \fP shows kernel configurations or processor hardware +registers affecting processor power saving policies. + +Some options are platform wide, some affect single cores. By default values +of core zero are displayed only. cpupower --cpu all cpuinfo will show the +settings of all cores, see cpupower(1) how to choose specific cores. + +.SH "SEE ALSO" +Options are described in detail in: + +cpupower(1), cpupower-set(1) --- linux-tools-3.7.1/tools/power/cpupower/debian/tmp/usr/man/man1/cpupower-monitor.1 1970-01-01 00:00:00.000000000 +0000 +++ linux-tools-3.7.5/tools/power/cpupower/debian/tmp/usr/man/man1/cpupower-monitor.1 2013-01-29 02:37:35.000000000 +0000 @@ -0,0 +1,179 @@ +.TH CPUPOWER\-MONITOR "1" "22/02/2011" "" "cpupower Manual" +.SH NAME +cpupower\-monitor \- Report processor frequency and idle statistics +.SH SYNOPSIS +.ft B +.B cpupower monitor +.RB "\-l" + +.B cpupower monitor +.RB [ "\-m ," [ ",..." ] ] +.RB [ "\-i seconds" ] +.br +.B cpupower monitor +.RB [ "\-m ," [ ",..." ] ] +.RB command +.br +.SH DESCRIPTION +\fBcpupower-monitor \fP reports processor topology, frequency and idle power +state statistics. Either \fBcommand\fP is forked and +statistics are printed upon its completion, or statistics are printed periodically. + +\fBcpupower-monitor \fP implements independent processor sleep state and +frequency counters. Some are retrieved from kernel statistics, some are +directly reading out hardware registers. Use \-l to get an overview which are +supported on your system. + +.SH Options +.PP +\-l +.RS 4 +List available monitors on your system. Additional details about each monitor +are shown: +.RS 2 +.IP \(bu +The name in quotation marks which can be passed to the \-m parameter. +.IP \(bu +The number of different counters the monitor supports in brackets. +.IP \(bu +The amount of time in seconds the counters might overflow, due to +implementation constraints. +.IP \(bu +The name and a description of each counter and its processor hierarchy level +coverage in square brackets: +.RS 4 +.IP \(bu +[T] \-> Thread +.IP \(bu +[C] \-> Core +.IP \(bu +[P] \-> Processor Package (Socket) +.IP \(bu +[M] \-> Machine/Platform wide counter +.RE +.RE +.RE +.PP +\-m ,,... +.RS 4 +Only display specific monitors. Use the monitor string(s) provided by \-l option. +.RE +.PP +\-i seconds +.RS 4 +Measure intervall. +.RE +.PP +command +.RS 4 +Measure idle and frequency characteristics of an arbitrary command/workload. +The executable \fBcommand\fP is forked and upon its exit, statistics gathered since it was +forked are displayed. +.RE +.PP +\-v +.RS 4 +Increase verbosity if the binary was compiled with the DEBUG option set. +.RE + +.SH MONITOR DESCRIPTIONS +.SS "Idle_Stats" +Shows statistics of the cpuidle kernel subsystem. Values are retrieved from +/sys/devices/system/cpu/cpu*/cpuidle/state*/. +The kernel updates these values every time an idle state is entered or +left. Therefore there can be some inaccuracy when cores are in an idle +state for some time when the measure starts or ends. In worst case it can happen +that one core stayed in an idle state for the whole measure time and the idle +state usage time as exported by the kernel did not get updated. In this case +a state residency of 0 percent is shown while it was 100. + +.SS "Mperf" +The name comes from the aperf/mperf (average and maximum) MSR registers used +which are available on recent X86 processors. It shows the average frequency +(including boost frequencies). +The fact that on all recent hardware the mperf timer stops ticking in any idle +state it is also used to show C0 (processor is active) and Cx (processor is in +any sleep state) times. These counters do not have the inaccuracy restrictions +the "Idle_Stats" counters may show. +May work poorly on Linux-2.6.20 through 2.6.29, as the \fBacpi-cpufreq \fP +kernel frequency driver periodically cleared aperf/mperf registers in those +kernels. + +.SS "Nehalem" "SandyBridge" +Intel Core and Package sleep state counters. +Threads (hyperthreaded cores) may not be able to enter deeper core states if +its sibling is utilized. +Deepest package sleep states may in reality show up as machine/platform wide +sleep states and can only be entered if all cores are idle. Look up Intel +manuals (some are provided in the References section) for further details. + +.SS "Fam_12h" "Fam_14h" +AMD laptop and desktop processor (family 12h and 14h) sleep state counters. +The registers are accessed via PCI and therefore can still be read out while +cores have been offlined. + +There is one special counter: NBP1 (North Bridge P1). +This one always returns 0 or 1, depending on whether the North Bridge P1 +power state got entered at least once during measure time. +Being able to enter NBP1 state also depends on graphics power management. +Therefore this counter can be used to verify whether the graphics' driver +power management is working as expected. + +.SH EXAMPLES + +cpupower monitor -l" may show: +.RS 4 +Monitor "Mperf" (3 states) \- Might overflow after 922000000 s + + ... + +Monitor "Idle_Stats" (3 states) \- Might overflow after 4294967295 s + + ... + +.RE +cpupower monitor \-m "Idle_Stats,Mperf" scp /tmp/test /nfs/tmp + +Monitor the scp command, show both Mperf and Idle_Stats states counter +statistics, but in exchanged order. + + + +.RE +Be careful that the typical command to fully utilize one CPU by doing: + +cpupower monitor cat /dev/zero >/dev/null + +Does not work as expected, because the measured output is redirected to +/dev/null. This could get workarounded by putting the line into an own, tiny +shell script. Hit CTRL\-c to terminate the command and get the measure output +displayed. + +.SH REFERENCES +"BIOS and Kernel Developer’s Guide (BKDG) for AMD Family 14h Processors" +http://support.amd.com/us/Processor_TechDocs/43170.pdf + +"Intel® Turbo Boost Technology +in Intel® Core™ Microarchitecture (Nehalem) Based Processors" +http://download.intel.com/design/processor/applnots/320354.pdf + +"Intel® 64 and IA-32 Architectures Software Developer's Manual +Volume 3B: System Programming Guide" +http://www.intel.com/products/processor/manuals + +.SH FILES +.ta +.nf +/dev/cpu/*/msr +/sys/devices/system/cpu/cpu*/cpuidle/state*/. +.fi + +.SH "SEE ALSO" +powertop(8), msr(4), vmstat(8) +.PP +.SH AUTHORS +.nf +Written by Thomas Renninger + +Nehalem, SandyBridge monitors and command passing +based on turbostat.8 from Len Brown --- linux-tools-3.7.1/tools/power/cpupower/debian/tmp/usr/man/man1/cpupower-set.1 1970-01-01 00:00:00.000000000 +0000 +++ linux-tools-3.7.5/tools/power/cpupower/debian/tmp/usr/man/man1/cpupower-set.1 2013-01-29 02:37:35.000000000 +0000 @@ -0,0 +1,94 @@ +.TH CPUPOWER\-SET "1" "22/02/2011" "" "cpupower Manual" +.SH NAME +cpupower\-set \- Set processor power related kernel or hardware configurations +.SH SYNOPSIS +.ft B +.B cpupower set [ \-b VAL ] [ \-s VAL ] [ \-m VAL ] + + +.SH DESCRIPTION +\fBcpupower set \fP sets kernel configurations or directly accesses hardware +registers affecting processor power saving policies. + +Some options are platform wide, some affect single cores. By default values +are applied on all cores. How to modify single core configurations is +described in the cpupower(1) manpage in the \-\-cpu option section. Whether an +option affects the whole system or can be applied to individual cores is +described in the Options sections. + +Use \fBcpupower info \fP to read out current settings and whether they are +supported on the system at all. + +.SH Options +.PP +\-\-perf-bias, \-b +.RS 4 +Sets a register on supported Intel processore which allows software to convey +its policy for the relative importance of performance versus energy savings to +the processor. + +The range of valid numbers is 0-15, where 0 is maximum +performance and 15 is maximum energy efficiency. + +The processor uses this information in model-specific ways +when it must select trade-offs between performance and +energy efficiency. + +This policy hint does not supersede Processor Performance states +(P-states) or CPU Idle power states (C-states), but allows +software to have influence where it would otherwise be unable +to express a preference. + +For example, this setting may tell the hardware how +aggressively or conservatively to control frequency +in the "turbo range" above the explicitly OS-controlled +P-state frequency range. It may also tell the hardware +how aggressively it should enter the OS requested C-states. + +This option can be applied to individual cores only via the \-\-cpu option, +cpupower(1). + +Setting the performance bias value on one CPU can modify the setting on +related CPUs as well (for example all CPUs on one socket), because of +hardware restrictions. +Use \fBcpupower -c all info -b\fP to verify. + +This options needs the msr kernel driver (CONFIG_X86_MSR) loaded. +.RE +.PP +\-\-sched\-mc, \-m [ VAL ] +.RE +\-\-sched\-smt, \-s [ VAL ] +.RS 4 +\-\-sched\-mc utilizes cores in one processor package/socket first before +processes are scheduled to other processor packages/sockets. + +\-\-sched\-smt utilizes thread siblings of one processor core first before +processes are scheduled to other cores. + +The impact on power consumption and performance (positiv or negativ) heavily +depends on processor support for deep sleep states, frequency scaling and +frequency boost modes and their dependencies between other thread siblings +and processor cores. + +Taken over from kernel documentation: + +Adjust the kernel's multi-core scheduler support. + +Possible values are: +.RS 2 +0 - No power saving load balance (default value) + +1 - Fill one thread/core/package first for long running threads + +2 - Also bias task wakeups to semi-idle cpu package for power +savings +.RE + +.SH "SEE ALSO" +cpupower-info(1), cpupower-monitor(1), powertop(1) +.PP +.SH AUTHORS +.nf +\-\-perf\-bias parts written by Len Brown +Thomas Renninger --- linux-tools-3.7.1/tools/power/cpupower/debian/tmp/usr/man/man1/cpupower.1 1970-01-01 00:00:00.000000000 +0000 +++ linux-tools-3.7.5/tools/power/cpupower/debian/tmp/usr/man/man1/cpupower.1 2013-01-29 02:37:35.000000000 +0000 @@ -0,0 +1,72 @@ +.TH CPUPOWER "1" "07/03/2011" "" "cpupower Manual" +.SH NAME +cpupower \- Shows and sets processor power related values +.SH SYNOPSIS +.ft B +.B cpupower [ \-c cpulist ] [ARGS] + +.B cpupower \-v|\-\-version + +.B cpupower \-h|\-\-help + +.SH DESCRIPTION +\fBcpupower \fP is a collection of tools to examine and tune power saving +related features of your processor. + +The manpages of the commands (cpupower\-(1)) provide detailed +descriptions of supported features. Run \fBcpupower help\fP to get an overview +of supported commands. + +.SH Options +.PP +\-\-help, \-h +.RS 4 +Shows supported commands and general usage. +.RE +.PP +\-\-cpu cpulist, \-c cpulist +.RS 4 +Only show or set values for specific cores. +This option is not supported by all commands, details can be found in the +manpages of the commands. + +Some commands access all cores (typically the *\-set commands), some only +the first core (typically the *\-info commands) by default. + +The syntax for is based on how the kernel exports CPU bitmasks via +sysfs files. Some examples: +.RS 4 +.TP 16 +Input +Equivalent to +.TP +all +all cores +.TP +0\-3 +0,1,2,3 +.TP +0\-7:2 +0,2,4,6 +.TP +1,3,5-7 +1,3,5,6,7 +.TP +0\-3:2,8\-15:4 +0,2,8,12 +.RE +.RE +.PP +\-\-version, \-v +.RS 4 +Print the package name and version number. + +.SH "SEE ALSO" +cpupower-set(1), cpupower-info(1), cpupower-idle(1), +cpupower-frequency-set(1), cpupower-frequency-info(1), cpupower-monitor(1), +powertop(1) +.PP +.SH AUTHORS +.nf +\-\-perf\-bias parts written by Len Brown +Thomas Renninger