diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-09-14 13:37:28 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-09-14 13:37:28 -0400 |
commit | d7e9660ad9d5e0845f52848bce31bcf5cdcdea6b (patch) | |
tree | c6c67d145771187b194d79d603742b31090a59d6 /net/sched/cls_api.c | |
parent | b8cb48aae1b8c50b37dcb7710363aa69a7a0d9ca (diff) | |
parent | 13af7a6ea502fcdd4c0e3d7de6e332b102309491 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6: (1623 commits)
netxen: update copyright
netxen: fix tx timeout recovery
netxen: fix file firmware leak
netxen: improve pci memory access
netxen: change firmware write size
tg3: Fix return ring size breakage
netxen: build fix for INET=n
cdc-phonet: autoconfigure Phonet address
Phonet: back-end for autoconfigured addresses
Phonet: fix netlink address dump error handling
ipv6: Add IFA_F_DADFAILED flag
net: Add DEVTYPE support for Ethernet based devices
mv643xx_eth.c: remove unused txq_set_wrr()
ucc_geth: Fix hangs after switching from full to half duplex
ucc_geth: Rearrange some code to avoid forward declarations
phy/marvell: Make non-aneg speed/duplex forcing work for 88E1111 PHYs
drivers/net/phy: introduce missing kfree
drivers/net/wan: introduce missing kfree
net: force bridge module(s) to be GPL
Subject: [PATCH] appletalk: Fix skb leak when ipddp interface is not loaded
...
Fixed up trivial conflicts:
- arch/x86/include/asm/socket.h
converted to <asm-generic/socket.h> in the x86 tree. The generic
header has the same new #define's, so that works out fine.
- drivers/net/tun.c
fix conflict between 89f56d1e9 ("tun: reuse struct sock fields") that
switched over to using 'tun->socket.sk' instead of the redundantly
available (and thus removed) 'tun->sk', and 2b980dbd ("lsm: Add hooks
to the TUN driver") which added a new 'tun->sk' use.
Noted in 'next' by Stephen Rothwell.
Diffstat (limited to 'net/sched/cls_api.c')
-rw-r--r-- | net/sched/cls_api.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/net/sched/cls_api.c b/net/sched/cls_api.c index 09cdcdfe7e91..6a536949cdc0 100644 --- a/net/sched/cls_api.c +++ b/net/sched/cls_api.c | |||
@@ -168,8 +168,7 @@ replay: | |||
168 | 168 | ||
169 | /* Find qdisc */ | 169 | /* Find qdisc */ |
170 | if (!parent) { | 170 | if (!parent) { |
171 | struct netdev_queue *dev_queue = netdev_get_tx_queue(dev, 0); | 171 | q = dev->qdisc; |
172 | q = dev_queue->qdisc_sleeping; | ||
173 | parent = q->handle; | 172 | parent = q->handle; |
174 | } else { | 173 | } else { |
175 | q = qdisc_lookup(dev, TC_H_MAJ(t->tcm_parent)); | 174 | q = qdisc_lookup(dev, TC_H_MAJ(t->tcm_parent)); |
@@ -181,6 +180,9 @@ replay: | |||
181 | if ((cops = q->ops->cl_ops) == NULL) | 180 | if ((cops = q->ops->cl_ops) == NULL) |
182 | return -EINVAL; | 181 | return -EINVAL; |
183 | 182 | ||
183 | if (cops->tcf_chain == NULL) | ||
184 | return -EOPNOTSUPP; | ||
185 | |||
184 | /* Do we search for filter, attached to class? */ | 186 | /* Do we search for filter, attached to class? */ |
185 | if (TC_H_MIN(parent)) { | 187 | if (TC_H_MIN(parent)) { |
186 | cl = cops->get(q, parent); | 188 | cl = cops->get(q, parent); |
@@ -405,7 +407,6 @@ static int tcf_node_dump(struct tcf_proto *tp, unsigned long n, | |||
405 | static int tc_dump_tfilter(struct sk_buff *skb, struct netlink_callback *cb) | 407 | static int tc_dump_tfilter(struct sk_buff *skb, struct netlink_callback *cb) |
406 | { | 408 | { |
407 | struct net *net = sock_net(skb->sk); | 409 | struct net *net = sock_net(skb->sk); |
408 | struct netdev_queue *dev_queue; | ||
409 | int t; | 410 | int t; |
410 | int s_t; | 411 | int s_t; |
411 | struct net_device *dev; | 412 | struct net_device *dev; |
@@ -424,15 +425,16 @@ static int tc_dump_tfilter(struct sk_buff *skb, struct netlink_callback *cb) | |||
424 | if ((dev = dev_get_by_index(&init_net, tcm->tcm_ifindex)) == NULL) | 425 | if ((dev = dev_get_by_index(&init_net, tcm->tcm_ifindex)) == NULL) |
425 | return skb->len; | 426 | return skb->len; |
426 | 427 | ||
427 | dev_queue = netdev_get_tx_queue(dev, 0); | ||
428 | if (!tcm->tcm_parent) | 428 | if (!tcm->tcm_parent) |
429 | q = dev_queue->qdisc_sleeping; | 429 | q = dev->qdisc; |
430 | else | 430 | else |
431 | q = qdisc_lookup(dev, TC_H_MAJ(tcm->tcm_parent)); | 431 | q = qdisc_lookup(dev, TC_H_MAJ(tcm->tcm_parent)); |
432 | if (!q) | 432 | if (!q) |
433 | goto out; | 433 | goto out; |
434 | if ((cops = q->ops->cl_ops) == NULL) | 434 | if ((cops = q->ops->cl_ops) == NULL) |
435 | goto errout; | 435 | goto errout; |
436 | if (cops->tcf_chain == NULL) | ||
437 | goto errout; | ||
436 | if (TC_H_MIN(tcm->tcm_parent)) { | 438 | if (TC_H_MIN(tcm->tcm_parent)) { |
437 | cl = cops->get(q, tcm->tcm_parent); | 439 | cl = cops->get(q, tcm->tcm_parent); |
438 | if (cl == 0) | 440 | if (cl == 0) |