函数逻辑报告 |
Source Code:mm\mempolicy.c |
Create Date:2022-07-27 17:03:24 |
Last Modify:2020-03-17 22:28:11 | Copyright©Brick |
首页 | 函数Tree |
注解内核,赢得工具 | 下载SCCT | English |
函数名称:This function just creates a new policy, does some check and simple* initialization. You must invoke mpol_set_nodemask() to set nodes.
函数原型:static struct mempolicy *mpol_new(unsigned short mode, unsigned short flags, nodemask_t *nodes)
返回类型:struct mempolicy
参数:
类型 | 参数 | 名称 |
---|---|---|
unsigned short | mode | |
unsigned short | flags | |
nodemask_t * | nodes |
247 | pr_debug("setting mode %d flags %d nodes[0] %lx\n", mode, flags, nodes ? nodes_addr( * nodes)[0] : NUMA_NO_NODE) |
250 | 如果mode恒等于MPOL_DEFAULT则 |
251 | 如果nodes且非nodes_empty( * nodes)则返回:错误号 |
253 | 返回:NULL |
262 | 如果mode恒等于MPOL_PREFERRED则 |
263 | 如果nodes_empty( * nodes)则 |
264 | 如果flags按位与Flags for set_mempolicy 或flags按位与MPOL_F_RELATIVE_NODES则返回:错误号 |
268 | 否则如果mode恒等于MPOL_LOCAL则 |
269 | 如果非nodes_empty( * nodes)或flags按位与Flags for set_mempolicy 或flags按位与MPOL_F_RELATIVE_NODES则返回:错误号 |
273 | mode等于MPOL_PREFERRED |
274 | 否则如果nodes_empty( * nodes)则返回:错误号 |
279 | atomic_set( & refcnt, 1) |
280 | See MPOL_* above 等于mode |
283 | 返回:policy |
名称 | 描述 |
---|---|
do_set_mempolicy | Set the process memory policy |
do_mbind | |
mpol_shared_policy_init | mpol_shared_policy_init - initialize shared policy for inode*@sp: pointer to inode shared policy*@mpol: struct mempolicy to install* Install non-NULL @mpol in inode's shared policy rb-tree.* On entry, the current task has a reference on a non-NULL @mpol. |
源代码转换工具 开放的插件接口 | X |
---|---|
支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |