mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jeff Layton <jlayton@redhat.com>
To: linux-kernel@vger.kernel.org, linux-nfs@vger.kernel.org,
	bfields@fieldses.org
Subject: [PATCH 3/3] sunrpc: change default for pooled services to SVC_POOL_AUTO and make settings persistent
Date: Tue, 03 Jun 2008 07:18:07 -0400	[thread overview]
Message-ID: <20080603111807.8769.56170.stgit@dantu.usersys.redhat.com> (raw)
In-Reply-To: <20080603111757.8769.69366.stgit@dantu.usersys.redhat.com>

The current default for pooled services is SVC_POOL_GLOBAL, which just
does allocations in whatever pool the current process is running, and
doesn't restrict which CPUs the tasks will run.

Change the default to SVC_POOL_AUTO so that large-scale machines will
automatically choose an allocation and cpu masking scheme that's better
suited to their architecture. Also, change it so that when the pool
refcount goes to zero, that we do not reset the allocation scheme to the
compile-time default. The setting should stick once it's made.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
---

 net/sunrpc/svc.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/net/sunrpc/svc.c b/net/sunrpc/svc.c
index a61e7aa..7238c37 100644
--- a/net/sunrpc/svc.c
+++ b/net/sunrpc/svc.c
@@ -39,7 +39,7 @@ enum {
 	SVC_POOL_PERCPU,	/* one pool per cpu */
 	SVC_POOL_PERNODE	/* one pool per numa node */
 };
-#define SVC_POOL_DEFAULT	SVC_POOL_GLOBAL
+#define SVC_POOL_DEFAULT	SVC_POOL_AUTO
 
 /*
  * Structure for mapping cpus to pools and vice versa.
@@ -280,7 +280,6 @@ svc_pool_map_put(void)
 	mutex_lock(&svc_pool_map_mutex);
 
 	if (!--m->count) {
-		m->mode = SVC_POOL_DEFAULT;
 		kfree(m->to_pool);
 		kfree(m->pool_to);
 		m->npools = 0;


      parent reply	other threads:[~2008-06-03 11:18 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-06-03 11:17 [PATCH 1/3] VM: add kzalloc_node inline Jeff Layton
2008-06-03 11:18 ` [PATCH 2/3] sunrpc: have pooled services make NUMA-friendly allocations Jeff Layton
2008-06-06 15:21   ` Jeff Layton
2008-06-06 15:41     ` J. Bruce Fields
2008-06-03 11:18 ` Jeff Layton [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20080603111807.8769.56170.stgit@dantu.usersys.redhat.com \
    --to=jlayton@redhat.com \
    --cc=bfields@fieldses.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-nfs@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®