Hi,
On 11/02/2019 01:09, Linus Lüssing wrote:
Furthermore, don't jiffies overflow at some point on some architectures ? Initializing a jiffies field with 0 appears error-prone.
Hm, good point. Assuming 32bit and 1 jiffy = 1ms it would overflow every 49 days (2^32/1000/60/60/24). The time_before() macros should accomodate for that (as long as the value to compare with is < 49/2 days apart?). However you are right, the 0 value would probably lead to faulty results for 49/2 days then...
Anyway, removing that new timeout thing should fix it, as last_update is always initialized with "jiffies".
+1
the problem is on last_dht_update that gets initializes with 0 (for locally cached entries). If you agree on removing it and using a bool (I like this idea too!), the overflow problem should be gone.
Regards,