tags +patch
thanks

This patch fixes sys_personality for the o32 emulation by
 a) killing the sign extension bits
 b) tighten the bitmask match for current->personality (like it is done
    for x86_64)

Already submitted to [EMAIL PROTECTED]


Thiemo


Signed-off-by:  Thiemo Seufer <[EMAIL PROTECTED]>


--- a/arch/mips/kernel/linux32.c
+++ b/arch/mips/kernel/linux32.c
@@ -1053,7 +1053,9 @@ asmlinkage long sys32_newuname(struct ne
 asmlinkage int sys32_personality(unsigned long personality)
 {
        int ret;
-       if (current->personality == PER_LINUX32 && personality == PER_LINUX)
+       personality &= 0xffffffff;
+       if (personality(current->personality) == PER_LINUX32 &&
+           personality == PER_LINUX)
                personality = PER_LINUX32;
        ret = sys_personality(personality);
        if (ret == PER_LINUX32)


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to