From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C239739A802 for ; Tue, 28 Apr 2026 08:20:05 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1777364405; cv=none; b=K1z9k9BkvgIT8R9/TiAiBEqQf4muP+OYiS9cn8d89fgxJ4QGcpeOy5cUqRWeFxbT9hpPfpcdvs9A8l4/E3RJkuFsTp5P0Qt1I4Sqh1WxQ8qNmL0R4JGPBAZL+j2OazU8PK3urpowxFPfgAuYhxEyKR0/MaGMKVRojFWrUm9iMag= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1777364405; c=relaxed/simple; bh=AlX+PHctGVQmBEusAIxrcU6IvuyJGDGTPTn4tAS8RgE=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=flMnwrjoXiroAvlTPVk9CpqEc37gGzlxiObGX1Ftt8aZGTIAwkh0VeK7a/jMie9/sSegPMM9Y8iN1uvwlX4+U1eoJnjDLbjqya2JU9csaAdLxozhkSaIftXCBKV2FDJCcIy5+IlJ5VlRm323h1vJ2kVqEUih+sR+b+k8nMO8CJE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=ANf4bBV5; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="ANf4bBV5" Received: by smtp.kernel.org (Postfix) with ESMTPSA id A08E0C2BCAF; Tue, 28 Apr 2026 08:20:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1777364405; bh=AlX+PHctGVQmBEusAIxrcU6IvuyJGDGTPTn4tAS8RgE=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=ANf4bBV5hh1elppcHkKIe6tBZoWdw4S+OulwNHHfao1CbVESyHowPxZrCvlUL7bWA GAPeLyrZ5Tw92jdKVtel6p2q/E204StMuGRaYrqW1jDk8JgACI1eUdJddoqJT2fb5W OVky1sqGtru5Z7RaT9NpTbthjM8t2yeNAytc4WpokK57JbORUHaLue1SY68FCK8Gu3 gnjXJjw3Qk0OIRz26xBbkcVcOKLNHDvPvsW/QtFh+esVdaEL77wBs9ma5uQz2q/MNq Vehz+oAmPENOiLw5OSIBPMUz8TkeY6E9GtJXxtQBDFuWy8A6D3MYGTMFTP/CNRs3Nk gPc/ht4sH8VKg== Message-ID: <579d47c8-ac21-4ac1-bf58-15f5b88b4872@kernel.org> Date: Tue, 28 Apr 2026 10:20:01 +0200 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 2/2] scripts/gdb: slab: Update field names of struct kmem_cache Content-Language: en-US To: Illia Ostapyshyn , linux-kernel@vger.kernel.org Cc: Hao Li , Harry Yoo , Andrew Morton , Seongjun Hong , Kieran Bingham , Jan Kiszka , Florian Fainelli References: <20260427142448.666117-1-illia@yshyn.com> <20260427142448.666117-3-illia@yshyn.com> From: "Vlastimil Babka (SUSE)" In-Reply-To: <20260427142448.666117-3-illia@yshyn.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit On 4/27/26 16:24, Illia Ostapyshyn wrote: > The commit 5ba6bc27b1f9 ("slab: decouple pointer to barn from > kmem_cache_node") reorganized the struct kmem_cache to factor out the > per-node fields to the new struct kmem_cache_per_node_ptrs. This causes > the gdb scripts for lx-slabinfo and lx-slabtrace fail as they still > reference the old structure. > > Adjust the gdb scripts to match the current state of struct kmem_cache. > > Fixes: 5ba6bc27b1f9 ("slab: decouple pointer to barn from kmem_cache_node") > Signed-off-by: Illia Ostapyshyn Acked-by: Vlastimil Babka (SUSE) Thanks! > --- > scripts/gdb/linux/slab.py | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/scripts/gdb/linux/slab.py b/scripts/gdb/linux/slab.py > index 0e2d93867fe2..ddde25aeca8d 100644 > --- a/scripts/gdb/linux/slab.py > +++ b/scripts/gdb/linux/slab.py > @@ -196,7 +196,7 @@ def slabtrace(alloc, cache_name): > > if target_cache['flags'] & SLAB_STORE_USER: > for i in range(0, nr_node_ids): > - cache_node = target_cache['node'][i] > + cache_node = target_cache['per_node']['node'][i] > if cache_node['nr_slabs']['counter'] == 0: > continue > process_slab(loc_track, cache_node['partial'], alloc, target_cache) > @@ -300,7 +300,7 @@ def slabinfo(): > nr_free = 0 > nr_slabs = 0 > for i in range(0, nr_node_ids): > - cache_node = cache['node'][i] > + cache_node = cache['per_node']['node'][i] > try: > nr_slabs += cache_node['nr_slabs']['counter'] > nr_objs = int(cache_node['total_objects']['counter'])