Do not call cancel_rearming_delayed_work() if there is no pending work. Signed-off-by: Jason Wessel --- net/core/netpoll.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) Index: linux-2.6.21/net/core/netpoll.c =================================================================== --- linux-2.6.21.orig/net/core/netpoll.c +++ linux-2.6.21/net/core/netpoll.c @@ -781,8 +781,10 @@ void netpoll_cleanup(struct netpoll *np) if (atomic_dec_and_test(&npinfo->refcnt)) { skb_queue_purge(&npinfo->arp_tx); skb_queue_purge(&npinfo->txq); - cancel_rearming_delayed_work(&npinfo->tx_work); - flush_scheduled_work(); + if (delayed_work_pending(&npinfo->tx_work)) { + cancel_rearming_delayed_work(&npinfo->tx_work); + flush_scheduled_work(); + } kfree(npinfo); }