All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH net] net: sched: Remove TCA_OPTIONS from policy
@ 2018-10-24 15:32 David Ahern
  2018-10-24 21:35 ` David Miller
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: David Ahern @ 2018-10-24 15:32 UTC (permalink / raw)
  To: netdev, davem, pupilla; +Cc: David Ahern

From: David Ahern <dsahern@gmail.com>

Marco reported an error with hfsc:
root@Calimero:~# tc qdisc add dev eth0 root handle 1:0 hfsc default 1
Error: Attribute failed policy validation.

Apparently a few implementations pass TCA_OPTIONS as a binary instead
of nested attribute, so drop TCA_OPTIONS from the policy.

Fixes: 8b4c3cdd9dd8 ("net: sched: Add policy validation for tc attributes")
Reported-by: Marco Berizzi <pupilla@libero.it>
Signed-off-by: David Ahern <dsahern@gmail.com>
---
 net/sched/sch_api.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/net/sched/sch_api.c b/net/sched/sch_api.c
index 3dc0acf54245..be7cd140b2a3 100644
--- a/net/sched/sch_api.c
+++ b/net/sched/sch_api.c
@@ -1309,7 +1309,6 @@ check_loop_fn(struct Qdisc *q, unsigned long cl, struct qdisc_walker *w)
 
 const struct nla_policy rtm_tca_policy[TCA_MAX + 1] = {
 	[TCA_KIND]		= { .type = NLA_STRING },
-	[TCA_OPTIONS]		= { .type = NLA_NESTED },
 	[TCA_RATE]		= { .type = NLA_BINARY,
 				    .len = sizeof(struct tc_estimator) },
 	[TCA_STAB]		= { .type = NLA_NESTED },
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2018-10-31 21:40 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-24 15:32 [PATCH net] net: sched: Remove TCA_OPTIONS from policy David Ahern
2018-10-24 21:35 ` David Miller
2018-10-25  6:31 ` Jiri Pirko
2018-10-26 16:02   ` David Ahern
2018-10-26 16:08     ` Jiri Pirko
2018-10-26 11:34 ` Marco Berizzi
2018-10-26 15:48   ` David Ahern
2018-10-26 18:19   ` Cong Wang
2018-10-31 12:42     ` Marco Berizzi

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.