Function report |
Source Code:mm\slab_common.c |
Create Date:2022-07-28 14:29:22 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
home page | Tree |
Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:create_cache
Proto:static struct kmem_cache *create_cache(const char *name, unsigned int object_size, unsigned int align, slab_flags_t flags, unsigned int useroffset, unsigned int usersize, void (*ctor)(void *), struct mem_cgroup *memcg, struct kmem_cache *root_cache)
Type:struct kmem_cache
Parameter:
Type | Parameter | Name |
---|---|---|
const char * | name | |
unsigned int | object_size | |
unsigned int | align | |
slab_flags_t | flags | |
unsigned int | useroffset | |
unsigned int | usersize | |
void (* | ctor | |
struct mem_cgroup * | memcg | |
struct kmem_cache * | root_cache |
388 | If WARN_ON(useroffset + usersize > object_size) Then useroffset = usersize = 0 |
396 | Name (only for display!) = name |
401 | Usercopy region size = usersize |
403 | err = init_memcg_params(s, root_cache) |
404 | If err Then Go to out_free_cache |
408 | If err Then Go to out_free_cache |
411 | Refcount for slab cache destroy = 1 |
413 | memcg_link_cache(s, memcg) |
414 | out : |
417 | Return s |
419 | out_free_cache : |
420 | destroy_memcg_params(s) |
421 | kmem_cache_free(kmem_cache, s) |
422 | Go to out |
Name | Describe |
---|---|
kmem_cache_create_usercopy | kmem_cache_create_usercopy - Create a cache with a region suitable* for copying to userspace*@name: A string which is used in /proc/slabinfo to identify this cache.*@size: The size of objects to be created in this cache. |
Source code conversion tool public plug-in interface | X |
---|---|
Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |