lkml.org 
[lkml]   [2019]   [Jun]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCHv4 03/28] posix-clocks: add another call back to return clock time in ktime_t
From
Date
Hi Thomas,

Thanks much for the review,

On 6/14/19 2:32 PM, Thomas Gleixner wrote:
> Dmitry,
>
> On Wed, 12 Jun 2019, Dmitry Safonov wrote:
>
>> From: Andrei Vagin <avagin@gmail.com>
>>
>> The callsite in common_timer_get() has already a comment:
>> /*
>> * The timespec64 based conversion is suboptimal, but it's not
>> * worth to implement yet another callback.
>> */
>> kc->clock_get(timr->it_clock, &ts64);
>> now = timespec64_to_ktime(ts64);
>>
>> Now we are going to add time namespaces and we need to be able to get:
>
> Please avoid 'we' and try to describe the changes in a neutral technical
> form, e.g.:
>
> The upcoming support for time namespaces requires to have access to:
>
>> * clock value in a task time namespace to return it from the clock_gettime
>> syscall.
>
> - The time in a tasks time namespace for sys_clock_gettime()
>
>> * clock valuse in the root time namespace to use it in
>> common_timer_get().
>
> - The time in the root name space for common_timer_get()
>
>> It looks like another reason why we need a separate callback to return
>> clock value in ktime_t.
>
> That adds a valid reason to finally implement a separate callback which
> returns the time in ktime_t format.
>
> Hmm?

Agree, the patch has become bigger than wanted and the message could
have been better in technical sense. Will split, add kernel doc and fix
the commit message(s).

[..]
> TBH, this patch is way to big. It changes too many things at once. Can you
> please structure it this way:
>
> 1) Rename k_clock::clock_get to k_clock::clock_get_timespec and fix up all
> struct initializers
>
> 2) Rename the clock_get_timespec functions per instance
>
> 3) Add the new callback
>
> 4) Add the new functions per instance and add them to the corresponding
> struct initializers
>
> 5) Use the new callback
>
Thanks,
Dima

\
 
 \ /
  Last update: 2019-06-14 16:40    [W:0.065 / U:21.092 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site