diff options
author | David S. Miller <davem@davemloft.net> | 2008-07-17 03:53:03 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-07-17 22:21:30 -0400 |
commit | 83874000929ed63aef30b44083a9f713135ff040 (patch) | |
tree | 7646fd185751cad8665eca19aa3f87d13c37eade /include/net/sch_generic.h | |
parent | c7e4f3bbb4ba4e48ab3b529d5016e454cee1ccd6 (diff) |
pkt_sched: Kill netdev_queue lock.
We can simply use the qdisc->q.lock for all of the
qdisc tree synchronization.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/sch_generic.h')
-rw-r--r-- | include/net/sch_generic.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/include/net/sch_generic.h b/include/net/sch_generic.h index 1eef8d0c9990..2902a42564f0 100644 --- a/include/net/sch_generic.h +++ b/include/net/sch_generic.h | |||
@@ -163,6 +163,11 @@ struct tcf_proto | |||
163 | struct tcf_proto_ops *ops; | 163 | struct tcf_proto_ops *ops; |
164 | }; | 164 | }; |
165 | 165 | ||
166 | static inline spinlock_t *qdisc_lock(struct Qdisc *qdisc) | ||
167 | { | ||
168 | return &qdisc->q.lock; | ||
169 | } | ||
170 | |||
166 | static inline struct Qdisc *qdisc_root(struct Qdisc *qdisc) | 171 | static inline struct Qdisc *qdisc_root(struct Qdisc *qdisc) |
167 | { | 172 | { |
168 | return qdisc->dev_queue->qdisc; | 173 | return qdisc->dev_queue->qdisc; |
@@ -172,7 +177,7 @@ static inline spinlock_t *qdisc_root_lock(struct Qdisc *qdisc) | |||
172 | { | 177 | { |
173 | struct Qdisc *root = qdisc_root(qdisc); | 178 | struct Qdisc *root = qdisc_root(qdisc); |
174 | 179 | ||
175 | return &root->dev_queue->lock; | 180 | return qdisc_lock(root); |
176 | } | 181 | } |
177 | 182 | ||
178 | static inline struct net_device *qdisc_dev(struct Qdisc *qdisc) | 183 | static inline struct net_device *qdisc_dev(struct Qdisc *qdisc) |