Re: [PATCH] bpf: Add bpf_ktime_get_real_ns

2020-08-18 Thread Daniel Xu
Hi Maciej, On Tue Aug 18, 2020 at 2:19 PM PDT, Maciej Żenczykowski wrote: > On Tue, Aug 18, 2020 at 2:11 PM Daniel Xu wrote: > > > > On Mon Jul 27, 2020 at 10:01 PM PDT, Andrii Nakryiko wrote: > > > On Mon, Jul 27, 2020 at 4:35 PM wrote: > > > > > > > > From: Ashkan Nikravesh > > > > > > > > Th

Re: [PATCH] bpf: Add bpf_ktime_get_real_ns

2020-08-18 Thread Daniel Xu
On Mon Jul 27, 2020 at 10:01 PM PDT, Andrii Nakryiko wrote: > On Mon, Jul 27, 2020 at 4:35 PM wrote: > > > > From: Ashkan Nikravesh > > > > The existing bpf helper functions to get timestamp return the time > > elapsed since system boot. This timestamp is not particularly useful > > where epoch t

Re: [PATCH] bpf: Add bpf_ktime_get_real_ns

2020-07-29 Thread David Ahern
On 7/28/20 11:15 PM, Andrii Nakryiko wrote: > On Tue, Jul 28, 2020 at 1:57 PM David Ahern wrote: >> >> On 7/28/20 12:28 PM, Andrii Nakryiko wrote: >>> In some, yes, which also means that in some other they can't. So I'm >>> still worried about misuses of REALCLOCK, within (internal daemons >>> wit

Re: [PATCH] bpf: Add bpf_ktime_get_real_ns

2020-07-28 Thread Andrii Nakryiko
On Tue, Jul 28, 2020 at 1:57 PM David Ahern wrote: > > On 7/28/20 12:28 PM, Andrii Nakryiko wrote: > > In some, yes, which also means that in some other they can't. So I'm > > still worried about misuses of REALCLOCK, within (internal daemons > > within the company) our outside (BCC tools and alik

Re: [PATCH] bpf: Add bpf_ktime_get_real_ns

2020-07-28 Thread Andrii Nakryiko
Starovoitov ; Daniel Borkmann ; > Martin Lau ; Nikravesh, Ashkan > Subject: Re: [PATCH] bpf: Add bpf_ktime_get_real_ns > > On Tue, Jul 28, 2020 at 10:57 AM Maciej Żenczykowski wrote: > > > > On Mon, Jul 27, 2020 at 10:01 PM Andrii Nakryiko > > wrote: > >> &g

Re: [PATCH] bpf: Add bpf_ktime_get_real_ns

2020-07-28 Thread David Ahern
On 7/28/20 12:28 PM, Andrii Nakryiko wrote: > In some, yes, which also means that in some other they can't. So I'm > still worried about misuses of REALCLOCK, within (internal daemons > within the company) our outside (BCC tools and alike) of data centers. > Especially if people will start using it

Re: [PATCH] bpf: Add bpf_ktime_get_real_ns

2020-07-28 Thread Andrii Nakryiko
On Tue, Jul 28, 2020 at 10:57 AM Maciej Żenczykowski wrote: > > On Mon, Jul 27, 2020 at 10:01 PM Andrii Nakryiko > wrote: >> >> On Mon, Jul 27, 2020 at 4:35 PM wrote: >> > >> > From: Ashkan Nikravesh >> > >> > The existing bpf helper functions to get timestamp return the time >> > elapsed sinc

Re: [PATCH] bpf: Add bpf_ktime_get_real_ns

2020-07-27 Thread Andrii Nakryiko
On Mon, Jul 27, 2020 at 4:35 PM wrote: > > From: Ashkan Nikravesh > > The existing bpf helper functions to get timestamp return the time > elapsed since system boot. This timestamp is not particularly useful > where epoch timestamp is required or more than one server is involved > and time sync i

Re: [PATCH] bpf: Add bpf_ktime_get_real_ns

2020-07-27 Thread Song Liu
On Mon, Jul 27, 2020 at 4:35 PM wrote: > > From: Ashkan Nikravesh > > The existing bpf helper functions to get timestamp return the time > elapsed since system boot. This timestamp is not particularly useful > where epoch timestamp is required or more than one server is involved > and time sync i

[PATCH] bpf: Add bpf_ktime_get_real_ns

2020-07-27 Thread bimmy . pujari
From: Ashkan Nikravesh The existing bpf helper functions to get timestamp return the time elapsed since system boot. This timestamp is not particularly useful where epoch timestamp is required or more than one server is involved and time sync is required. Instead, you want to use CLOCK_REALTIME,