8989 . align 4
9090start_dispatch:
9191/ *
92- * this routine is called in the non - task conext during the startup of the kernel
92+ * this routine is called in the non - task context during the startup of the kernel
9393 * , and all the interrupts are locked.
9494 *
95- * when the dispatcher is called , the cpu is locked , no nest exception ( CPU exception/interrupt).
9695 * In target_initialize , all interrupt priority mask should be cleared , cpu should be
9796 * locked , the interrupts outside the kernel such as fiq can be
9897 * enabled.
@@ -112,7 +111,7 @@ dispatcher:
112111/ *
113112 * before dispatcher is called , task context | cpu locked | dispatch enabled
114113 * should be satisfied. In this routine , the processor will jump
115- * into the entry of next to run task
114+ * into the entry of next to run task through exception return
116115 *
117116 * i.e. kernel mode , IRQ disabled , dispatch enabled
118117 * /
@@ -141,7 +140,7 @@ exc_entry_cpu:
141140 st r1 , [ exc_nest_count ]
142141 cmp r0 , 0
143142 bne exc_handler_1
144- / * chang to interrupt stack if interrupt happened in task context * /
143+ / * change to exception stack if interrupt happened in task context * /
145144 mov sp , _e_stack
146145exc_handler_1:
147146 PUSH blink
@@ -188,19 +187,7 @@ ret_exc_r_1:
188187exc_entry_int:
189188 clri / * disable interrupt * /
190189
191- #if ARC_FEATURE_FIRQ == 1
192- #if ARC_FEATURE_RGF_NUM_BANKS > 1
193- lr r0 , [ AUX_IRQ_ACT ] / * check whether it is P0 interrupt * /
194- btst r0 , 0
195- jnz exc_entry_firq
196- #else
197- PUSH r10
198- lr r10 , [ AUX_IRQ_ACT ]
199- btst r10 , 0
200- POP r10
201- jnz exc_entry_firq
202- #endif
203- #endif
190+ / * FIRQ and banking is not supported now in secureshield * /
204191 INTERRUPT_PROLOGUE
205192
206193 mov blink , sp
@@ -210,7 +197,7 @@ exc_entry_int:
210197 st r2 , [ exc_nest_count ]
211198 cmp r3 , 0
212199 bne irq_handler_1
213- / * chang to interrupt stack if interrupt happened in task context * /
200+ / * change to exception stack if interrupt happened in task context * /
214201 mov sp , _e_stack
215202irq_handler_1:
216203 PUSH blink
@@ -242,7 +229,7 @@ ret_int:
242229 ld r0 , [ context_switch_reqflg ]
243230 cmp r0 , 0
244231 beq ret_int_r_1
245- / * clear dispatch requst * /
232+ / * clear dispatch request * /
246233 mov r0 , 0
247234 st r0 , [ context_switch_reqflg ]
248235
@@ -263,6 +250,12 @@ ret_int:
263250 st r0 , [ ulCriticalNesting ]
264251 RESTORE_CALLEE_REGS
265252ret_int_r_1:
253+ / * differences between INTERRUPT_EPILOGUE and EXCEPTION_EPILOGUE:
254+ * INTERRUPT_EPIOLOGUE is a subset of EXCEPTION_EPIOLOGUE.
255+ * In EXCEPTION_EPILOGUE , all regs are popped through SW.
256+ * IN INTERRUPT_EPILOGUE , some regs are popped through SW , the left
257+ * part is popped by HW (interrupt return).
258+ * /
266259 INTERRUPT_EPILOGUE
267260 rtie
268261/ ** @endcond * /
0 commit comments