mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 18:51:56 -04:00
Merge branch 'cputime' of git://git390.osdl.marist.edu/pub/scm/linux-2.6
* 'cputime' of git://git390.osdl.marist.edu/pub/scm/linux-2.6: [PATCH] fast vdso implementation for CLOCK_THREAD_CPUTIME_ID [PATCH] improve idle cputime accounting [PATCH] improve precision of idle time detection. [PATCH] improve precision of process accounting. [PATCH] idle cputime accounting [PATCH] fix scaled & unscaled cputime accounting
This commit is contained in:
commit
61420f59a5
30 changed files with 683 additions and 456 deletions
|
|
@ -419,7 +419,9 @@ void tick_nohz_restart_sched_tick(void)
|
|||
{
|
||||
int cpu = smp_processor_id();
|
||||
struct tick_sched *ts = &per_cpu(tick_cpu_sched, cpu);
|
||||
#ifndef CONFIG_VIRT_CPU_ACCOUNTING
|
||||
unsigned long ticks;
|
||||
#endif
|
||||
ktime_t now;
|
||||
|
||||
local_irq_disable();
|
||||
|
|
@ -441,6 +443,7 @@ void tick_nohz_restart_sched_tick(void)
|
|||
tick_do_update_jiffies64(now);
|
||||
cpumask_clear_cpu(cpu, nohz_cpu_mask);
|
||||
|
||||
#ifndef CONFIG_VIRT_CPU_ACCOUNTING
|
||||
/*
|
||||
* We stopped the tick in idle. Update process times would miss the
|
||||
* time we slept as update_process_times does only a 1 tick
|
||||
|
|
@ -450,12 +453,9 @@ void tick_nohz_restart_sched_tick(void)
|
|||
/*
|
||||
* We might be one off. Do not randomly account a huge number of ticks!
|
||||
*/
|
||||
if (ticks && ticks < LONG_MAX) {
|
||||
add_preempt_count(HARDIRQ_OFFSET);
|
||||
account_system_time(current, HARDIRQ_OFFSET,
|
||||
jiffies_to_cputime(ticks));
|
||||
sub_preempt_count(HARDIRQ_OFFSET);
|
||||
}
|
||||
if (ticks && ticks < LONG_MAX)
|
||||
account_idle_ticks(ticks);
|
||||
#endif
|
||||
|
||||
touch_softlockup_watchdog();
|
||||
/*
|
||||
|
|
|
|||
Loading…
Reference in a new issue