xv6
a simple, Unix-like teaching operating system
一个简易、类Unix教学操作系统
Russ
Cox
Frans
Kaashoek
Robert
Morris
[email protected]
Draft
as of September 3, 2014
Contents
目录
0 Operating system interfaces 7
1 Operating system organization 17
1 操作系统组织
2 Page tables 29
2 页表
3 Traps, interrupts, and drivers 37
3 陷入、中断和驱动
4 Locking 49
4 锁
5 Scheduling 57
5 调度
6 File system 71
6 文件系统
7 Summary 87
7 总结
A PC hardware 89
A PC硬件
B The boot loader 93
B 引导加载程序
Index 99
索引
Foreword and acknowledgements
前言和致谢
This
is a draft text intended for a class on operating systems. It explains the main
concepts of operating systems by studying an example kernel, named xv6. xv6 is
a re-implementation of Dennis Ritchie’s and Ken Thompson’s Unix Version 6 (v6).
xv6 loosely follows the structure and style of v6, but is implemented in ANSI C
for an x86-based multiprocessor.
这是一份用于操作系统课程的草案。通过研究名为xv6的实例内核来阐明操作系统的主要概念。xv6是在Dennis Ritchie和Ken Thompson的Unix Version6(v6)基础之上重新实现的。xv6大致遵循了v6的结构和风格,但它是基于x86多核架构的ANSI C实现。
The
text should be read along with the source code for xv6. This approach is
inspired
by
John Lions’s Commentary on UNIX 6th Edition (Peer to Peer Communications; ISBN:
1-57398-013-7; 1st edition (June 14, 2000)). See http://pdos.csail.mit.edu/6.828
for pointers to on-line resources for v6 and xv6.
这本教材需要与xv6源码配套阅读。这是John Lions’s在UNIX 6th Edition (Peer to Peer Communications; ISBN:
1-57398-013-7; 1st edition (June 14, 2000))的评注中推荐的方式。v6和xv6的在线资源可参见http://pdos.csail.mit.edu/6.828。
We
have used this text in 6.828, the operating system class at MIT. We thank the
faculty, TAs, and students of 6.828 who all directly or indirectly contributed
to xv6. In particular,
we would like to thank Austin Clements and Nickolai Zeldovich.
我们已经在MIT操作系统课程6.828中使用了本教材。感谢6.828课程中所有教职员工、助教和学生们,他们都直接或间接的为xv6做出了贡献。此处我们还要向Austin Clements和Nickolai Zeldovich致以特别的感谢。