lkml.org 
[lkml]   [2009]   [Apr]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] writeback: guard against jiffies wraparound on inode->dirtied_when checks (try #3)
On Thu, 2 Apr 2009 00:12:24 +0200
Andi Kleen <andi@firstfloor.org> wrote:

> On Wed, Apr 01, 2009 at 05:26:30PM -0400, Jeff Layton wrote:
> > One possibility might be a new debugging option. We could add
> > replacement time_after() and time_before() macros that also check
> > whether the difference in times is beyond a certain threshold
> > (maybe a day or week or so), and pop a printk or otherwise record
> > info about it when one is detected?
>
> Makes sense. However it might be hard to get people to run kernels
> with heavy debugging options for that long.
>

Good point. That would limit the usefulness. I also worry that these
macros get used in sensitive places that might not be conducive to
printk's. Plus, we'd have to worry about ratelimiting them since they
could potentially pop often once you did hit the issue.

I'm not sure there's much we can do other than good old-fashioned
review. Identifying places where jiffies-based timestamps might live a
long time is ultimately going to come down to understanding how they're
used in the code.

--
Jeff Layton <jlayton@redhat.com>


\
 
 \ /
  Last update: 2009-04-02 14:03    [W:0.064 / U:0.088 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site