diff options
Diffstat (limited to 'net/sched')
-rw-r--r-- | net/sched/sch_dsmark.c | 9 |
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, | |||
73 | 73 | ||
74 | DPRINTK("dsmark_graft(sch %p,[qdisc %p],new %p,old %p)\n",sch,p,new, | 74 | DPRINTK("dsmark_graft(sch %p,[qdisc %p],new %p,old %p)\n",sch,p,new, |
75 | old); | 75 | old); |
76 | if (!new) | 76 | |
77 | new = &noop_qdisc; | 77 | if (new == NULL) { |
78 | new = qdisc_create_dflt(sch->dev, &pfifo_qdisc_ops); | ||
79 | if (new == NULL) | ||
80 | new = &noop_qdisc; | ||
81 | } | ||
82 | |||
78 | sch_tree_lock(sch); | 83 | sch_tree_lock(sch); |
79 | *old = xchg(&p->q,new); | 84 | *old = xchg(&p->q,new); |
80 | if (*old) | 85 | if (*old) |