netdev
[Top] [All Lists]

[IPV4/IPV6] Replace spin_lock_irq with spin_lock_bh

To: "David S. Miller" <davem@xxxxxxxxxxxxx>, netdev@xxxxxxxxxxx
Subject: [IPV4/IPV6] Replace spin_lock_irq with spin_lock_bh
From: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx>
Date: Thu, 2 Jun 2005 19:44:04 +1000
Sender: netdev-bounce@xxxxxxxxxxx
User-agent: Mutt/1.5.9i
Hi Dave:

In light of my recent patch to net/ipv4/udp.c that replaced the
spin_lock_irq calls on the receive queue lock with spin_lock_bh,
here is a similar patch for all other occurences of spin_lock_irq
on receive/error queue locks in IPv4 and IPv6.

In these stacks, we know that they can only be entered from user
or softirq context.  Therefore it's safe to disable BH only.

Signed-off-by: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx> 

Since this patch simply improves the consistent use of locking
primitives rather fixing any real bugs, it should probably go
into net-2.6.13.

Cheers,
-- 
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <herbert@xxxxxxxxxxxxxxxxxxx>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

Attachment: p
Description: Text document

<Prev in Thread] Current Thread [Next in Thread>