Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 103394
b: refs/heads/master
c: 3e745dd
h: refs/heads/master
v: v3
  • Loading branch information
David S. Miller committed Jul 9, 2008
1 parent cc55a10 commit d9c580b
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5aa709954a32a646c0cf14fdf7c8834db4ff1c03
refs/heads/master: 3e745dd6950d72d19e4cb30dc44307e8d6671864
2 changes: 1 addition & 1 deletion trunk/include/net/irda/irda_device.h
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ int irda_device_is_receiving(struct net_device *dev);
/* Interface for internal use */
static inline int irda_device_txqueue_empty(const struct net_device *dev)
{
return skb_queue_empty(&dev->tx_queue.qdisc->q);
return qdisc_all_tx_empty(dev);
}
int irda_device_set_raw_mode(struct net_device* self, int status);
struct net_device *alloc_irdadev(int sizeof_priv);
Expand Down
9 changes: 9 additions & 0 deletions trunk/include/net/sch_generic.h
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,15 @@ static inline void qdisc_reset_all_tx(struct net_device *dev)
qdisc_reset(dev->tx_queue.qdisc);
}

/* Are all TX queues of the device empty? */
static inline bool qdisc_all_tx_empty(const struct net_device *dev)
{
const struct netdev_queue *txq = &dev->tx_queue;
const struct Qdisc *q = txq->qdisc;

return (q->q.qlen == 0);
}

static inline int __qdisc_enqueue_tail(struct sk_buff *skb, struct Qdisc *sch,
struct sk_buff_head *list)
{
Expand Down

0 comments on commit d9c580b

Please sign in to comment.