linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Howells <dhowells@redhat.com>
To: netdev@vger.kernel.org
Cc: dhowells@redhat.com, linux-afs@lists.infradead.org,
	linux-kernel@vger.kernel.org
Subject: [PATCH net-next 6/9] fs/afs/vlocation: Remove deprecated create_singlethread_workqueue
Date: Sun, 04 Sep 2016 22:03:05 +0100	[thread overview]
Message-ID: <147302298519.28597.766505614863532593.stgit@warthog.procyon.org.uk> (raw)
In-Reply-To: <147302294435.28597.15007422228950187972.stgit@warthog.procyon.org.uk>

From: Bhaktipriya Shridhar <bhaktipriya96@gmail.com>

The workqueue "afs_vlocation_update_worker" queues a single work item
&afs_vlocation_update and hence it doesn't require execution ordering.
Hence, alloc_workqueue has been used to replace the deprecated
create_singlethread_workqueue instance.

Since the workqueue is being used on a memory reclaim path, WQ_MEM_RECLAIM
flag has been set to ensure forward progress under memory pressure.

Since there are fixed number of work items, explicit concurrency
limit is unnecessary here.

Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com>
Signed-off-by: David Howells <dhowells@redhat.com>
---

 fs/afs/vlocation.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/afs/vlocation.c b/fs/afs/vlocation.c
index 52976785a32c..45a86396fd2d 100644
--- a/fs/afs/vlocation.c
+++ b/fs/afs/vlocation.c
@@ -594,8 +594,8 @@ static void afs_vlocation_reaper(struct work_struct *work)
  */
 int __init afs_vlocation_update_init(void)
 {
-	afs_vlocation_update_worker =
-		create_singlethread_workqueue("kafs_vlupdated");
+	afs_vlocation_update_worker = alloc_workqueue("kafs_vlupdated",
+						      WQ_MEM_RECLAIM, 0);
 	return afs_vlocation_update_worker ? 0 : -ENOMEM;
 }
 

  parent reply	other threads:[~2016-09-04 21:13 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-04 21:02 [PATCH net-next 0/9] rxrpc: Small fixes David Howells
2016-09-04 21:02 ` [PATCH net-next 1/9] rxrpc: fix undefined behavior in rxrpc_mark_call_released David Howells
2016-09-04 21:02 ` [PATCH net-next 2/9] rxrpc: Fix uninitialised variable warning David Howells
2016-09-04 21:02 ` [PATCH net-next 3/9] rxrpc: The client call state must be changed before attachment to conn David Howells
2016-09-04 21:02 ` [PATCH net-next 4/9] rxrpc: Randomise epoch and starting client conn ID values David Howells
2016-09-05 15:01   ` David Laight
2016-09-05 16:24   ` David Howells
2016-09-06  2:12     ` Jeffrey Altman
2016-09-04 21:02 ` [PATCH net-next 5/9] rxrpc: Don't change the epoch David Howells
2016-09-04 21:03 ` David Howells [this message]
2016-09-04 21:03 ` [PATCH net-next 7/9] fs/afs/rxrpc: Remove deprecated create_singlethread_workqueue David Howells
2016-09-04 21:03 ` [PATCH net-next 8/9] fs/afs/callback: " David Howells
2016-09-04 21:03 ` [PATCH net-next 9/9] fs/afs/flock: " David Howells
2016-09-06 20:53 ` [PATCH net-next 0/9] rxrpc: Small fixes David Miller

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=147302298519.28597.766505614863532593.stgit@warthog.procyon.org.uk \
    --to=dhowells@redhat.com \
    --cc=linux-afs@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@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;
as well as URLs for NNTP newsgroup(s).