mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-01-24 18:21:36 -05:00
net/sched: sch_hfsc: warn about class in use while deleting
Add extack to warn that delete was rejected because the class is still in use Acked-by: Jamal Hadi Salim <jhs@mojatatu.com> Signed-off-by: Pedro Tammela <pctammela@mojatatu.com> Reviewed-by: Simon Horman <horms@kernel.org> Signed-off-by: Paolo Abeni <pabeni@redhat.com>
This commit is contained in:
committed by
Paolo Abeni
parent
daf8d9181b
commit
8e4553ef3e
@@ -1094,8 +1094,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);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user