函数逻辑报告 |
Source Code:mm\slab.c |
Create Date:2022-07-27 17:19:27 |
Last Modify:2022-05-23 17:02:55 | Copyright©Brick |
首页 | 函数Tree |
注解内核,赢得工具 | 下载SCCT | English |
函数名称:slab_alloc
函数原型:static __always_inline void *slab_alloc(struct kmem_cache *cachep, gfp_t flags, unsigned long caller)
返回类型:void
参数:
类型 | 参数 | 名称 |
---|---|---|
struct kmem_cache * | cachep | |
gfp_t | flags | |
unsigned long | caller |
3353 | flags与等于gfp_allowed_mask |
3354 | cachep等于slab_pre_alloc_hook(cachep, flags) |
3355 | 如果此条件成立可能性小(为编译器优化)(!cachep)则返回:NULL |
3359 | local_irq_save(save_flags) |
3360 | objp等于__do_cache_alloc(cachep, flags) |
3361 | local_irq_restore(save_flags) |
3365 | 如果此条件成立可能性小(为编译器优化)(slab_want_init_on_alloc(flags, cachep))且objp则memset(objp, 0, The size of an object without metadata ) |
3368 | slab_post_alloc_hook(cachep, flags, 1, & objp) |
3369 | 返回:objp |
名称 | 描述 |
---|---|
kmem_cache_alloc | 分配高速缓存区 |
__do_kmalloc | __do_kmalloc - allocate memory*@size: how many bytes of memory are required.*@flags: the type of memory to allocate (see kmalloc).*@caller: function caller for debug tracking of the caller* Return: pointer to the allocated memory or %NULL in case of error |
源代码转换工具 开放的插件接口 | X |
---|---|
支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |