xfs
[Top] [All Lists]

Re: [PATCH 1/2] mm: add context argument to shrinker callback

To: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Subject: Re: [PATCH 1/2] mm: add context argument to shrinker callback
From: Nick Piggin <npiggin@xxxxxxx>
Date: Tue, 20 Apr 2010 00:00:39 +1000
Cc: Dave Chinner <david@xxxxxxxxxxxxx>, linux-kernel@xxxxxxxxxxxxxxx, linux-fsdevel@xxxxxxxxxxxxxxx, linux-mm@xxxxxxxxx, xfs@xxxxxxxxxxx, Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
In-reply-to: <20100418001514.GA26575@xxxxxxxxxxxxx>
References: <1271118255-21070-1-git-send-email-david@xxxxxxxxxxxxx> <1271118255-21070-2-git-send-email-david@xxxxxxxxxxxxx> <20100418001514.GA26575@xxxxxxxxxxxxx>
User-agent: Mutt/1.5.20 (2009-06-14)
On Sat, Apr 17, 2010 at 08:15:14PM -0400, Christoph Hellwig wrote:
> Any chance we can still get this into 2.6.34?  It's really needed to fix
> a regression in XFS that would be hard to impossible to work around
> inside the fs.  While it touches quite a few places the changes are
> trivial and well understood.

Why do you even need this context argument?  Reclaim is not doing anything
smart about this, it would just call each call shrinker in turn.

Do you not have an easily traversable list of mountpoints? Can you just
make a list of them? It would be cheaper than putting a whole shrinker
structure into them anyway.

The main reason I would be against proliferation of dynamic shrinker
registration would be that it could change reclaim behaviour depending
on how they get ordered (in the cache the caches are semi-dependent,
like inode cache and dentry cache).

Unless there is a reason I missed, I would much prefer not to do this
like this.

<Prev in Thread] Current Thread [Next in Thread>