Commit d3584183 authored by David S. Miller's avatar David S. Miller

sparc64: Fix SET_PERSONALITY to not clip bits outside of PER_MASK.

Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 956d039a
...@@ -208,8 +208,9 @@ do { unsigned long new_flags = current_thread_info()->flags; \ ...@@ -208,8 +208,9 @@ do { unsigned long new_flags = current_thread_info()->flags; \
else \ else \
clear_thread_flag(TIF_ABI_PENDING); \ clear_thread_flag(TIF_ABI_PENDING); \
/* flush_thread will update pgd cache */ \ /* flush_thread will update pgd cache */ \
if (current->personality != PER_LINUX32) \ if (personality(current->personality) != PER_LINUX32) \
set_personality(PER_LINUX); \ set_personality(PER_LINUX | \
(current->personality & (~PER_MASK))); \
} while (0) } while (0)
#endif /* !(__ASM_SPARC64_ELF_H) */ #endif /* !(__ASM_SPARC64_ELF_H) */
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment