pkt_sched: Add qdisc_tx_is_noop() helper and use in IPV6.

This indicates if the NOOP scheduler is what is active for TX on a
given device.

Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
David S. Miller
2008-07-08 23:01:27 -07:00
parent 6fa9864b53
commit 052979499c
2 changed files with 10 additions and 3 deletions

View File

@@ -229,10 +229,9 @@ const struct in6_addr in6addr_linklocal_allnodes = IN6ADDR_LINKLOCAL_ALLNODES_IN
const struct in6_addr in6addr_linklocal_allrouters = IN6ADDR_LINKLOCAL_ALLROUTERS_INIT;
/* Check if a valid qdisc is available */
static inline int addrconf_qdisc_ok(struct net_device *dev)
static inline bool addrconf_qdisc_ok(const struct net_device *dev)
{
struct netdev_queue *txq = &dev->tx_queue;
return (txq->qdisc != &noop_qdisc);
return !qdisc_tx_is_noop(dev);
}
/* Check if a route is valid prefix route */