函数逻辑报告 |
Source Code:kernel\fork.c |
Create Date:2022-07-27 09:57:29 |
| Last Modify:2020-03-17 11:04:53 | Copyright©Brick |
| 首页 | 函数Tree |
| 注解内核,赢得工具 | 下载SCCT | English |
函数名称:设置内核内存分配器
函数原型:static struct mm_struct *mm_init(struct mm_struct *mm, struct task_struct *p, struct user_namespace *user_ns)
返回类型:struct mm_struct
参数:
| 类型 | 参数 | 名称 |
|---|---|---|
| struct mm_struct * | mm | |
| struct task_struct * | p | |
| struct user_namespace * | user_ns |
| 1009 | list of VMAs = NULL |
| 1010 | mm_rb = |
| 1011 | per-thread vmacache 等于0 |
| 1013 | atomic_set( & *@mm_count: The number of references to &struct mm_struct * (@mm_users count as 1). * Use mmgrab()/mmdrop() to modify. When this drops to 0, the * &struct mm_struct is freed., 1) |
| 1014 | init_rwsem( & mmap_sem) |
| 1015 | 初始化链表头 |
| 1016 | coredumping support = NULL |
| 1017 | mm_pgtables_bytes_init(mm) |
| 1018 | number of VMAs 等于0 |
| 1019 | Pages that have PG_mlocked set 等于0 |
| 1020 | atomic64_set( & Refcount permanently increased , 0) |
| 1023 | spin_lock_init( & protect the below fields ) |
| 1025 | mm_init_aio(mm) |
| 1026 | mm_init_owner(mm, p) |
| 1028 | mmu_notifier_mm_init(mm) |
| 1029 | init_tlb_flush_pending(mm) |
| 1031 | protected by page_table_lock = NULL |
| 1033 | mm_init_uprobes_state(mm) |
| 1035 | 如果mm则 |
| 1038 | 否则 |
| 1040 | def_flags等于0 |
| 1043 | 如果mm_alloc_pgd(mm)则转到:fail_nopgd |
| 1046 | 如果Init a new mm. Used on mm copies, like at fork()* and on mm's that are brand-new, like at execve().则转到:fail_nocontext |
| 1049 | user_ns等于get_user_ns(user_ns) |
| 1050 | 返回:mm |
| 1052 | fail_nocontext : |
| 1053 | mm_free_pgd(mm) |
| 1054 | fail_nopgd : |
| 1056 | 返回:NULL |
| 名称 | 描述 |
|---|---|
| mm_alloc | Allocate and initialize an mm_struct. |
| dup_mm | dup_mm() - duplicates an existing mm structure*@tsk: the task_struct with which the new mm will be associated.*@oldmm: the mm to duplicate.* Allocates a new mm structure and duplicates the provided @oldmm structure* content into it. |
| 源代码转换工具 开放的插件接口 | X |
|---|---|
| 支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |