]> git.baikalelectronics.ru Git - kernel.git/commit
forcedeth: xmit lock fix
authorAyaz Abdulla <aabdulla@nvidia.com>
Fri, 9 Jan 2009 11:03:44 +0000 (11:03 +0000)
committerDavid S. Miller <davem@davemloft.net>
Sun, 11 Jan 2009 08:07:32 +0000 (00:07 -0800)
commitea8fed7b2d7b6d1cf5d50de184ea1a3a90764f06
treebcd1265262417bd61b6f4b37fada2fca80c13b48
parentbdbc65ef9b5e89da655316197d1a317220427a8a
forcedeth: xmit lock fix

This patch fixes a potential race condition between xmit thread and xmit
completion thread. The calculation of empty tx descriptors is not
performed under the lock. This could cause it to set the stop flag while
the completion thread finishes all tx's. This will result in the tx
queue in stopped state and no one to wake it up.

Signed-off-by: Ayaz Abdulla <aabdulla@nvidia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/forcedeth.c