lkml.org 
[lkml]   [2016]   [Feb]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v8 2/8] time: Add timekeeping snapshot code capturing system time and counter
On Mon, 22 Feb 2016, Christopher S. Hall wrote:

> In the current timekeeping code there isn't any interface to
> atomically capture the current relationship between the system counter
> and system time. ktime_get_snapshot() returns this triple (counter,
> monotonic raw, realtime) in the system_time_snapshot struct.

> +/**
> + * ktime_get_snapshot - snapshots the realtime/monotonic raw clocks with counter
> + * @systime_snapshot: pointer to struct receiving the system time snapshot
> + */
> +void ktime_get_snapshot(struct system_time_snapshot *systime_snapshot)
> +{
> + struct timekeeper *tk = &tk_core.timekeeper;
> + unsigned long seq;
> + ktime_t base_raw;
> + ktime_t base_real;
> + s64 nsec_raw;
> + s64 nsec_real;

I'd prefer to have the variables of the same type in a single line. Other than
that:

Reviewed-by: Thomas Gleixner <tglx@linutronix.de>

\
 
 \ /
  Last update: 2016-02-24 12:21    [W:0.190 / U:0.132 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site