[PATCH 2/2]: Spider ethernet driver -- protect chain head

Eugene Surovegin ebs at ebshome.net
Sat Apr 22 10:11:40 EST 2006


On Fri, Apr 21, 2006 at 06:45:51PM -0500, Linas Vepstas wrote:
> Prevent a potential race. If two threads are both calling
> the transmit routine, both can potentially try to grab the
> same dma descriptor. Serialize access to the head of the
> tx ring with spinlocks.

Two threads cannot be in spider_net_xmit() simultaneosuly because 
hard_start_xmit entry point is already protected by net_device 
xmit_lock, see Documentation/net/netdevices.txt

-- 
Eugene




More information about the Linuxppc-dev mailing list