summaryrefslogtreecommitdiffstats
path: root/net/sched
diff options
context:
space:
mode:
authorThomas Graf2005-06-01 00:16:52 +0200
committerDavid S. Miller2005-06-01 00:16:52 +0200
commit486b53e59ca8cd07d91ad88375c1c884b15cc9bd (patch)
tree4130617e9bdef8fbaef12392584496223587bb50 /net/sched
parent[PKT_SCHED]: Fix dsmark to count ignored indices while walking (diff)
downloadkernel-qcow2-linux-486b53e59ca8cd07d91ad88375c1c884b15cc9bd.tar.gz
kernel-qcow2-linux-486b53e59ca8cd07d91ad88375c1c884b15cc9bd.tar.xz
kernel-qcow2-linux-486b53e59ca8cd07d91ad88375c1c884b15cc9bd.zip
[PKT_SCHED]: make dsmark try using pfifo instead of noop while grafting
Signed-off-by: Thomas Graf <tgraf@suug.ch> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sched')
-rw-r--r--net/sched/sch_dsmark.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/net/sched/sch_dsmark.c b/net/sched/sch_dsmark.c
index acbe9d2b3e15..a8c948f62978 100644
--- a/net/sched/sch_dsmark.c
+++ b/net/sched/sch_dsmark.c
@@ -73,8 +73,13 @@ static int dsmark_graft(struct Qdisc *sch,unsigned long arg,
DPRINTK("dsmark_graft(sch %p,[qdisc %p],new %p,old %p)\n",sch,p,new,
old);
- if (!new)
- new = &noop_qdisc;
+
+ if (new == NULL) {
+ new = qdisc_create_dflt(sch->dev, &pfifo_qdisc_ops);
+ if (new == NULL)
+ new = &noop_qdisc;
+ }
+
sch_tree_lock(sch);
*old = xchg(&p->q,new);
if (*old)