0001
0002 #ifndef __ASM_ARM_SYSTEM_MISC_H
0003 #define __ASM_ARM_SYSTEM_MISC_H
0004
0005 #ifndef __ASSEMBLY__
0006
0007 #include <linux/compiler.h>
0008 #include <linux/linkage.h>
0009 #include <linux/irqflags.h>
0010 #include <linux/reboot.h>
0011 #include <linux/percpu.h>
0012
0013 extern void cpu_init(void);
0014
0015 void soft_restart(unsigned long);
0016 extern void (*arm_pm_idle)(void);
0017
0018 #ifdef CONFIG_HARDEN_BRANCH_PREDICTOR
0019 typedef void (*harden_branch_predictor_fn_t)(void);
0020 DECLARE_PER_CPU(harden_branch_predictor_fn_t, harden_branch_predictor_fn);
0021 static inline void harden_branch_predictor(void)
0022 {
0023 harden_branch_predictor_fn_t fn = per_cpu(harden_branch_predictor_fn,
0024 smp_processor_id());
0025 if (fn)
0026 fn();
0027 }
0028 #else
0029 #define harden_branch_predictor() do { } while (0)
0030 #endif
0031
0032 #define UDBG_UNDEFINED (1 << 0)
0033 #define UDBG_SYSCALL (1 << 1)
0034 #define UDBG_BADABORT (1 << 2)
0035 #define UDBG_SEGV (1 << 3)
0036 #define UDBG_BUS (1 << 4)
0037
0038 extern unsigned int user_debug;
0039
0040 #endif
0041
0042 #endif