- 2
- 0
- 约2.72万字
- 约 81页
- 2019-03-26 发布于天津
- 举报
演算法在Linux作業系統上之應用 Algorithm Applications in Linux Operating System CE6100 許 富 皓 Chapter 3 Processes Parameters of do_fork() clone_flags Same as the flags parameter of clone( ) stack_start Same as the child_stack parameter of clone( ) regs Pointer to the values of the general purpose registers saved into the Kernel Mode stack when switching from User Mode to Kernel Mode (see the section The do_IRQ( ) function in Chapter 4) stack_size Unused (always set to 0) parent_tidptr, child_tidptr Same as the corresponding ptid and ctid parameters of clone() copy_process( ) do_fork( ) makes use of an auxiliary function called copy_process( ) to set up the process descriptor and any other kernel data structure required for childs execution. do_fork()- a new PID Allocates a new PID for the child by looking in the pidmap_array bitmap (see the earlier section Identifying a Process). The Meaning of Some Clone Flags CLONE_PTRACE If traced, the parent wants the child to be traced too. Furthermore, the debugger may want to trace the child on its own; in this case, the kernel forces the flag to 1. CLONE_STOPPED Forces the child to start in the TASK_STOPPED state. CLONE_UNTRACED Set by the kernel to override the value of the CLONE_PTRACE flag (used for disabling tracing of kernel threads ; see the section Kernel Threads later in this chapter). CLONE_VM Shares the memory descriptor and all Page Tables (see Chapter 9). do_fork()- the ptrace Field Checks the ptrace field of the parent (current-ptrace): if it is not zero, the parent process is being traced by another process, thus do_fork( ) checks whether the debugger wants to trace the child on its own (independently of the value of the CLONE_PTRACE flag specified by the parent); in this case, if the child is not a kernel thread (CLONE_UNTRACED flag cleared), the function sets the CLONE_PTRACE flag. do_fork()- copy_process() Invokes copy_process() to make a copy of the process descriptor. If all needed resources are availab
您可能关注的文档
- 湖南中小微企业信心指数模型..pdf
- 湖南大康牧业股份有限公司拟收购汇一食品.pdf
- 湖南建设工程材料场价格编者声明:.pdf
- 湖南股权交易所有限公司交易规则.pdf
- 湛江金鹿实业发展有限公司梅花鹿引进项目采购.DOC
- 滑人民医院新生儿专用监护仪、空氧混合器、T--组合复苏器....DOC
- 滕州第五中学微机室采购项目.pdf
- 滙丰控股000HK业界翘楚增长稳定.pdf
- 漳江口湿地变化的遥感监测.pdf
- 潍坊富华大酒店迎星评复核整修改造工程.pdf
- (正式版)DB51∕T 1867-2014 《袋栽黑木耳生产技术规程》.docx
- (正式版)DB51∕T 2413-2023 《油橄榄密植丰产栽培技术规程》.docx
- (正式版)DB51∕T 2436-2017 《川菜东坡一品肉烹饪工艺技术规范》.docx
- (正式版)DB51∕T 2396-2017 《农村电子商务服务站(点)服务与管理规范》.docx
- (正式版)DB51∕T 2419-2017 《桢楠扦插育苗技术规程》.docx
- CN105145773B 一种无花果曲奇饼干及其制作方法 (江苏农林职业技术学院).docx
- CN105203825A 微测量电极的制作方法和热电势的测量方法及相关装置 (国家纳米科学中心).docx
- CN105137533B 一种啁啾光纤光栅及其制作方法 (南京航空航天大学).docx
- (正式版)DB51∕T 2453-2018 《巴山新居公共管理指南》.docx
- (正式版)DB51∕T 1892-2014 《川西北地区沙化土地治理技术规程》.docx
原创力文档

文档评论(0)