X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=include%2Fasm-sparc%2Fwinmacro.h;h=557257eef3f947b0f2d60bee5267a0bd8e9f05d0;hb=6a77f38946aaee1cd85eeec6cf4229b204c15071;hp=cb80840b111ef43f74bb9dfe02b797fbafcaea8c;hpb=87fc8d1bb10cd459024a742c6a10961fefcef18f;p=linux-2.6.git diff --git a/include/asm-sparc/winmacro.h b/include/asm-sparc/winmacro.h index cb80840b1..557257eef 100644 --- a/include/asm-sparc/winmacro.h +++ b/include/asm-sparc/winmacro.h @@ -112,9 +112,12 @@ and %idreg, 0xc, %idreg; \ ld [%idreg + %dest_reg], %dest_reg; -/* Sliiick. We have a Linux current register :) -jj */ -#define LOAD_CURRENT4D(dest_reg) \ - lda [%g0] ASI_M_VIKING_TMP2, %dest_reg; +#define LOAD_CURRENT4D(dest_reg, idreg) \ + lda [%g0] ASI_M_VIKING_TMP1, %idreg; \ + sethi %hi(C_LABEL(current_set)), %dest_reg; \ + sll %idreg, 2, %idreg; \ + or %dest_reg, %lo(C_LABEL(current_set)), %dest_reg; \ + ld [%idreg + %dest_reg], %dest_reg; /* Blackbox - take care with this... - check smp4m and smp4d before changing this. */ #define LOAD_CURRENT(dest_reg, idreg) \