Message ID | 20230721191332.1424997-4-pctammela@mojatatu.com (mailing list archive) |
---|---|
State | Superseded |
Delegated to: | Netdev Maintainers |
Headers | show |
Series | net/sched: improve class lifetime handling | expand |
diff --git a/net/sched/sch_hfsc.c b/net/sched/sch_hfsc.c index 122fe775c7ab..4800191f7c49 100644 --- a/net/sched/sch_hfsc.c +++ b/net/sched/sch_hfsc.c @@ -1095,8 +1095,10 @@ hfsc_delete_class(struct Qdisc *sch, unsigned long arg, struct hfsc_class *cl = (struct hfsc_class *)arg; if (cl->level > 0 || qdisc_class_in_use(&cl->cl_common) || - cl == &q->root) + cl == &q->root) { + NL_SET_ERR_MSG(extack, "HFSC class in use"); return -EBUSY; + } sch_tree_lock(sch);
Add extack to warn that delete was rejected because the class is still in use Signed-off-by: Pedro Tammela <pctammela@mojatatu.com> --- net/sched/sch_hfsc.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)