From c626aec4434149e17e4cd98174e59095a3a06e05 Mon Sep 17 00:00:00 2001 From: patacongo Date: Wed, 8 Jun 2011 18:10:55 +0000 Subject: More AVR context switching logic git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@3683 42af7a65-404d-4744-a932-0658087f49c3 --- nuttx/arch/avr/include/avr/irq.h | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'nuttx/arch/avr/include') diff --git a/nuttx/arch/avr/include/avr/irq.h b/nuttx/arch/avr/include/avr/irq.h index b387be671..d3026c185 100644 --- a/nuttx/arch/avr/include/avr/irq.h +++ b/nuttx/arch/avr/include/avr/irq.h @@ -89,9 +89,14 @@ #define REG_R0 33 /* r0 */ #define REG_R24 34 /* r24 */ +/* The program counter is automatically pushed when the interrupt occurs */ + +#define REG_PCH 35 /* PC */ +#define REG_PCL 36 + /* Size of the register state save array (in bytes) */ -#define XCPTCONTEXT_REGS 35 +#define XCPTCONTEXT_REGS 37 /**************************************************************************** * Public Types @@ -111,8 +116,9 @@ struct xcptcontext /* These are saved copies of PC and SR used during signal processing.*/ - uint16_t saved_pc; - uint8_t saved_sr; + uint8_t saved_pcl; + uint8_t saved_pch; + uint8_t saved_sreg; #endif /* Register save area */ -- cgit v1.2.3