aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-xtensa
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-xtensa')
-rw-r--r--include/asm-xtensa/bug.h25
-rw-r--r--include/asm-xtensa/byteorder.h4
-rw-r--r--include/asm-xtensa/irq_regs.h1
-rw-r--r--include/asm-xtensa/unistd.h3
-rw-r--r--include/asm-xtensa/xtensa/config-linux_be/tie.h2
5 files changed, 8 insertions, 27 deletions
diff --git a/include/asm-xtensa/bug.h b/include/asm-xtensa/bug.h
index 56703659b204..3e52d72712f1 100644
--- a/include/asm-xtensa/bug.h
+++ b/include/asm-xtensa/bug.h
@@ -13,29 +13,6 @@
13#ifndef _XTENSA_BUG_H 13#ifndef _XTENSA_BUG_H
14#define _XTENSA_BUG_H 14#define _XTENSA_BUG_H
15 15
16#include <linux/stringify.h> 16#include <asm-generic/bug.h>
17
18#define ILL __asm__ __volatile__ (".byte 0,0,0\n")
19
20#ifdef CONFIG_KALLSYMS
21# define BUG() do { \
22 printk("kernel BUG at %s:%d!\n", __FILE__, __LINE__); \
23 ILL; \
24} while (0)
25#else
26# define BUG() do { \
27 printk("kernel BUG!\n"); \
28 ILL; \
29} while (0)
30#endif
31
32#define BUG_ON(condition) do { if (unlikely((condition)!=0)) BUG(); } while(0)
33#define PAGE_BUG(page) do { BUG(); } while (0)
34#define WARN_ON(condition) do { \
35 if (unlikely((condition)!=0)) { \
36 printk ("Warning in %s at %s:%d\n", __FUNCTION__, __FILE__, __LINE__); \
37 dump_stack(); \
38 } \
39} while (0)
40 17
41#endif /* _XTENSA_BUG_H */ 18#endif /* _XTENSA_BUG_H */
diff --git a/include/asm-xtensa/byteorder.h b/include/asm-xtensa/byteorder.h
index 0b1552569aae..0ba72ddbf889 100644
--- a/include/asm-xtensa/byteorder.h
+++ b/include/asm-xtensa/byteorder.h
@@ -14,7 +14,7 @@
14#include <asm/processor.h> 14#include <asm/processor.h>
15#include <asm/types.h> 15#include <asm/types.h>
16 16
17static __inline__ __const__ __u32 ___arch__swab32(__u32 x) 17static __inline__ __attribute_const__ __u32 ___arch__swab32(__u32 x)
18{ 18{
19 __u32 res; 19 __u32 res;
20 /* instruction sequence from Xtensa ISA release 2/2000 */ 20 /* instruction sequence from Xtensa ISA release 2/2000 */
@@ -29,7 +29,7 @@ static __inline__ __const__ __u32 ___arch__swab32(__u32 x)
29 return res; 29 return res;
30} 30}
31 31
32static __inline__ __const__ __u16 ___arch__swab16(__u16 x) 32static __inline__ __attribute_const__ __u16 ___arch__swab16(__u16 x)
33{ 33{
34 /* Given that 'short' values are signed (i.e., can be negative), 34 /* Given that 'short' values are signed (i.e., can be negative),
35 * we cannot assume that the upper 16-bits of the register are 35 * we cannot assume that the upper 16-bits of the register are
diff --git a/include/asm-xtensa/irq_regs.h b/include/asm-xtensa/irq_regs.h
new file mode 100644
index 000000000000..3dd9c0b70270
--- /dev/null
+++ b/include/asm-xtensa/irq_regs.h
@@ -0,0 +1 @@
#include <asm-generic/irq_regs.h>
diff --git a/include/asm-xtensa/unistd.h b/include/asm-xtensa/unistd.h
index 2e1a1b997e7d..15b0932523d5 100644
--- a/include/asm-xtensa/unistd.h
+++ b/include/asm-xtensa/unistd.h
@@ -218,6 +218,8 @@
218 218
219#define SYSXTENSA_COUNT 5 /* count of syscall0 functions*/ 219#define SYSXTENSA_COUNT 5 /* count of syscall0 functions*/
220 220
221#ifdef __KERNEL__
222
221/* 223/*
222 * "Conditional" syscalls 224 * "Conditional" syscalls
223 * 225 *
@@ -230,6 +232,7 @@
230#define __ARCH_WANT_SYS_UTIME 232#define __ARCH_WANT_SYS_UTIME
231#define __ARCH_WANT_SYS_LLSEEK 233#define __ARCH_WANT_SYS_LLSEEK
232#define __ARCH_WANT_SYS_RT_SIGACTION 234#define __ARCH_WANT_SYS_RT_SIGACTION
235
233#endif /* __KERNEL__ */ 236#endif /* __KERNEL__ */
234 237
235#endif /* _XTENSA_UNISTD_H */ 238#endif /* _XTENSA_UNISTD_H */
diff --git a/include/asm-xtensa/xtensa/config-linux_be/tie.h b/include/asm-xtensa/xtensa/config-linux_be/tie.h
index 3c2e514602f4..07c6d1ca4589 100644
--- a/include/asm-xtensa/xtensa/config-linux_be/tie.h
+++ b/include/asm-xtensa/xtensa/config-linux_be/tie.h
@@ -115,7 +115,7 @@
115/* ... */ 115/* ... */
116 116
117 117
118#ifdef _ASMLANGUAGE 118#ifdef __ASSEMBLER__
119/* 119/*
120 * Assembly-language specific definitions (assembly macros, etc.). 120 * Assembly-language specific definitions (assembly macros, etc.).
121 */ 121 */