RDMA/rxe: Remove tasklet call from rxe_cq.c
authorBob Pearson <rpearsonhpe@gmail.com>
Mon, 27 Mar 2023 21:56:44 +0000 (16:56 -0500)
committerLeon Romanovsky <leon@kernel.org>
Wed, 29 Mar 2023 11:25:11 +0000 (14:25 +0300)
commit78b26a335310a097d6b22581b706050db42f196c
tree9f128a87e8cf865406b9d63613c6f6f4b93d838a
parentcba968e33e5df086b6e681179d199f959bc71f33
RDMA/rxe: Remove tasklet call from rxe_cq.c

Remove the tasklet call in rxe_cq.c and also the is_dying in the
cq struct. There is no reason for the rxe driver to defer the call
to the cq completion handler by scheduling a tasklet. rxe_cq_post()
is not called in a hard irq context.

The rxe driver currently is incorrect because the tasklet call is
made without protecting the cq pointer with a reference from having
the underlying memory freed before the deferred routine is called.
Executing the comp_handler inline fixes this problem.

Fixes: 8700e3e7c485 ("Soft RoCE driver")
Signed-off-by: Bob Pearson <rpearsonhpe@gmail.com>
Link: https://lore.kernel.org/r/20230327215643.10410-1-rpearsonhpe@gmail.com
Acked-by: Zhu Yanjun <zyjzyj2000@gmail.com>
Signed-off-by: Leon Romanovsky <leon@kernel.org>
drivers/infiniband/sw/rxe/rxe_cq.c
drivers/infiniband/sw/rxe/rxe_verbs.c
drivers/infiniband/sw/rxe/rxe_verbs.h