Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
This commit is contained in:
@@ -336,12 +336,24 @@ extern void qdisc_calculate_pkt_len(struct sk_buff *skb,
|
||||
extern void tcf_destroy(struct tcf_proto *tp);
|
||||
extern void tcf_destroy_chain(struct tcf_proto **fl);
|
||||
|
||||
/* Reset all TX qdiscs of a device. */
|
||||
/* Reset all TX qdiscs greater then index of a device. */
|
||||
static inline void qdisc_reset_all_tx_gt(struct net_device *dev, unsigned int i)
|
||||
{
|
||||
struct Qdisc *qdisc;
|
||||
|
||||
for (; i < dev->num_tx_queues; i++) {
|
||||
qdisc = netdev_get_tx_queue(dev, i)->qdisc;
|
||||
if (qdisc) {
|
||||
spin_lock_bh(qdisc_lock(qdisc));
|
||||
qdisc_reset(qdisc);
|
||||
spin_unlock_bh(qdisc_lock(qdisc));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static inline void qdisc_reset_all_tx(struct net_device *dev)
|
||||
{
|
||||
unsigned int i;
|
||||
for (i = 0; i < dev->num_tx_queues; i++)
|
||||
qdisc_reset(netdev_get_tx_queue(dev, i)->qdisc);
|
||||
qdisc_reset_all_tx_gt(dev, 0);
|
||||
}
|
||||
|
||||
/* Are all TX queues of the device empty? */
|
||||
|
Reference in New Issue
Block a user