Bug 68011

Summary: spin_unlock is missed in function (netpoll_send_skb_on_dev) in file (linux-3.12/net/core/netpoll.c)
Product: Networking Reporter: Ahmed Tamrawi (atamrawi)
Component: OtherAssignee: Stephen Hemminger (stephen)
Status: NEW ---    
Severity: normal CC: alan, atamrawi
Priority: P1    
Hardware: x86-64   
OS: Linux   
Kernel Version: 3.12 Subsystem:
Regression: No Bisected commit-id:
Attachments: An image showing the possible error/bug

Description Ahmed Tamrawi 2014-01-01 19:52:11 UTC
In function (netpoll_send_skb_on_dev) in file (linux-3.12/net/core/netpoll.c):

The structure (txq->_xmit_lock) gets successfully locked at line (383) by (__netif_tx_trylock(txq)) and unlocked by (__netif_tx_unlock(txq)) at line (398).

The problem occurs when the loop breaks at line (390) and the structure (txq->_xmit_lock) still locked. In that case, the structure (txq->_xmit_lock) never gets unlocked.

A possible solution is to call (__netif_tx_unlock(txq)) before the break at line (390)
Comment 1 Ahmed Tamrawi 2014-01-01 20:06:59 UTC
Created attachment 120491 [details]
An image showing the possible error/bug
Comment 2 Alan 2014-01-03 14:04:05 UTC
Please send a copy of this report to netdev@vger.kernel.org

Thanks