当前位置:  技术问答>linux和unix

Nested Interrupt Handling

    来源: 互联网  发布时间:2015-12-04

    本文导语:  在Understanding the Linux Kernel的4.3节上有这么一段话。 The price to pay for allowing nested kernel control paths is that an interrupt handler must never block, that is, no process switch can take place until an interrupt handler is running...

在Understanding the Linux Kernel的4.3节上有这么一段话。
The price to pay for allowing nested kernel control paths is that an interrupt handler must never block, that is, no process switch can take place until an interrupt handler is running. In fact, all the data needed to resume a nested kernel control path is stored in the Kernel Mode stack, which is tightly bound to the current process.

意思是说:

中断处理是可以嵌套进行的,但是代价是interrupt handler不能被block——也就是不能在其中发生进程切换。

这里我有几个疑问:
1. Preemptive multi-task不就是在timer interrupt handler中进行
   进程切换吗?
2. Linux的interrupt handler是通过interrupt gate调用的,而Intel
   CPU触发interrupt gate的时候会自动清除IF。如果是这样,又如
   何会产程嵌套的中断处理呢?
3. 这里的interrupt handler,我猜是指狭义的interrupt——就是不
   包括exception。是吗?


|
不是很了解linux调度,不过很多RTOS的Preemptive multi-task都不是在timer interrupt handler中进行进程切换,而是在timer interrupt handler结束(返回)的时候切换,这样可以避免nest interrupt导致多次调度。

    
 
 

您可能感兴趣的文章:

 
本站(WWW.)旨在分享和传播互联网科技相关的资讯和技术,将尽最大努力为读者提供更好的信息聚合和浏览方式。
本站(WWW.)站内文章除注明原创外,均为转载、整理或搜集自网络。欢迎任何形式的转载,转载请注明出处。












  • 相关文章推荐
  • java命名空间javax.xml.stream类xmlstreamexception成员方法: nested定义参考
  • qt设置中文出现'QTextCodec' used in nested name specifier


  • 站内导航:


    特别声明:169IT网站部分信息来自互联网,如果侵犯您的权利,请及时告知,本站将立即删除!

    ©2012-2021,,E-mail:www_#163.com(请将#改为@)

    浙ICP备11055608号-3