net: mido: mdio-mux-bcm-iproc: Use devm_platform_get_and_ioremap_resource()

[ Upstream commit 8a55a73433 ]

Use devm_platform_get_and_ioremap_resource() to simplify
code and avoid a null-ptr-deref by checking 'res' in it.

Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
Yang Yingliang 2021-06-10 17:17:12 +08:00 • committed by Greg Kroah-Hartman
commit dd18ad96a9