Re: [PATCH v5 3/3] sched/cputime: Add steal time support to full dynticks CPU time accounting

From: Paolo Bonzini
Date: Mon Jun 13 2016 - 03:56:27 EST




On 13/06/2016 05:38, Wanpeng Li wrote:
> + delta_jiffies = jiffies_to_cputime(now - tsk->vtime_snap);
> + steal_jiffies = jiffies_to_cputime(steal_account_process_tick(delta_jiffies));

Without jiffies_to_cputime here. Apart from this, yes, this is what I
meant.

Paolo

> WARN_ON_ONCE(tsk->vtime_snap_whence == VTIME_INACTIVE);
> tsk->vtime_snap = now;
>
> - return jiffies_to_cputime(delta);
> + return jiffies_to_cputime(delta_jiffies - steal_jiffies);