Re: [PATCH] qedr: fix resource leak in qedr_create_qp

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

Thank you for your comment.
I will re-label the goto statements and post the patch as version 2.

Thanks,
Keita

2020年9月10日(木) 22:24 Markus Elfring <Markus.Elfring@xxxxxx>:
>
> > Fix this by adding a new goto label that calls qedr_free_qp_resources.
>
>
> > +++ b/drivers/infiniband/hw/qedr/verbs.c
>
> > @@ -2165,11 +2187,13 @@ struct ib_qp *qedr_create_qp(struct ib_pd *ibpd,
>
> >       return &qp->ibqp;
> >
> > +err2:
> > +     qedr_free_qp_resources(dev, qp, udata);
> >  err:
> >       kfree(qp);
>
> I propose to choose further alternatives for numbered labels.
> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/coding-style.rst?id=7fe10096c1508c7f033d34d0741809f8eecc1ed4#n485
>
> Regards,
> Markus




[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux