函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\cgroup\cgroup.c Create Date:2022-07-27 12:09:08
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:IDR wrappers which synchronize using cgroup_idr_lock

函数原型:static int cgroup_idr_alloc(struct idr *idr, void *ptr, int start, int end, gfp_t gfp_mask)

返回类型:int

参数:

类型参数名称
struct idr *idr
void *ptr
intstart
intend
gfp_tgfp_mask
309  dr_preload - preload for idr_alloc()*@gfp_mask: allocation mask to use for preloading* Preallocate memory to use for the next call to idr_alloc(). This function* returns with preemption disabled. It will be enabled by idr_preload_end().
310  spin_lock_bh( & Protects cgroup_idr and css_idr so that IDs can be released without* grabbing cgroup_mutex.)
311  ret等于dr_alloc() - Allocate an ID.*@idr: IDR handle.*@ptr: Pointer to be associated with the new ID.*@start: The minimum ID (inclusive).*@end: The maximum ID (exclusive).*@gfp: Memory allocation flags.
312  spin_unlock_bh( & Protects cgroup_idr and css_idr so that IDs can be released without* grabbing cgroup_mutex.)
313  dr_preload_end - end preload section started with idr_preload()* Each idr_preload() should be matched with an invocation of this* function. See idr_preload() for details.
314  返回:ret
调用者
名称描述
css_create
cgroup_init_subsys
cgroup_initgroup_init - cgroup initialization* Register cgroup filesystem and /proc file, and initialize* any subsystems that didn't request early init.