linux-nfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH RFC 0/3] nfsd: convert nfsd DRC code to use list_lru infrastructure
@ 2013-12-05 11:00 Jeff Layton
  2013-12-05 11:00 ` [PATCH RFC 1/3] nfsd: don't try to reuse an expired DRC entry off the list Jeff Layton
                   ` (3 more replies)
  0 siblings, 4 replies; 16+ messages in thread
From: Jeff Layton @ 2013-12-05 11:00 UTC (permalink / raw)
  To: linux-nfs; +Cc: Christoph Hellwig, J. Bruce Fields

This patchset converts the LRU list in the nfsd duplicate reply cache to
use the new list_lru infrastrucure. Note that this is based on top of
the patch that I sent to Bruce earlier this week that fixes the
svc_cacherep direct reclaim bug. I'm sending this as an RFC since I'm
not 100% convinced it's an improvement.

The majorly unintuitive thing about list_lru that I've found is that
you can't call call list_lru_del from list_lru_walk. So, you need
different routines to free an object depending on how it's being freed.

Using list_lru also means extra spinlocking since we'd be moving to a
per-node LRU, but that's probably not a big deal since all of this is
done under the cache_lock anyway.

In any case, here's what a conversion to list_lru would look like...

Discuss!

Jeff Layton (3):
  nfsd: don't try to reuse an expired DRC entry off the list
  list_lru: add a new LRU_SKIP_REST lru_status value and handling
  nfsd: convert DRC code to use list_lru

 fs/nfsd/nfscache.c       | 130 +++++++++++++++++++++++++----------------------
 include/linux/list_lru.h |   2 +
 mm/list_lru.c            |   4 +-
 3 files changed, 75 insertions(+), 61 deletions(-)

-- 
1.8.4.2


^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2013-12-11 16:31 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-12-05 11:00 [PATCH RFC 0/3] nfsd: convert nfsd DRC code to use list_lru infrastructure Jeff Layton
2013-12-05 11:00 ` [PATCH RFC 1/3] nfsd: don't try to reuse an expired DRC entry off the list Jeff Layton
2013-12-05 13:29   ` Christoph Hellwig
2013-12-05 13:41     ` Jeff Layton
2013-12-05 15:50       ` J. Bruce Fields
2013-12-05 16:22         ` Jeff Layton
2013-12-05 11:00 ` [PATCH RFC 2/3] list_lru: add a new LRU_SKIP_REST lru_status value and handling Jeff Layton
2013-12-05 13:30   ` Christoph Hellwig
2013-12-05 13:36     ` Jeff Layton
2013-12-05 11:00 ` [PATCH RFC 3/3] nfsd: convert DRC code to use list_lru Jeff Layton
2013-12-05 13:41   ` Christoph Hellwig
2013-12-05 13:48     ` Jeff Layton
2013-12-05 15:58       ` J. Bruce Fields
2013-12-11 16:31         ` J. Bruce Fields
2013-12-05 13:27 ` [PATCH RFC 0/3] nfsd: convert nfsd DRC code to use list_lru infrastructure Christoph Hellwig
2013-12-05 13:37   ` Jeff Layton

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).