2 * Copyright 2007-2009 Analog Devices Inc.
3 * Philippe Gerum <rpm@xenomai.org>
5 * Licensed under the GPL-2 or later.
8 #ifndef _ASM_BLACKFIN_PDA_H
9 #define _ASM_BLACKFIN_PDA_H
11 #include <mach/anomaly.h>
15 struct blackfin_pda
{ /* Per-processor Data Area */
17 struct blackfin_pda
*next
;
22 unsigned long imask
; /* Current IMASK value */
25 unsigned long *ipdt
; /* Start of switchable I-CPLB table */
26 unsigned long *ipdt_swapcount
; /* Number of swaps in ipdt */
27 unsigned long *dpdt
; /* Start of switchable D-CPLB table */
28 unsigned long *dpdt_swapcount
; /* Number of swaps in dpdt */
31 * Single instructions can have multiple faults, which
32 * need to be handled by traps.c, in irq5. We store
33 * the exception cause to ensure we don't miss a
34 * double fault condition
36 unsigned long ex_iptr
;
37 unsigned long ex_optr
;
38 unsigned long ex_buf
[4];
39 unsigned long ex_imask
; /* Saved imask from exception */
40 unsigned long ex_ipend
; /* Saved IPEND from exception */
41 unsigned long *ex_stack
; /* Exception stack space */
43 #ifdef ANOMALY_05000261
44 unsigned long last_cplb_fault_retx
;
46 unsigned long dcplb_fault_addr
;
47 unsigned long icplb_fault_addr
;
49 unsigned long seqstat
;
50 unsigned int __nmi_count
; /* number of times NMI asserted on this CPU */
51 #ifdef CONFIG_DEBUG_DOUBLEFAULT
52 unsigned long dcplb_doublefault_addr
;
53 unsigned long icplb_doublefault_addr
;
54 unsigned long retx_doublefault
;
55 unsigned long seqstat_doublefault
;
59 struct blackfin_initial_pda
{
61 #ifdef CONFIG_DEBUG_DOUBLEFAULT
62 void *dcplb_doublefault_addr
;
63 void *icplb_doublefault_addr
;
64 void *retx_doublefault
;
65 unsigned seqstat_doublefault
;
69 extern struct blackfin_pda cpu_pda
[];
71 #endif /* __ASSEMBLY__ */
73 #endif /* _ASM_BLACKFIN_PDA_H */