lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAJpMwyhd_=4vwKT6TXnyQ6sHyXSHUm44Z=OWK36smonZC=ucGg@mail.gmail.com>
Date:   Fri, 6 Aug 2021 12:09:57 +0200
From:   Haris Iqbal <haris.iqbal@...os.com>
To:     Christophe JAILLET <christophe.jaillet@...adoo.fr>
Cc:     Jinpu Wang <jinpu.wang@...os.com>,
        Doug Ledford <dledford@...hat.com>,
        Jason Gunthorpe <jgg@...pe.ca>,
        RDMA mailing list <linux-rdma@...r.kernel.org>,
        linux-kernel@...r.kernel.org, kernel-janitors@...r.kernel.org
Subject: Re: [PATCH] RDMA/rtrs: Remove a useless kfree

On Thu, Aug 5, 2021 at 7:43 PM Christophe JAILLET
<christophe.jaillet@...adoo.fr> wrote:
>
> 'sess->rbufs' is known to be NULL here, so there is no point in kfree'ing
> it. It is just a no-op.
>
> Remove the useless kfree.
>
> Signed-off-by: Christophe JAILLET <christophe.jaillet@...adoo.fr>

Thanks
Acked-by: Md Haris Iqbal <haris.iqbal@...os.com>

> ---
>  drivers/infiniband/ulp/rtrs/rtrs-clt.c | 1 -
>  1 file changed, 1 deletion(-)
>
> diff --git a/drivers/infiniband/ulp/rtrs/rtrs-clt.c b/drivers/infiniband/ulp/rtrs/rtrs-clt.c
> index ece3205531b8..fc440a08e112 100644
> --- a/drivers/infiniband/ulp/rtrs/rtrs-clt.c
> +++ b/drivers/infiniband/ulp/rtrs/rtrs-clt.c
> @@ -1844,7 +1844,6 @@ static int rtrs_rdma_conn_established(struct rtrs_clt_con *con,
>                 }
>
>                 if (!sess->rbufs) {
> -                       kfree(sess->rbufs);
>                         sess->rbufs = kcalloc(queue_depth, sizeof(*sess->rbufs),
>                                               GFP_KERNEL);
>                         if (!sess->rbufs)
> --
> 2.30.2
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ