]> err.no Git - linux-2.6/blobdiff - net/core/rtnetlink.c
Merge git://git.infradead.org/embedded-2.6
[linux-2.6] / net / core / rtnetlink.c
index ca32ddb8ad17c15a7c758330f47524a4587946d8..71edb8b36341622df50ec48f32127b1be490b19f 100644 (file)
@@ -498,7 +498,8 @@ int rtnetlink_put_metrics(struct sk_buff *skb, u32 *metrics)
        return nla_nest_end(skb, mx);
 
 nla_put_failure:
-       return nla_nest_cancel(skb, mx);
+       nla_nest_cancel(skb, mx);
+       return -EMSGSIZE;
 }
 
 int rtnl_put_cacheinfo(struct sk_buff *skb, struct dst_entry *dst, u32 id,
@@ -604,6 +605,7 @@ static int rtnl_fill_ifinfo(struct sk_buff *skb, struct net_device *dev,
                            int type, u32 pid, u32 seq, u32 change,
                            unsigned int flags)
 {
+       struct netdev_queue *txq;
        struct ifinfomsg *ifm;
        struct nlmsghdr *nlh;
        struct net_device_stats *stats;
@@ -634,8 +636,9 @@ static int rtnl_fill_ifinfo(struct sk_buff *skb, struct net_device *dev,
        if (dev->master)
                NLA_PUT_U32(skb, IFLA_MASTER, dev->master->ifindex);
 
-       if (dev->qdisc_sleeping)
-               NLA_PUT_STRING(skb, IFLA_QDISC, dev->qdisc_sleeping->ops->id);
+       txq = netdev_get_tx_queue(dev, 0);
+       if (txq->qdisc_sleeping)
+               NLA_PUT_STRING(skb, IFLA_QDISC, txq->qdisc_sleeping->ops->id);
 
        if (1) {
                struct rtnl_link_ifmap map = {