slub: Don't read nr_slabs and total_objects directly
authorXiongwei Song <xiongwei.song@windriver.com>
Thu, 13 Apr 2023 14:34:52 +0000 (22:34 +0800)
committerVlastimil Babka <vbabka@suse.cz>
Mon, 22 May 2023 13:20:21 +0000 (15:20 +0200)
commit8040cbf5e1da2fe86558239b92927a947c79ecd6
tree117c0a6a9463eff9b69ecb38379603c992f20e6c
parent4f174a8bacebf57ffa18be0439b9ed7ee6d00c70
slub: Don't read nr_slabs and total_objects directly

We have node_nr_slabs() to read nr_slabs, node_nr_objs() to read
total_objects in a kmem_cache_node, so no need to access the two
members directly.

Signed-off-by: Xiongwei Song <xiongwei.song@windriver.com>
Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
mm/slub.c