* [PATCH v3 0/4] fs/afs: Remove deprecated create_singlethread_workqueue
@ 2016-09-04 15:21 Bhaktipriya Shridhar
2016-09-04 15:22 ` [PATCH v3 1/4] fs/afs/vlocation: " Bhaktipriya Shridhar
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: Bhaktipriya Shridhar @ 2016-09-04 15:21 UTC (permalink / raw)
To: David Howells; +Cc: linux-kernel, linux-afs, Tejun Heo
This patch set removes deprecated create_singlethread_workqueue
usages in fs/afs.
Bhaktipriya Shridhar (4):
fs/afs/vlocation: Remove deprecated create_singlethread_workqueue
fs/afs/rxrpc: Remove deprecated create_singlethread_workqueue
fs/afs/callback: Remove deprecated create_singlethread_workqueue
fs/afs/flock: Remove deprecated create_singlethread_workqueue
fs/afs/callback.c | 4 ++--
fs/afs/flock.c | 4 ++--
fs/afs/rxrpc.c | 2 +-
fs/afs/vlocation.c | 4 ++--
4 files changed, 7 insertions(+), 7 deletions(-)
--
2.1.4
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH v3 1/4] fs/afs/vlocation: Remove deprecated create_singlethread_workqueue
2016-09-04 15:21 [PATCH v3 0/4] fs/afs: Remove deprecated create_singlethread_workqueue Bhaktipriya Shridhar
@ 2016-09-04 15:22 ` Bhaktipriya Shridhar
2016-09-04 15:23 ` [PATCH v3 2/4] fs/afs/rxrpc: " Bhaktipriya Shridhar
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Bhaktipriya Shridhar @ 2016-09-04 15:22 UTC (permalink / raw)
To: David Howells; +Cc: linux-kernel, linux-afs, Tejun Heo
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>
---
Changes in v3:
- No change
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 5297678..45a8639 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;
}
--
2.1.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH v3 2/4] fs/afs/rxrpc: Remove deprecated create_singlethread_workqueue
2016-09-04 15:21 [PATCH v3 0/4] fs/afs: Remove deprecated create_singlethread_workqueue Bhaktipriya Shridhar
2016-09-04 15:22 ` [PATCH v3 1/4] fs/afs/vlocation: " Bhaktipriya Shridhar
@ 2016-09-04 15:23 ` Bhaktipriya Shridhar
2016-09-04 15:24 ` [PATCH v3 3/4] fs/afs/callback: " Bhaktipriya Shridhar
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Bhaktipriya Shridhar @ 2016-09-04 15:23 UTC (permalink / raw)
To: David Howells; +Cc: linux-kernel, linux-afs, Tejun Heo
The workqueue "afs_async_calls" queues work item
&call->async_work per afs_call. Since there could be multiple calls and since
these calls can be run concurrently, alloc_workqueue has been used to replace
the deprecated create_singlethread_workqueue instance.
The WQ_MEM_RECLAIM flag has been set to ensure forward progress under
memory pressure because the workqueue is being used on a memory reclaim
path.
Since there are fixed number of work items, explicit concurrency
limit is unnecessary here.
Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com>
---
Changes in v3:
- Updated patch description
fs/afs/rxrpc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/fs/afs/rxrpc.c b/fs/afs/rxrpc.c
index 63cd9f9..4f9e9b3 100644
--- a/fs/afs/rxrpc.c
+++ b/fs/afs/rxrpc.c
@@ -85,7 +85,7 @@ int afs_open_socket(void)
skb_queue_head_init(&afs_incoming_calls);
- afs_async_calls = create_singlethread_workqueue("kafsd");
+ afs_async_calls = alloc_workqueue("kafsd", WQ_MEM_RECLAIM, 0);
if (!afs_async_calls) {
_leave(" = -ENOMEM [wq]");
return -ENOMEM;
--
2.1.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH v3 3/4] fs/afs/callback: Remove deprecated create_singlethread_workqueue
2016-09-04 15:21 [PATCH v3 0/4] fs/afs: Remove deprecated create_singlethread_workqueue Bhaktipriya Shridhar
2016-09-04 15:22 ` [PATCH v3 1/4] fs/afs/vlocation: " Bhaktipriya Shridhar
2016-09-04 15:23 ` [PATCH v3 2/4] fs/afs/rxrpc: " Bhaktipriya Shridhar
@ 2016-09-04 15:24 ` Bhaktipriya Shridhar
2016-09-04 15:24 ` [PATCH v3 4/4] fs/afs/flock: " Bhaktipriya Shridhar
2016-09-04 21:06 ` [PATCH v3 0/4] fs/afs: " David Howells
4 siblings, 0 replies; 6+ messages in thread
From: Bhaktipriya Shridhar @ 2016-09-04 15:24 UTC (permalink / raw)
To: David Howells; +Cc: linux-kernel, linux-afs, Tejun Heo
The workqueue "afs_callback_update_worker" queues multiple work items
viz &vnode->cb_broken_work, &server->cb_break_work which require strict
execution ordering. Hence, an ordered dedicated workqueue has been used.
Since the workqueue is being used on a memory reclaim path, WQ_MEM_RECLAIM
has been set to ensure forward progress under memory pressure.
Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com>
---
Changes in v3:
-No change
fs/afs/callback.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fs/afs/callback.c b/fs/afs/callback.c
index 7ef637d..1e9d2f8 100644
--- a/fs/afs/callback.c
+++ b/fs/afs/callback.c
@@ -461,8 +461,8 @@ static void afs_callback_updater(struct work_struct *work)
*/
int __init afs_callback_update_init(void)
{
- afs_callback_update_worker =
- create_singlethread_workqueue("kafs_callbackd");
+ afs_callback_update_worker = alloc_ordered_workqueue("kafs_callbackd",
+ WQ_MEM_RECLAIM);
return afs_callback_update_worker ? 0 : -ENOMEM;
}
--
2.1.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH v3 4/4] fs/afs/flock: Remove deprecated create_singlethread_workqueue
2016-09-04 15:21 [PATCH v3 0/4] fs/afs: Remove deprecated create_singlethread_workqueue Bhaktipriya Shridhar
` (2 preceding siblings ...)
2016-09-04 15:24 ` [PATCH v3 3/4] fs/afs/callback: " Bhaktipriya Shridhar
@ 2016-09-04 15:24 ` Bhaktipriya Shridhar
2016-09-04 21:06 ` [PATCH v3 0/4] fs/afs: " David Howells
4 siblings, 0 replies; 6+ messages in thread
From: Bhaktipriya Shridhar @ 2016-09-04 15:24 UTC (permalink / raw)
To: David Howells; +Cc: linux-kernel, linux-afs, Tejun Heo
The workqueue "afs_lock_manager" queues work item &vnode->lock_work,
per vnode. Since there can be multiple vnodes and since their work items
can be executed concurrently, alloc_workqueue has been used to replace
the deprecated create_singlethread_workqueue instance.
The WQ_MEM_RECLAIM flag has been set to ensure forward progress under
memory pressure because the workqueue is being used on a memory reclaim
path.
Since there are fixed number of work items, explicit concurrency
limit is unnecessary here.
Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com>
---
Changes in v3:
-Updated patch description
fs/afs/flock.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fs/afs/flock.c b/fs/afs/flock.c
index d91a9c9..3191dff 100644
--- a/fs/afs/flock.c
+++ b/fs/afs/flock.c
@@ -36,8 +36,8 @@ static int afs_init_lock_manager(void)
if (!afs_lock_manager) {
mutex_lock(&afs_lock_manager_mutex);
if (!afs_lock_manager) {
- afs_lock_manager =
- create_singlethread_workqueue("kafs_lockd");
+ afs_lock_manager = alloc_workqueue("kafs_lockd",
+ WQ_MEM_RECLAIM, 0);
if (!afs_lock_manager)
ret = -ENOMEM;
}
--
2.1.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH v3 0/4] fs/afs: Remove deprecated create_singlethread_workqueue
2016-09-04 15:21 [PATCH v3 0/4] fs/afs: Remove deprecated create_singlethread_workqueue Bhaktipriya Shridhar
` (3 preceding siblings ...)
2016-09-04 15:24 ` [PATCH v3 4/4] fs/afs/flock: " Bhaktipriya Shridhar
@ 2016-09-04 21:06 ` David Howells
4 siblings, 0 replies; 6+ messages in thread
From: David Howells @ 2016-09-04 21:06 UTC (permalink / raw)
To: Bhaktipriya Shridhar; +Cc: dhowells, linux-kernel, linux-afs, Tejun Heo
Bhaktipriya Shridhar <bhaktipriya96@gmail.com> wrote:
> This patch set removes deprecated create_singlethread_workqueue
> usages in fs/afs.
Applied.
David
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2016-09-04 21:06 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-09-04 15:21 [PATCH v3 0/4] fs/afs: Remove deprecated create_singlethread_workqueue Bhaktipriya Shridhar
2016-09-04 15:22 ` [PATCH v3 1/4] fs/afs/vlocation: " Bhaktipriya Shridhar
2016-09-04 15:23 ` [PATCH v3 2/4] fs/afs/rxrpc: " Bhaktipriya Shridhar
2016-09-04 15:24 ` [PATCH v3 3/4] fs/afs/callback: " Bhaktipriya Shridhar
2016-09-04 15:24 ` [PATCH v3 4/4] fs/afs/flock: " Bhaktipriya Shridhar
2016-09-04 21:06 ` [PATCH v3 0/4] fs/afs: " David Howells
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.