aboutsummaryrefslogtreecommitdiffstats
path: root/net/sched/sch_hfsc.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2008-07-08 19:55:56 -0400
committerDavid S. Miller <davem@davemloft.net>2008-07-08 19:55:56 -0400
commitbb949fbd1878973c3539d9aecff52f284482a937 (patch)
treee8bde854b18be79723502167c16e2131914a75b7 /net/sched/sch_hfsc.c
parente65d22e18038eed7307276e46810d884c402d57d (diff)
netdev: Create netdev_queue abstraction.
A netdev_queue is an entity managed by a qdisc. Currently there is one RX and one TX queue, and a netdev_queue merely contains a backpointer to the net_device. The Qdisc struct is augmented with a netdev_queue pointer as well. Eventually the 'dev' Qdisc member will go away and we will have the resulting hierarchy: net_device --> netdev_queue --> Qdisc Also, qdisc_alloc() and qdisc_create_dflt() now take a netdev_queue pointer argument. Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sched/sch_hfsc.c')
-rw-r--r--net/sched/sch_hfsc.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/net/sched/sch_hfsc.c b/net/sched/sch_hfsc.c
index 3a8267246a4f..5a22fec4eadd 100644
--- a/net/sched/sch_hfsc.c
+++ b/net/sched/sch_hfsc.c
@@ -1083,7 +1083,8 @@ hfsc_change_class(struct Qdisc *sch, u32 classid, u32 parentid,
1083 cl->refcnt = 1; 1083 cl->refcnt = 1;
1084 cl->sched = q; 1084 cl->sched = q;
1085 cl->cl_parent = parent; 1085 cl->cl_parent = parent;
1086 cl->qdisc = qdisc_create_dflt(sch->dev, &pfifo_qdisc_ops, classid); 1086 cl->qdisc = qdisc_create_dflt(sch->dev, sch->dev_queue,
1087 &pfifo_qdisc_ops, classid);
1087 if (cl->qdisc == NULL) 1088 if (cl->qdisc == NULL)
1088 cl->qdisc = &noop_qdisc; 1089 cl->qdisc = &noop_qdisc;
1089 INIT_LIST_HEAD(&cl->children); 1090 INIT_LIST_HEAD(&cl->children);
@@ -1201,7 +1202,8 @@ hfsc_graft_class(struct Qdisc *sch, unsigned long arg, struct Qdisc *new,
1201 if (cl->level > 0) 1202 if (cl->level > 0)
1202 return -EINVAL; 1203 return -EINVAL;
1203 if (new == NULL) { 1204 if (new == NULL) {
1204 new = qdisc_create_dflt(sch->dev, &pfifo_qdisc_ops, 1205 new = qdisc_create_dflt(sch->dev, sch->dev_queue,
1206 &pfifo_qdisc_ops,
1205 cl->cl_common.classid); 1207 cl->cl_common.classid);
1206 if (new == NULL) 1208 if (new == NULL)
1207 new = &noop_qdisc; 1209 new = &noop_qdisc;
@@ -1443,7 +1445,8 @@ hfsc_init_qdisc(struct Qdisc *sch, struct nlattr *opt)
1443 q->root.cl_common.classid = sch->handle; 1445 q->root.cl_common.classid = sch->handle;
1444 q->root.refcnt = 1; 1446 q->root.refcnt = 1;
1445 q->root.sched = q; 1447 q->root.sched = q;
1446 q->root.qdisc = qdisc_create_dflt(sch->dev, &pfifo_qdisc_ops, 1448 q->root.qdisc = qdisc_create_dflt(sch->dev, sch->dev_queue,
1449 &pfifo_qdisc_ops,
1447 sch->handle); 1450 sch->handle);
1448 if (q->root.qdisc == NULL) 1451 if (q->root.qdisc == NULL)
1449 q->root.qdisc = &noop_qdisc; 1452 q->root.qdisc = &noop_qdisc;