Re: [PATCH 03/11] drbd_transport_rdma: put kref for cm in dtr_path_established in error path
Philipp Reisner <[email protected]> Fri, 28 Jun 2024 11:40:31 +0200
| Newsgroups | dev.linux.lists.drbd-dev |
|---|---|
| Message-ID | <CADGDV=V4kpNPAWf6MsdswhbMqKPe5=qEMXkF_KBqXVM7W+aUhQ@mail.gmail.com> |
Hello Dongsheng, Please add more information why you think this change fixes a bug. Have you experienced a leak of cm structs? We got a RDMA_CM_EVENT_ESTABLISHED event. Even if DRBD does not do anything with this cm, we sill expect a RDMA_CM_EVENT_DISCONNECTED in the future. Is a problem in the handling of the disconnect? best regards, Philipp On Mon, Jun 24, 2024 at 9:28 AM zhengbing.huang <[email protected]> wrote: > > From: Dongsheng Yang <[email protected]> > > Signed-off-by: Dongsheng Yang <[email protected]> > --- > drbd/drbd_transport_rdma.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drbd/drbd_transport_rdma.c b/drbd/drbd_transport_rdma.c > index cfbae0e78..eccd0c6ce 100644 > --- a/drbd/drbd_transport_rdma.c > +++ b/drbd/drbd_transport_rdma.c > @@ -922,6 +922,7 @@ static void dtr_path_established(struct dtr_cm *cm) > atomic_set(&cs->active_state, PCS_INACTIVE); > wake_up(&cs->wq); > } > + kref_put(&cm->kref, dtr_destroy_cm); > return; > } > > -- > 2.27.0 >