diff options
author | Eric Dumazet <dada1@cosmosbay.com> | 2008-01-02 00:58:02 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-01-28 18:00:31 -0500 |
commit | 9a429c4983deae020f1e757ecc8f547b6d4e2f2b (patch) | |
tree | 172e27a5866e182b902cd77506df1755aafadb60 /net/sched | |
parent | b950dfcf504842a0f2bb142a33ef938f1c00d300 (diff) |
[NET]: Add some acquires/releases sparse annotations.
Add __acquires() and __releases() annotations to suppress some sparse
warnings.
example of warnings :
net/ipv4/udp.c:1555:14: warning: context imbalance in 'udp_seq_start' - wrong
count at exit
net/ipv4/udp.c:1571:13: warning: context imbalance in 'udp_seq_stop' -
unexpected unlock
Signed-off-by: Eric Dumazet <dada1@cosmosbay.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sched')
-rw-r--r-- | net/sched/sch_generic.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/net/sched/sch_generic.c b/net/sched/sch_generic.c index 9be2f152455a..ea5a05b172c4 100644 --- a/net/sched/sch_generic.c +++ b/net/sched/sch_generic.c | |||
@@ -40,12 +40,16 @@ | |||
40 | */ | 40 | */ |
41 | 41 | ||
42 | void qdisc_lock_tree(struct net_device *dev) | 42 | void qdisc_lock_tree(struct net_device *dev) |
43 | __acquires(dev->queue_lock) | ||
44 | __acquires(dev->ingress_lock) | ||
43 | { | 45 | { |
44 | spin_lock_bh(&dev->queue_lock); | 46 | spin_lock_bh(&dev->queue_lock); |
45 | spin_lock(&dev->ingress_lock); | 47 | spin_lock(&dev->ingress_lock); |
46 | } | 48 | } |
47 | 49 | ||
48 | void qdisc_unlock_tree(struct net_device *dev) | 50 | void qdisc_unlock_tree(struct net_device *dev) |
51 | __releases(dev->ingress_lock) | ||
52 | __releases(dev->queue_lock) | ||
49 | { | 53 | { |
50 | spin_unlock(&dev->ingress_lock); | 54 | spin_unlock(&dev->ingress_lock); |
51 | spin_unlock_bh(&dev->queue_lock); | 55 | spin_unlock_bh(&dev->queue_lock); |