Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros
special_insns.h File Reference

Go to the source code of this file.

Macros

#define get_creg(reg)
 
#define set_creg(reg, v)
 
#define or_creg(reg, n)
 
#define and_creg(reg, n)
 
#define get_coreid()   (get_creg(DNUM) & 0xff)
 
#define set_ist(x)   set_creg(ISTP, x)
 
#define get_ist()   get_creg(ISTP)
 
#define disable_exception()
 
#define get_except_type()   get_creg(EFR)
 
#define ack_exception(type)   set_creg(ECR, 1 << (type))
 
#define get_iexcept()   get_creg(IERR)
 
#define set_iexcept(mask)   set_creg(IERR, (mask))
 
#define _extu(x, s, e)
 

Macro Definition Documentation

#define _extu (   x,
  s,
  e 
)
Value:
({ unsigned int __x; \
asm volatile ("extu .S2 %3,%1,%2,%0\n" : \
"=b"(__x) : "n"(s), "n"(e), "b"(x)); \
__x; })

Definition at line 57 of file special_insns.h.

#define ack_exception (   type)    set_creg(ECR, 1 << (type))

Definition at line 53 of file special_insns.h.

#define and_creg (   reg,
  n 
)
Value:
do { unsigned __x, __n = (unsigned)(n); \
asm volatile ("mvc .s2 " #reg ",%0\n" \
"and .l2 %1,%0,%0\n" \
"mvc .s2 %0," #reg "\n" \
"nop\n" \
: "=&b"(__x) : "b"(__n)); \
} while (0)

Definition at line 33 of file special_insns.h.

#define disable_exception ( )

Definition at line 51 of file special_insns.h.

#define get_coreid ( )    (get_creg(DNUM) & 0xff)

Definition at line 42 of file special_insns.h.

#define get_creg (   reg)
Value:
({ unsigned int __x; \
asm volatile ("mvc .s2 " #reg ",%0\n" : "=b"(__x)); __x; })

Definition at line 15 of file special_insns.h.

#define get_except_type ( )    get_creg(EFR)

Definition at line 52 of file special_insns.h.

#define get_iexcept ( )    get_creg(IERR)

Definition at line 54 of file special_insns.h.

#define get_ist ( )    get_creg(ISTP)

Definition at line 46 of file special_insns.h.

#define or_creg (   reg,
  n 
)
Value:
do { unsigned __x, __n = (unsigned)(n); \
asm volatile ("mvc .s2 " #reg ",%0\n" \
"or .l2 %1,%0,%0\n" \
"mvc .s2 %0," #reg "\n" \
"nop\n" \
: "=&b"(__x) : "b"(__n)); \
} while (0)

Definition at line 24 of file special_insns.h.

#define set_creg (   reg,
  v 
)
Value:
do { unsigned int __x = (unsigned int)(v); \
asm volatile ("mvc .s2 %0," #reg "\n" : : "b"(__x)); \
} while (0)

Definition at line 19 of file special_insns.h.

#define set_iexcept (   mask)    set_creg(IERR, (mask))

Definition at line 55 of file special_insns.h.

#define set_ist (   x)    set_creg(ISTP, x)

Definition at line 45 of file special_insns.h.