Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394...
[sfrench/cifs-2.6.git] / include / asm-mips / mipsmtregs.h
index a669c0702c66705fc7440b1056d9727ad03bc8b9..294bca12cd3fd443183aeb85cdb505f7d1822484 100644 (file)
 
 #ifndef __ASSEMBLY__
 
-extern void mips_mt_regdump(void);
-
 static inline unsigned int dvpe(void)
 {
        int res = 0;
@@ -234,7 +232,7 @@ static inline void __raw_emt(void)
        __asm__ __volatile__(
        "       .set    noreorder                                       \n"
        "       .set    mips32r2                                        \n"
-       "       emt                                                     \n"
+       "       .word   0x41600be1                      # emt           \n"
        "       ehb                                                     \n"
        "       .set    mips0                                           \n"
        "       .set    reorder");
@@ -282,8 +280,11 @@ static inline void ehb(void)
                                                                        \
        __asm__ __volatile__(                                           \
        "       .set    push                                    \n"     \
+       "       .set    noat                                    \n"     \
        "       .set    mips32r2                                \n"     \
-       "       mftgpr  %0," #rt "                              \n"     \
+       "       # mftgpr $1," #rt "                             \n"     \
+       "       .word   0x41000820 | (" #rt " << 16)            \n"     \
+       "       move    %0, $1                                  \n"     \
        "       .set    pop                                     \n"     \
        : "=r" (__res));                                                \
                                                                        \
@@ -295,9 +296,7 @@ static inline void ehb(void)
        unsigned long __res;                                            \
                                                                        \
        __asm__ __volatile__(                                           \
-       ".set noat\n\t"                                                 \
-       "mftr\t%0, " #rt ", " #u ", " #sel "\n\t"                       \
-       ".set at\n\t"                                                   \
+       "       mftr    %0, " #rt ", " #u ", " #sel "           \n"     \
        : "=r" (__res));                                                \
                                                                        \
        __res;                                                          \
@@ -351,6 +350,8 @@ do {                                                                        \
 #define write_vpe_c0_vpecontrol(val)   mttc0(1, 1, val)
 #define read_vpe_c0_vpeconf0()         mftc0(1, 2)
 #define write_vpe_c0_vpeconf0(val)     mttc0(1, 2, val)
+#define read_vpe_c0_count()            mftc0(9, 0)
+#define write_vpe_c0_count(val)                mttc0(9, 0, val)
 #define read_vpe_c0_status()           mftc0(12, 0)
 #define write_vpe_c0_status(val)       mttc0(12, 0, val)
 #define read_vpe_c0_cause()            mftc0(13, 0)
@@ -364,6 +365,9 @@ do {                                                                        \
 #define read_vpe_c0_ebase()            mftc0(15,1)
 #define write_vpe_c0_ebase(val)                mttc0(15, 1, val)
 #define write_vpe_c0_compare(val)      mttc0(11, 0, val)
+#define read_vpe_c0_badvaddr()         mftc0(8, 0)
+#define read_vpe_c0_epc()              mftc0(14, 0)
+#define write_vpe_c0_epc(val)          mttc0(14, 0, val)
 
 
 /* TC */