[PATCH 0/6] refine and rename slub sysfs
From: Wei Yang
Date: Wed May 17 2017 - 10:12:41 EST
This patch serial could be divided into two parts.
First three patches refine and adds slab sysfs.
Second three patches rename slab sysfs.
1. Refine slab sysfs
There are four level slabs:
And in sysfs, it use show_slab_objects() and cpu_partial_slabs_show() to
reflect the statistics.
In patch 2, it splits some function in show_slab_objects() which makes sure
only cpu_partial_slabs_show() covers statistics for CPU_PARTIAL slabs.
After doing so, it would be more clear that show_slab_objects() has totally 9
statistic combinations for three level of slabs. Each slab has three cases
And when we look at current implementation, some of them are missing. So patch
2 & 3 add them up.
2. Rename sysfs
The slab statistics in sysfs are
which is a little bit hard for users to understand. The second three patches
rename sysfs file in this pattern.
Finally it looks Like
Wei Yang (6):
mm/slub: add total_objects_partial sysfs
mm/slub: not include cpu_partial data in cpu_slabs sysfs
mm/slub: add cpu_slabs_[total_]objects sysfs
mm/slub: rename ALL slabs sysfs
mm/slub: rename partial_slabs sysfs
mm/slub: rename cpu_partial_slab sysfs
mm/slub.c | 64 +++++++++++++++++++++++++++++++++++----------------------------
1 file changed, 36 insertions(+), 28 deletions(-)