[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <Y4Slz8XC5/m+TZef@unreal>
Date: Mon, 28 Nov 2022 14:13:03 +0200
From: Leon Romanovsky <leon@...nel.org>
To: zhang.songyi@....com.cn
Cc: yishaih@...dia.com, jgg@...pe.ca, linux-rdma@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH linux-next] RDMA/mlx4: remove NULL check before dev_{put,
hold}
On Mon, Nov 28, 2022 at 08:00:29PM +0800, zhang.songyi@....com.cn wrote:
> From: zhang songyi <zhang.songyi@....com.cn>
>
> The call netdev_{put, hold} of dev_{put, hold} will check NULL,
> so there is no need to check before using dev_{put, hold}.
>
> Fix the following coccicheck warnings:
> /drivers/infiniband/hw/mlx4/main.c:1311:2-10: WARNING:
> WARNING NULL check before dev_{put, hold} functions is not needed.
>
> /drivers/infiniband/hw/mlx4/main.c:148:2-10: WARNING:
> WARNING NULL check before dev_{put, hold} functions is not needed.
>
> /drivers/infiniband/hw/mlx4/main.c:1959:3-11: WARNING:
> WARNING NULL check before dev_{put, hold} functions is not needed.
>
> /drivers/infiniband/hw/mlx4/main.c:1962:3-10: WARNING:
> WARNING NULL check before dev_{put, hold} functions is not needed.
>
> Signed-off-by: zhang songyi <zhang.songyi@....com.cn>
> ---
> drivers/infiniband/hw/mlx4/main.c | 12 ++++--------
> 1 file changed, 4 insertions(+), 8 deletions(-)
>
The patch needs to be based on this repository:
https://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma.git/
branch: for-next
Thanks
Powered by blists - more mailing lists