[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <YPVyophPac6yjBws@kroah.com>
Date: Mon, 19 Jul 2021 14:40:02 +0200
From: Greg KH <gregkh@...uxfoundation.org>
To: Yang Yingliang <yangyingliang@...wei.com>
Cc: sudipm.mukherjee@...il.com, linux-kernel@...r.kernel.org,
stable@...r.kernel.org, davem@...emloft.net, sashal@...nel.org
Subject: Re: [PATCH 5.4] net: moxa: Use
devm_platform_get_and_ioremap_resource()
On Fri, Jul 16, 2021 at 05:32:45PM +0800, Yang Yingliang wrote:
> [ Upstream commit 35cba15a504bf4f585bb9d78f47b22b28a1a06b2 ]
>
> Use devm_platform_get_and_ioremap_resource() to simplify
> code and avoid a null-ptr-deref by checking 'res' in it.
>
> [yyl: since devm_platform_get_and_ioremap_resource() is introduced
> in linux-5.7, so just check the return value after calling
> platform_get_resource()]
>
> Signed-off-by: Yang Yingliang <yangyingliang@...wei.com>
> Signed-off-by: David S. Miller <davem@...emloft.net>
> ---
> drivers/net/ethernet/moxa/moxart_ether.c | 4 ++++
> 1 file changed, 4 insertions(+)
Now queued up, thanks.
greg k-h
Powered by blists - more mailing lists