aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--include/asm-arm/system.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/include/asm-arm/system.h b/include/asm-arm/system.h
index f60faccf01fa..e160aeb0138d 100644
--- a/include/asm-arm/system.h
+++ b/include/asm-arm/system.h
@@ -173,6 +173,26 @@ static inline void set_copro_access(unsigned int val)
173extern unsigned long cr_no_alignment; /* defined in entry-armv.S */ 173extern unsigned long cr_no_alignment; /* defined in entry-armv.S */
174extern unsigned long cr_alignment; /* defined in entry-armv.S */ 174extern unsigned long cr_alignment; /* defined in entry-armv.S */
175 175
176#ifndef CONFIG_SMP
177static inline void adjust_cr(unsigned long mask, unsigned long set)
178{
179 unsigned long flags, cr;
180
181 mask &= ~CR_A;
182
183 set &= mask;
184
185 local_irq_save(flags);
186
187 cr_no_alignment = (cr_no_alignment & ~mask) | set;
188 cr_alignment = (cr_alignment & ~mask) | set;
189
190 set_cr((get_cr() & ~mask) | set);
191
192 local_irq_restore(flags);
193}
194#endif
195
176#define UDBG_UNDEFINED (1 << 0) 196#define UDBG_UNDEFINED (1 << 0)
177#define UDBG_SYSCALL (1 << 1) 197#define UDBG_SYSCALL (1 << 1)
178#define UDBG_BADABORT (1 << 2) 198#define UDBG_BADABORT (1 << 2)