Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
SLUB: Fix for offset change of struct slab members on Linux 6.2-rc1
The following kernel commits split slab info from struct page into struct slab in Linux 5.17. d122019bf061 ("mm: Split slab into its own type") 07f910f9b729 ("mm: Remove slab from struct page") Crash commit 5f390ed followed the change for SLUB, but crash still uses the offset of page.lru inappropriately. Luckily, it could work because it was the same value as the offset of slab.slab_list until Linux 6.1. However, kernel commit 130d4df57390 ("mm/sl[au]b: rearrange struct slab fields to allow larger rcu_head") in Linux 6.2-rc1 changed the offset of slab.slab_list. As a result, without the patch, "kmem -s|-S" options print the following errors and fail to print values correctly for kernels configured with CONFIG_SLUB. crash> kmem -S filp CACHE OBJSIZE ALLOCATED TOTAL SLABS SSIZE NAME kmem: filp: partial list slab: ffffcc650405ab88 invalid page.inuse: -1 ffff8fa0401eca00 232 1267 1792 56 8k filp ... KMEM_CACHE_NODE NODE SLABS PARTIAL PER-CPU ffff8fa0401cb8c0 0 56 24 8 NODE 0 PARTIAL: SLAB MEMORY NODE TOTAL ALLOCATED FREE kmem: filp: invalid partial list slab pointer: ffffcc650405ab88 Signed-off-by: Kazuhito Hagio <k-hagio-ab@nec.com>
- Loading branch information
Showing
3 changed files
with
12 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters