[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aAgO59L0ccXl6kUs@pop-os.localdomain>
Date: Tue, 22 Apr 2025 14:49:27 -0700
From: Cong Wang <xiyou.wangcong@...il.com>
To: "Alan J. Wylie" <alan@...ie.me.uk>
Cc: Holger Hoffstätte <holger@...lied-asynchrony.com>,
Jamal Hadi Salim <jhs@...atatu.com>, regressions@...ts.linux.dev,
Jiri Pirko <jiri@...nulli.us>, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org, Octavian Purdila <tavip@...gle.com>,
Toke Høiland-Jørgensen <toke@...hat.com>,
stable@...r.kernel.org, Greg KH <gregkh@...uxfoundation.org>
Subject: Re: [REGRESSION] 6.14.3 panic - kernel NULL pointer dereference in
htb_dequeue
Hi, Alan
Although I am still trying to understand the NULL pointer, which seems
likely from:
478 if (p->inner.clprio[prio].ptr == cl->node + prio) {
479 /* we are removing child which is pointed to from
480 * parent feed - forget the pointer but remember
481 * classid
482 */
483 p->inner.clprio[prio].last_ptr_id = cl->common.classid;
484 p->inner.clprio[prio].ptr = NULL;
485 }
Does the following patch work? I mean not just fixing the crash, but
also not causing any other problem.
Please give it a try.
Thanks!
---
diff --git a/net/sched/sch_htb.c b/net/sched/sch_htb.c
index 4b9a639b642e..0cdc778fddef 100644
--- a/net/sched/sch_htb.c
+++ b/net/sched/sch_htb.c
@@ -348,7 +348,8 @@ static void htb_add_to_wait_tree(struct htb_sched *q,
*/
static inline void htb_next_rb_node(struct rb_node **n)
{
- *n = rb_next(*n);
+ if (*n)
+ *n = rb_next(*n);
}
/**
Powered by blists - more mailing lists