本系列是对 陈莉君 老师 Linux 内核分析与应用 的学习与记录。讲的非常之好,推荐观看
留此记录,蜻蜓点水,可作抛砖引玉

6.1 Linux中的各种API
LSB (Linux Standards Base)

POSIX: 可移植操作系统接口(Portable Operating System Interface of UNIX)
Linux ABI:
(为了兼容)

内核API:
主要是内核中标记为"EXPORT_SYMBOL"的函数
思考:
保持一个稳定的ABI和保持一个稳定的API相比,谁更困难,为什么?
6.2 系统调用机制
系统调用---内核的出口
各种工具:

如 strace ls,就可以看到ls命令所调用的系统调用


中断是异步的,异常是同步的,系统调用既可以是同步,也可以是异步

系统调用号存放在eax寄存器中, 其实现所在的源文件也不在一起.
参数存放在寄存器中,一般参数不超过6个


参考: