Re: [patch] voluntary-preempt-2.6.8.1-P9

From: Lee Revell
Date: Sat Aug 28 2004 - 10:11:19 EST


On Sat, 2004-08-28 at 03:37, Ingo Molnar wrote:
> * Lee Revell <rlrevell@xxxxxxxxxxx> wrote:
>
> > I am seeing large latencies (600-2000 usec) latencies in
> > dcache_readdir. This started when the machine became a Samba server
> > and the dcache presumably got large. Traces are at the above url (8
> > and 9 I believe). I think this patch fixes it.
> >
> > --- fs/libfs.c~ 2004-08-14 06:54:47.000000000 -0400
> > +++ fs/libfs.c 2004-08-27 00:44:17.000000000 -0400
> > @@ -140,6 +140,7 @@
> > }
> > for (p=q->next; p != &dentry->d_subdirs; p=p->next) {
> > struct dentry *next;
> > + voluntary_resched_lock(&dcache_lock);
> > next = list_entry(p, struct dentry, d_child);
> > if (d_unhashed(next) || !next->d_inode)
> > continue;
>
> In this loop we are iterating over the child-directories of this
> directory. In the next line (not shown in this patch) we drop the
> dcache_lock - so the issue is the 'continue' - where we skip already
> deleted entries. Are you positive this fixes the latencies you are
> seeing? The 'deleted entries' situation ought to be relatively rare.

No, I am not sure this fixes the problem. This is a pretty rare one, I
only saw it twice. I have not seen it since making the above change,
but this doesn't mean anything.

Lee

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/