Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:mm\slab.c Create Date:2022-07-28 15:44:16
Last Modify:2022-05-23 17:02:55 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:setup_cpu_cache

Proto:static int __ref setup_cpu_cache(struct kmem_cache *cachep, gfp_t gfp)

Type:int

Parameter:

TypeParameterName
struct kmem_cache *cachep
gfp_tgfp
1793  If (slab_state >= FULL) Then Return enable_cpucache(cachep, gfp)
1796  cpu_cache = alloc_kmem_cache_cpus(cachep, 1, 1)
1797  If Not cpu_cache Then Return 1
1800  If (slab_state == No slab functionality yet ) Then
1802  For setting up all the kmem_cache_node for cache whose buffer_size is same as* size of kmem_cache_node.
1803  Else if (slab_state == SLUB: kmem_cache_node available ) Then
1805  For setting up all the kmem_cache_node for cache whose buffer_size is same as* size of kmem_cache_node.
1806  Else
1812  BUG_ON(!node[node])
1817  next_reap = jiffies + REAPTIMEOUT_NODE + cachep % REAPTIMEOUT_NODE
1821  avail = 0
1822  limit = BOOT_CPUCACHE_ENTRIES
1823  batchcount = 1
1824  touched = 0
1825  batchcount = 1
1826  limit = BOOT_CPUCACHE_ENTRIES
1827  Return 0
Caller
NameDescribe
__kmem_cache_create__kmem_cache_create - Create a cache.*@cachep: cache management descriptor*@flags: SLAB flags* Returns a ptr to the cache on success, NULL on failure.* Cannot be called within a int, but can be interrupted.