sched: cpufreq: update power usage only if cpufreq_stat is enabled
authorAmit Pundir <amit.pundir@linaro.org>
Thu, 4 Jun 2015 14:34:37 +0000 (20:04 +0530)
committerAmit Pundir <amit.pundir@linaro.org>
Thu, 4 Jun 2015 18:27:26 +0000 (23:57 +0530)
commit1b1c8d6849655e6924c453e5ad377157f65eb950
tree1b3b5b8bd03e9669540ea77382467e70cc8ff9b5
parent8556d8602bfa9e2e36e75b1532d9c334f8250220
sched: cpufreq: update power usage only if cpufreq_stat is enabled

Call acct_update_power() to track power usage of task only if
CONFIG_CPU_FREQ_STAT is enabled, otherwise we run into
following build failure:
---------------
kernel/built-in.o: In function `account_user_time':
kernel/sched/cputime.c:155: undefined reference to `acct_update_power'
kernel/built-in.o: In function `__account_system_time':
kernel/sched/cputime.c:208: undefined reference to `acct_update_power'
make: *** [vmlinux] Error 1
---------------

Signed-off-by: Amit Pundir <amit.pundir@linaro.org>
kernel/sched/cputime.c