diff options
| author | Cong Wang <[email protected]> | 2025-03-06 23:23:54 +0000 |
|---|---|---|
| committer | Jakub Kicinski <[email protected]> | 2025-03-12 19:51:58 +0000 |
| commit | 0c3057a5a04d07120b3d0ec9c79568fceb9c921e (patch) | |
| tree | 182186645ee082560be958b0a097d35855fadde3 /drivers/net/ethernet/intel/ice/ice_lib.c | |
| parent | Merge tag 'wireless-2025-03-12' of https://git.kernel.org/pub/scm/linux/kerne... (diff) | |
| download | kernel-0c3057a5a04d07120b3d0ec9c79568fceb9c921e.tar.gz kernel-0c3057a5a04d07120b3d0ec9c79568fceb9c921e.zip | |
net_sched: Prevent creation of classes with TC_H_ROOT
The function qdisc_tree_reduce_backlog() uses TC_H_ROOT as a termination
condition when traversing up the qdisc tree to update parent backlog
counters. However, if a class is created with classid TC_H_ROOT, the
traversal terminates prematurely at this class instead of reaching the
actual root qdisc, causing parent statistics to be incorrectly maintained.
In case of DRR, this could lead to a crash as reported by Mingi Cho.
Prevent the creation of any Qdisc class with classid TC_H_ROOT
(0xFFFFFFFF) across all qdisc types, as suggested by Jamal.
Reported-by: Mingi Cho <[email protected]>
Signed-off-by: Cong Wang <[email protected]>
Reviewed-by: Simon Horman <[email protected]>
Fixes: 066a3b5b2346 ("[NET_SCHED] sch_api: fix qdisc_tree_decrease_qlen() loop")
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Jakub Kicinski <[email protected]>
Diffstat (limited to 'drivers/net/ethernet/intel/ice/ice_lib.c')
0 files changed, 0 insertions, 0 deletions
