]> git.baikalelectronics.ru Git - kernel.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)
committerDavid S. Miller <davem@davemloft.net>
Wed, 9 Mar 2022 12:14:30 +0000 (12:14 +0000)
commit3c9b6016c8432af910f8df64dd73b096edf857aa
tree9b9017bb86def4209cda900fa1dcce892ba04885
parent744258d10c921d3fc1ca835df78000d24c62a86c
net:mcf8390: Use platform_get_irq() to get the interrupt

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>
drivers/net/ethernet/8390/mcf8390.c