2002-08-14 Brett Swimley <brett.swimley@aedinc.net>

* cpu_asm.S: Per PR267, the _ISR_Handler() function never was modifying
	_ISR_Nest_level, and _Watchdog_Insert() requires this variable
	to be modified to determine if an interrupt may have modified
	the watchdog chain.  Prior to modifying _ISR_Handler(), I had
	a test that would fail if _ISR_Flash was not commented out in
	_Watchdog_Insert().  After this modification was made, my test
	ran flawlessly.
This commit is contained in:
Joel Sherrill
2002-08-14 23:08:04 +00:00
parent 5e39823b3f
commit 8e0738e1e6
3 changed files with 30 additions and 2 deletions

View File

@@ -1,3 +1,13 @@
2002-08-14 Brett Swimley <brett.swimley@aedinc.net>
* cpu_asm.S: Per PR267, the _ISR_Handler() function never was modifying
_ISR_Nest_level, and _Watchdog_Insert() requires this variable
to be modified to determine if an interrupt may have modified
the watchdog chain. Prior to modifying _ISR_Handler(), I had
a test that would fail if _ISR_Flash was not commented out in
_Watchdog_Insert(). After this modification was made, my test
ran flawlessly.
2002-08-05 Joel Sherrill <joel@OARcorp.com>
* Per PR260 eliminate use of make-target-options. This impacted

View File

@@ -139,6 +139,8 @@ SYM (_ISR_Handler):
#if ( CPU_HAS_SOFTWARE_INTERRUPT_STACK == 1 )
tstl SYM (_ISR_Nest_level) | Interrupting an interrupt handler?
bne 2f | Yes, just skip over stack switch code
movel _CPU_Interrupt_stack_high,a0 | a0 now point just above interrupt stack
cmpl _CPU_Interrupt_stack_low,a7 | stack below interrupt stack?
bcs.b 1f | yes, switch to interrupt stack
@@ -151,6 +153,8 @@ SYM (_ISR_Handler):
2:
#endif /* CPU_HAS_SOFTWARE_INTERRUPT_STACK == 1 */
addql #1,SYM(_ISR_Nest_level) | one nest level deeper
movel SYM (_ISR_Vector_table),a0 | a0= base of RTEMS table
#if ( M68K_HAS_PREINDEXING == 1 )
movel (a0,d0:w:1),a0 | a0 = address of user routine
@@ -165,14 +169,17 @@ SYM (_ISR_Handler):
addql #4,a7 | remove vector number
#if ( CPU_HAS_SOFTWARE_INTERRUPT_STACK == 1 )
subql #1,SYM(_ISR_Nest_level) | Reduce interrupt-nesting count
bne 1f | Skip if return to interrupt
movel _CPU_Interrupt_stack_high,a0
subql #4,a0
cmpl a0,a7 | At top of interrupt stack?
bne.b 1f | No, do not restore task stack pointer
movel (a7),a7 | Restore task stack pointer
1:
#else
subql #1,SYM (_ISR_Nest_level) | one less nest level
#endif /* CPU_HAS_SOFTWARE_INTERRUPT_STACK == 1 */
subql #1,SYM (_Thread_Dispatch_disable_level)
| unnest multitasking
bne.b exit | If dispatch disabled, exit

View File

@@ -84,7 +84,7 @@ extern "C" {
#define CPU_IDLE_TASK_IS_FP FALSE
#define CPU_USE_DEFERRED_FP_SWITCH TRUE
#define CPU_PROVIDES_IDLE_THREAD_BODY FALSE
#define CPU_PROVIDES_IDLE_THREAD_BODY TRUE
#define CPU_STACK_GROWS_UP FALSE
#define CPU_STRUCTURE_ALIGNMENT
@@ -416,6 +416,17 @@ unsigned32 _CPU_ISR_Get_level( void );
/* end of Context handler macros */
/*
* _CPU_Thread_Idle_body
*
* This routine is the CPU dependent IDLE thread body.
*
* NOTE: It need only be provided if CPU_PROVIDES_IDLE_THREAD_BODY
* is TRUE.
*/
void _CPU_Thread_Idle_body( void );
/*
* Fatal Error manager macros
*