我想知道PREEMPT_NONE和PREEMPT_VOLUNTARY之间的区别是什么。根据文件,Linux内核抢占级别
This option reduces the latency of the kernel by adding more
"explicit preemption points" to the kernel code
但它没有提到这些点是什么。我尝试使用Google搜索,但没有发现比上述文字更多的细节(这似乎令人惊讶,因为我认为这将是一个常见问题)。我主要关心的是进程挨饿其他进程,所以我想知道是否抢占发生在定时器中断与自愿。当然,越多的信息越好,所以我想知道其他的优先点可能是什么。
请参阅http://stackoverflow.com/questions/5174955/what-is-voluntary-preemption –
并参阅http://stackoverflow.com/questions/20769768/why-disabling-interrupts-disables-kernel-preemption -and-how-spin-lock-disables-p?rq = 1 –
谢谢 - 我遇到了第一篇文章,但它仍然有一个模糊的引语:“在做内核事情时”。它提到IO作为一个例子,但不幸的是并没有继续提到其他的东西。 – blackghost