函数逻辑报告 |
Source Code:kernel\resource.c |
Create Date:2022-07-27 10:05:17 |
Last Modify:2022-05-22 11:14:39 | Copyright©Brick |
首页 | 函数Tree |
注解内核,赢得工具 | 下载SCCT | English |
函数名称:__request_region - create a new busy resource region*@parent: parent resource descriptor*@start: resource start address*@n: resource region size*@name: reserving caller's ID string*@flags: IO resource flags
函数原型:struct resource *__request_region(struct resource *parent, resource_size_t start, resource_size_t n, const char *name, int flags)
返回类型:struct resource
参数:
类型 | 参数 | 名称 |
---|---|---|
struct resource * | parent | |
resource_size_t | start | |
resource_size_t | n | |
const char * | name | |
int | flags |
1127 | DECLARE_WAITQUEUE(wait, 当前进程) |
1128 | res等于alloc_resource(GFP_KERNEL) |
1130 | 如果非res则返回:NULL |
1137 | write_lock( & resource_lock) |
1139 | 循环 |
1142 | flags等于resource_type(parent)按位或resource_ext_type(parent) |
1143 | flags或等于Driver has marked this resource busy 按位或flags |
1154 | 如果desc恒等于IORES_DESC_DEVICE_PRIVATE_MEMORY则 |
1159 | 如果非flags按位与Driver has marked this resource busy 的值则 |
1164 | 如果flags按位与flags按位与Resource is software muxed 则 |
1166 | write_unlock( & resource_lock) |
1167 | set_current_state(深度睡眠态) |
1168 | schedule() |
1170 | write_lock( & resource_lock) |
1171 | 继续下一循环 |
1174 | free_resource(res) |
1175 | res = NULL |
1176 | 退出 |
1178 | write_unlock( & resource_lock) |
1179 | 返回:res |
名称 | 描述 |
---|---|
__devm_request_region | |
register_memory_resource | add this memory to iomem resource |
源代码转换工具 开放的插件接口 | X |
---|---|
支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |