lkml.org 
[lkml]   [2013]   [Mar]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v4 4/4] timekeeping: utilize the suspend-nonstop clocksource to count suspended time
On Tue, Mar 12, 2013 at 02:09:08PM -0700, John Stultz wrote:
> On 03/11/2013 08:56 PM, Feng Tang wrote:
> }
> >- /* re-base the last cycle value */
> >- tk->clock->cycle_last = tk->clock->read(tk->clock);
> >+
> >+ if (suspendtime_found)
> >+ __timekeeping_inject_sleeptime(tk, &ts_delta);
> >+
> >+ /* Re-base the last cycle value */
> >+ clock->cycle_last = clock->read(clock);
> It seems like since we unconditionally read the clock above, this
> last line could be reworked to be:
> clock->cycle_last = cycle_now;
>
> Which would save re-reading the clocksource.
>
> If you don't have any objections I'll fold that small change into
> your patch.

No objection at all. Thanks!

- Feng


\
 
 \ /
  Last update: 2013-03-13 04:41    [W:0.126 / U:0.012 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site