各位专家:
中断的配置与触发我理解可分为以下三大部分(以keystone I C6678的可屏蔽中断为例):
部分1:完成 芯片内部外部事件 与 内核中断 的映射;
部分2:中断的各级使能(GIE,NMIE,IER)的配置;
部分3:中断处理函数ISR需填入中断向量表;
对于寄存器IFR的置位,清除与丢失的处理有以下几个问题请教:
1 在非软件人工置位的情况下(ISR寄存器),IFR寄存器如果产生置位,我理解肯定首先需要完成上述部分1的工作,问题在于上述部分2的工作对IFR的硬件置位有什么影响,即不开启中断使能的情况下,IFR是否会被硬件自动置位?
2 IFR寄存器的清除有两种情况:“If it is not the highest priority pending interrupt, IFm remains set until either you clear it by writing a 1 to bit m of ICR, or the processing of INTm occurs.” 即对应中断触发后硬件自动清除,或者软件人工清除。这里的描述是否涵盖了所有情况? 参考描述来源《C66x CPU and Instruction Set Reference Guide》
3 中断丢失的处理,即中断信号到达时,对应IFR仍然处于置位状态(即上一个中断事件还未被处理),这是中断丢失,对应描述“Each INTm input has a corresponding output that indicates if a low-to-high transition occurred on the input while the pending flag for that input had not yet been cleared. These outputs may be used by the interrupt controller to create an exception back to the CPU to notify the user of the missed interrupt. See the device-specific data manual to verify the device supports this feature.” 参考描述来源《C66x CPU and Instruction Set Reference Guide》。是否还有其他检测中断丢失的手段?
4 keystone I C6678对中断嵌套默认是关闭的,在软件设计过程中,如需要使用中断嵌套是否有对应的例程参考?