bug.h 558 字节
Newer Older
L
Linus Torvalds 已提交
1 2 3
#ifndef __ASM_BUG_H
#define __ASM_BUG_H

4
#include <asm/sgidefs.h>
5 6 7

#ifdef CONFIG_BUG

L
Linus Torvalds 已提交
8 9 10 11 12 13
#include <asm/break.h>

#define BUG()								\
do {									\
	__asm__ __volatile__("break %0" : : "i" (BRK_BUG));		\
} while (0)
14 15

#define HAVE_ARCH_BUG
L
Linus Torvalds 已提交
16

17 18 19 20
#if (_MIPS_ISA > _MIPS_ISA_MIPS1)

#define BUG_ON(condition)						\
do {									\
21 22
	__asm__ __volatile__("tne $0, %0, %1"				\
			     : : "r" (condition), "i" (BRK_BUG));	\
23 24 25 26 27 28
} while (0)

#define HAVE_ARCH_BUG_ON

#endif /* _MIPS_ISA > _MIPS_ISA_MIPS1 */

L
Linus Torvalds 已提交
29
#endif
30

31 32
#include <asm-generic/bug.h>

33
#endif /* __ASM_BUG_H */
反馈
建议
客服 返回
顶部