mirror of
https://gitee.com/bianbu-linux/linux-6.6
synced 2025-04-24 14:07:52 -04:00
xprtrdma: Release in-flight MRs on disconnect
Dan Aloni reports that when a server disconnects abruptly, a few memory regions are left DMA mapped. Over time this leak could pin enough I/O resources to slow or even deadlock an NFS/RDMA client. I found that if a transport disconnects before pending Send and FastReg WRs can be posted, the to-be-registered MRs are stranded on the req's rl_registered list and never released -- since they weren't posted, there's no Send completion to DMA unmap them. Reported-by: Dan Aloni <dan@kernelim.com> Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
This commit is contained in:
parent
d012a7190f
commit
5de55ce951
1 changed files with 2 additions and 0 deletions
|
@ -933,6 +933,8 @@ static void rpcrdma_req_reset(struct rpcrdma_req *req)
|
|||
|
||||
rpcrdma_regbuf_dma_unmap(req->rl_sendbuf);
|
||||
rpcrdma_regbuf_dma_unmap(req->rl_recvbuf);
|
||||
|
||||
frwr_reset(req);
|
||||
}
|
||||
|
||||
/* ASSUMPTION: the rb_allreqs list is stable for the duration,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue