diff options
author | 2021-07-07 14:57:28 -0400 | |
---|---|---|
committer | 2021-08-17 11:47:53 -0400 | |
commit | 6c8c84f525100a1cade5698320b4abe43062e159 (patch) | |
tree | 0a665e57c6c80fd1b2dc72f19ff979fdc2367114 /include/linux/sunrpc | |
parent | lockd: Fix invalid lockowner cast after vfs_test_lock (diff) | |
download | linux-6c8c84f525100a1cade5698320b4abe43062e159.tar.gz linux-6c8c84f525100a1cade5698320b4abe43062e159.tar.bz2 linux-6c8c84f525100a1cade5698320b4abe43062e159.zip |
svcrdma: Fewer calls to wake_up() in Send completion handler
Because wake_up() takes an IRQ-safe lock, it can be expensive,
especially to call inside of a single-threaded completion handler.
What's more, the Send wait queue almost never has waiters, so
most of the time, this is an expensive no-op.
As always, the goal is to reduce the average overhead of each
completion, because a transport's completion handlers are single-
threaded on one CPU core. This change reduces CPU utilization of
the Send completion thread by 2-3% on my server.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Reviewed-By: Tom Talpey <tom@talpey.com>
Diffstat (limited to 'include/linux/sunrpc')
-rw-r--r-- | include/linux/sunrpc/svc_rdma.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/sunrpc/svc_rdma.h b/include/linux/sunrpc/svc_rdma.h index 3184465de3a0..57c60ffe76dd 100644 --- a/include/linux/sunrpc/svc_rdma.h +++ b/include/linux/sunrpc/svc_rdma.h @@ -207,6 +207,7 @@ extern void svc_rdma_send_error_msg(struct svcxprt_rdma *rdma, struct svc_rdma_send_ctxt *sctxt, struct svc_rdma_recv_ctxt *rctxt, int status); +extern void svc_rdma_wake_send_waiters(struct svcxprt_rdma *rdma, int avail); extern int svc_rdma_sendto(struct svc_rqst *); extern int svc_rdma_result_payload(struct svc_rqst *rqstp, unsigned int offset, unsigned int length); |