[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4739A97F.60206@cosmosbay.com>
Date: Tue, 13 Nov 2007 14:41:19 +0100
From: Eric Dumazet <dada1@...mosbay.com>
To: David Miller <davem@...emloft.net>
Cc: netdev@...r.kernel.org, kaber@...sh.net, stable@...nel.org
Subject: [NET] random : secure_tcp_sequence_number should not assume CONFIG_KTIME_SCALAR
I discovered one other incorrect use of .tv64 (coming from me, I must
confess)
I guess this patch is needed for 2.6.24 and stable (2.6.22 & 2.6.23)
Thank you
[NET] random : secure_tcp_sequence_number should not assume
CONFIG_KTIME_SCALAR
All 32 bits machines but i386 dont have CONFIG_KTIME_SCALAR. On these
machines, ktime.tv64
is more than 4 times the (correct) result given by ktime_to_ns()
Again on these machines, using ktime_get_real().tv64 >> 6 give a 32bits
rollover every 64 seconds,
which is not wanted (less than the 120 s MSL)
Using ktime_to_ns() is the portable way to get nsecs from a ktime, and
have correct code.
Signed-off-by: Eric Dumazet <dada1@...mosbay.com>
View attachment "random.patch" of type "text/plain" (1147 bytes)
Powered by blists - more mailing lists