mirror of https://github.com/ipxe/ipxe.git
[forcedeth] Exit poll() as early as possible if no work to do
Signed-off-by: Thomas Miletich <thomas.miletich@gmail.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>pull/1/head
parent
67dc832d15
commit
f122515515
|
@ -990,6 +990,10 @@ forcedeth_poll ( struct net_device *netdev )
|
|||
|
||||
status = readl ( ioaddr + NvRegIrqStatus ) & NVREG_IRQSTAT_MASK;
|
||||
|
||||
/* Return when no interrupts have been triggered */
|
||||
if ( ! status )
|
||||
return;
|
||||
|
||||
/* Clear interrupts */
|
||||
writel ( NVREG_IRQSTAT_MASK, ioaddr + NvRegIrqStatus );
|
||||
|
||||
|
@ -1000,10 +1004,6 @@ forcedeth_poll ( struct net_device *netdev )
|
|||
if ( ( status & NVREG_IRQ_LINK ) || ! ( netdev_link_ok ( netdev ) ) )
|
||||
forcedeth_link_status ( netdev );
|
||||
|
||||
/* Return when no interrupts have been triggered */
|
||||
if ( ! status )
|
||||
return;
|
||||
|
||||
/* Process transmitted packets */
|
||||
nv_process_tx_packets ( netdev );
|
||||
|
||||
|
|
Loading…
Reference in New Issue