From: Xuewen Wang Date: Mon, 18 May 2026 06:21:57 +0000 (+0800) Subject: tools/mm/slabinfo: Fix trace disable logic inversion X-Git-Url: http://git.ipfire.org/gitweb/?a=commitdiff_plain;h=235ab68d67eadbef1fdbfb771f21f5bacc77a2ae;p=thirdparty%2Fkernel%2Flinux.git tools/mm/slabinfo: Fix trace disable logic inversion The disable trace path in slab_debug() had a logic error where it would set trace=1 instead of trace=0. This made trace functionality permanently enabled once turned on for any slab cache. Fixes: a87615b8f9e2 ("SLUB: slabinfo upgrade") Cc: stable@vger.kernel.org Reviewed-by: SeongJae Park Signed-off-by: Xuewen Wang WARNING: From:/Signed-off-by: email address mismatch: 'From: wangxuewen <18810879172@163.com>' != 'Signed-off-by: wangxuewen ' Link: https://patch.msgid.link/20260518062159.80664-2-wangxuewen@kylinos.cn Signed-off-by: Vlastimil Babka (SUSE) --- diff --git a/tools/mm/slabinfo.c b/tools/mm/slabinfo.c index 54c7265ab52d9..39f7eae7eecda 100644 --- a/tools/mm/slabinfo.c +++ b/tools/mm/slabinfo.c @@ -798,7 +798,7 @@ static void slab_debug(struct slabinfo *s) fprintf(stderr, "%s can only enable trace for one slab at a time\n", s->name); } if (!tracing && s->trace) - set_obj(s, "trace", 1); + set_obj(s, "trace", 0); } static void totals(void)