Ignore:
Timestamp:
May 10, 2007, 6:40:49 PM (13 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, master
Children:
45d406f8
Parents:
93c2b41
Message:

2007-05-10 Joel Sherrill <joel.sherrill@…>

PR 1237/rtems

  • cpu.c, cpu_asm.S, rtems/score/cpu.h: Add logic to prevent stack creep when interrupts occur at a sufficient rate that the interrupted thread never gets to clean its stack. This patch ensures that an interrupted thread will not nest ISR dispatches on its stack.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpukit/score/cpu/sparc/rtems/score/cpu.h

    r93c2b41 ra32835a3  
    334334
    335335    uint32_t   psr;
     336    uint32_t   isr_dispatch_disable;
    336337} Context_Control;
    337338
     
    379380
    380381#define PSR_OFFSET   0x80
    381 
    382 #define CONTEXT_CONTROL_SIZE 0x84
     382#define ISR_DISPATCH_DISABLE_STACK_OFFSET 0x84
     383
     384#define CONTEXT_CONTROL_SIZE 0x88
    383385
    384386/*
     
    554556
    555557/*
     558 *  This flag is context switched with each thread.  It indicates
     559 *  that THIS thread has an _ISR_Dispatch stack frame on its stack.
     560 *  By using this flag, we can avoid nesting more interrupt dispatching
     561 *  attempts on a previously interrupted thread's stack.
     562 */
     563
     564SCORE_EXTERN volatile uint32_t _CPU_ISR_Dispatch_disable;
     565
     566/*
    556567 *  The following type defines an entry in the SPARC's trap table.
    557568 *
Note: See TracChangeset for help on using the changeset viewer.