lkml.org 
[lkml]   [2020]   [Sep]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH 1/2] printk: Store all three timestamps
Date
On 2020-09-23, Petr Mladek <pmladek@suse.com> wrote:
> diff --git a/kernel/printk/printk_ringbuffer.h b/kernel/printk/printk_ringbuffer.h
> index 0adaa685d1ca..09082c8472d3 100644
> --- a/kernel/printk/printk_ringbuffer.h
> +++ b/kernel/printk/printk_ringbuffer.h
> @@ -14,7 +15,7 @@
> */
> struct printk_info {
> u64 seq; /* sequence number */
> - u64 ts_nsec; /* timestamp in nanoseconds */
> + struct ktime_timestamps ts; /* timestamps */

Until now struct printk_info has contained generic types. If we add
struct ktime_timestamps, we may start storing more than we need. For
example, if more (possibly internal) fields are added to struct
ktime_timestamps that printk doesn't care about. We may prefer to
generically and explicitly store the information we care about:

u64 ts_mono;
u64 ts_boot;
u64 ts_real;

Or create our own struct printk_ts to copy the fields of interest to.

John Ogness

\
 
 \ /
  Last update: 2020-09-24 02:00    [W:0.120 / U:0.036 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site