Whamcloud - gitweb
LU-13005 ptlrpc: use percpu refcount to track requests. 45/36845/10
authorMr NeilBrown <neilb@suse.de>
Wed, 20 Nov 2019 02:16:04 +0000 (13:16 +1100)
committerOleg Drokin <green@whamcloud.com>
Tue, 24 Mar 2020 05:16:54 +0000 (05:16 +0000)
commitbee5cd85a8e35b8dbf0e16e9a380812f74d4f422
tree4da8c624d95eef90550c4d48cc6cf7a8902913c0
parent095281bd8070cddae1fead7117a48ac1f09d165b
LU-13005 ptlrpc: use percpu refcount to track requests.

ptlrpc needs to wait for outstanding RPC requests to complete before
ptlrpc_ni_fini() finishes.
It currently does this using a refcount in the event-queue, but that
refcount is otherwise unused, and it will shortly be removed.

So add a percpu refcount that explicitly tracks these requests, and
wait for it with a completion.

Also move the declaration of ptlrpc_eq to ptlrpc_internal.h which is a
more appropriate location.

Signed-off-by: Mr NeilBrown <neilb@suse.de>
Change-Id: I479df29d1ddfb4e3d82a26b5fb567f3432dad8af
Reviewed-on: https://review.whamcloud.com/36845
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: James Simmons <jsimmons@infradead.org>
Reviewed-by: Shaun Tancheff <shaun.tancheff@hpe.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/include/lustre_net.h
lustre/ptlrpc/events.c
lustre/ptlrpc/niobuf.c
lustre/ptlrpc/ptlrpc_internal.h