diff mbox

[1/2] libceph: mark ceph_msgr_wq reentrant

Message ID 50749742.2080104@inktank.com (mailing list archive)
State New, archived
Headers show

Commit Message

Alex Elder Oct. 9, 2012, 9:29 p.m. UTC
The ceph messenger workqueue is used to activate execution of the
messenger state machine loop con_work().  The work queue used is
allocated with flag WQ_NON_REENTRANT, which only allows a single
work item on the queue to execute at a time.

There is no need for this restriction, because each connection
maintains its own state and manipulation of each connection is
protected by the connection's mutex.

So drop the WQ_NON_REENTRANT flag when allocating this work queue.
This will allow different connections to be operated on at the same
time.

Signed-off-by: Alex Elder <elder@inktank.com>
---
  net/ceph/messenger.c |    2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox

Patch

diff --git a/net/ceph/messenger.c b/net/ceph/messenger.c
index 159aa8b..28ed904 100644
--- a/net/ceph/messenger.c
+++ b/net/ceph/messenger.c
@@ -190,7 +190,7 @@  int ceph_msgr_init(void)
  	zero_page = ZERO_PAGE(0);
  	page_cache_get(zero_page);

-	ceph_msgr_wq = alloc_workqueue("ceph-msgr", WQ_NON_REENTRANT, 0);
+	ceph_msgr_wq = alloc_workqueue("ceph-msgr", 0, 0);
  	if (ceph_msgr_wq)
  		return 0;