Patent ID: 9734326
Date: 2017-08-15
CPC Classifications: G06F

Claim:
1. A computer system comprising: a first memory storing an interrupt stack, the interrupt stack structured as a Last In-First Out (LIFO) buffer and having memory addresses extending between a top address and a bottom address; a second memory storing a software program; a central processing unit (CPU) configured to access the software program and including an interrupt protection unit with a first address register, a second register and a processor coupled to the first address register and the second address register, the first and the second address register each storing a respective address of the interrupt stack, and the processor and the CPU coupled to the first memory to access the interrupt stack to store and remove at least one stack frame onto and off the stack as directed by the software program, the processor configured to: set an access rule based on at least the first and second address registers when a first stack frame is stored onto the stack and an execution of the software program is suspended by the CPU responsive to an occurrence of a first interrupt service request (ISR) to prevent a first interrupt service routine that services the first ISR from accessing a hardware-protected region of the stack, the hardware-protected region of the stack comprising the first stack frame and at least one stack frame associated with one or more suspended interrupt service routines that service one or more suspended ISRs, wherein when the first stack frame has been stored onto the stack and the execution of the software program is suspended by the CPU, responsive to one or more occurring ISRs the processor is configured to hold a first set of contiguous stack frames corresponding to the first ISR, a second set of contiguous stack frames corresponding to a second ISR and a third set of contiguous stack frames corresponding to a third ISR in the stack in a LIFO linked list, until the one or more occurring ISRs interrupt service requests are serviced.