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] [day] [month] [year] [list]
Date:   Wed, 28 Oct 2020 15:31:03 +0200
From:   Maor Gottlieb <maorg@...dia.com>
To:     Jason Gunthorpe <jgg@...dia.com>
CC:     <linux-rdma@...r.kernel.org>,
        Guoqing Jiang <guoqing.jiang@...ud.ionos.com>,
        Christoph Hellwig <hch@....de>,
        Jack Wang <jinpu.wang@...ud.ionos.com>,
        Leon Romanovsky <leonro@...dia.com>,
        Chao Leng <lengchao@...wei.com>,
        Santosh Shilimkar <santosh.shilimkar@...cle.com>,
        Keith Busch <kbusch@...nel.org>,
        <linux-nvme@...ts.infradead.org>,
        "Max Gurtovoy" <mgurtovoy@...dia.com>, <netdev@...r.kernel.org>,
        <rds-devel@....oracle.com>, Sagi Grimberg <sagi@...mberg.me>
Subject: Re: [PATCH rdma v2] RDMA: Add rdma_connect_locked()


On 10/28/2020 2:14 PM, Jason Gunthorpe wrote:
> On Wed, Oct 28, 2020 at 11:19:14AM +0200, Maor Gottlieb wrote:
>>> +			struct rdma_conn_param *conn_param)
>>>    {
>>>    	struct rdma_id_private *id_priv =
>>>    		container_of(id, struct rdma_id_private, id);
>>>    	int ret;
>>> -	mutex_lock(&id_priv->handler_mutex);
>> You need to delete the mutex_unlock in success path too.
> Gaaaaah. Just goes to prove I shouldn't write patches with a child on
> my lap :\
>
> diff --git a/drivers/infiniband/core/cma.c b/drivers/infiniband/core/cma.c
> index f58d19881524dc..a77750b8954db0 100644
> --- a/drivers/infiniband/core/cma.c
> +++ b/drivers/infiniband/core/cma.c
> @@ -4072,7 +4072,6 @@ int rdma_connect_locked(struct rdma_cm_id *id,
>   		ret = -ENOSYS;
>   	if (ret)
>   		goto err_state;
> -	mutex_unlock(&id_priv->handler_mutex);
>   	return 0;
>   err_state:
>   	cma_comp_exch(id_priv, RDMA_CM_CONNECT, RDMA_CM_ROUTE_RESOLVED);
>
> Thanks,
> Jason

Reviewed-by: Maor Gottlieb <maorg@...dia.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ