* [PATCH 2.6] TBF: do not oops when user tries to attach/show filter
@ 2004-05-26 4:12 Dmitry Torokhov
0 siblings, 0 replies; only message in thread
From: Dmitry Torokhov @ 2004-05-26 4:12 UTC (permalink / raw)
To: netdev; +Cc: David S. Miller
TBF does not allow attaching filters; implement dummy tcf_chain method to
avoid oopsing.
--
Dmitry
===================================================================
ChangeSet@1.1750, 2004-05-25 22:54:30-05:00, dtor_core@ameritech.net
[NET_SCHED] Do not oops when user tries to attach a filter to a TBF qdisc.
(TBF does not allow attaching filters as it has only one class,
filter should be attached either to TBF's parent or to its child)
sch_tbf.c | 6 ++++++
1 files changed, 6 insertions(+)
===================================================================
diff -Nru a/net/sched/sch_tbf.c b/net/sched/sch_tbf.c
--- a/net/sched/sch_tbf.c 2004-05-25 22:57:37 -05:00
+++ b/net/sched/sch_tbf.c 2004-05-25 22:57:37 -05:00
@@ -495,6 +495,11 @@
}
}
+static struct tcf_proto **tbf_find_tcf(struct Qdisc *sch, unsigned long cl)
+{
+ return NULL;
+}
+
static struct Qdisc_class_ops tbf_class_ops =
{
.graft = tbf_graft,
@@ -504,6 +509,7 @@
.change = tbf_change_class,
.delete = tbf_delete,
.walk = tbf_walk,
+ .tcf_chain = tbf_find_tcf,
.dump = tbf_dump_class,
};
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2004-05-26 4:12 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-05-26 4:12 [PATCH 2.6] TBF: do not oops when user tries to attach/show filter Dmitry Torokhov
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).