]> www.infradead.org Git - users/dwmw2/linux.git/commit
net:mcf8390: Use platform_get_irq() to get the interrupt
authorMinghao Chi (CGEL ZTE) <chi.minghao@zte.com.cn>
Tue, 8 Mar 2022 06:43:09 +0000 (06:43 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 8 Apr 2022 12:39:48 +0000 (14:39 +0200)
commit18a4417a192f6d2527792d71963a06d36f6dd1b5
treec53be39a5296ad8a7cc787c167c7a98d7c80a4e0
parent102d7f6c2eff2e7a3e1f9271a61d0c006dce1291
net:mcf8390: Use platform_get_irq() to get the interrupt

[ Upstream commit 2a760554dcba450d3ad61b32375b50ed6d59a87c ]

It is not recommened to use platform_get_resource(pdev, IORESOURCE_IRQ)
for requesting IRQ's resources any more, as they can be not ready yet in
case of DT-booting.

platform_get_irq() instead is a recommended way for getting IRQ even if
it was not retrieved earlier.

It also makes code simpler because we're getting "int" value right away
and no conversion from resource to int is required.

Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: Minghao Chi (CGEL ZTE) <chi.minghao@zte.com.cn>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/8390/mcf8390.c