lkml.org 
[lkml]   [2018]   [Jun]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH net-next 3/3] tcp: use monotonic timestamps for PAWS
On Mon, Jun 18, 2018 at 5:59 PM, Eric Dumazet <eric.dumazet@gmail.com> wrote:
> On 06/18/2018 08:22 AM, Arnd Bergmann wrote:
>
> Please use the time_after32(), since ktime_get_seconds() is time64_t while ts_recent_stamp is int.
>
> Same remark for tcp_twsk_unique()
>
> Lets clean up this stuff, thanks !

Sure, no problem. Note that as ktime_get_seconds() uses CLOCK_MONOTONIC, it is
guaranteed to return a number that fits into a positive 32-bit number
(for about 136
years after boot to be precise). Most users of time_after() or
time_after32() are for
jiffies values that do overflow regularly, but it doesn't hurt to use
time_after32()
here for illustration.

Arnd

\
 
 \ /
  Last update: 2018-06-19 11:24    [W:0.048 / U:0.208 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site