login 3d729e2069
bugfix: 修复进程pcb被回收时,未将其从链表中删除的问题 (#87)
* bugfix: 修复进程pcb被回收时,未将其从链表中删除的问题
new: pcb相关api文档

* 将文档加入目录
2022-11-18 17:59:33 +08:00

27 lines
524 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# PCB 进程控制块
PCB的全称为process control block, 它是每个进程/线程的核心控制结构。定义于`kernel/src/process/proc-types.h`中。
## PCB详解
Todo:
## 与PCB的管理相关的API
### 根据pid寻找pcb
**process_find_pcb_by_pid**
该API提供了根据pid寻找pcb的功能定义在`kernel/src/process/process.h`中。
当找到目标的pcb时返回对应的pcb否则返回NULL。
#### 参数
**pid**
进程id
#### 返回值
**struct process_control_block**
目标pcb