VisionFive2 Linux kernel

StarFive Tech Linux Kernel for VisionFive (JH7110) boards (mirror)

More than 9999 Commits   32 Branches   54 Tags
author: Jiri Kosina <jkosina@suse.cz> 2012-10-04 17:12:20 -0700 committer: Linus Torvalds <torvalds@linux-foundation.org> 2012-10-06 03:04:47 +0900 commit: 16f3e95b3209c4d9080e3a3c6bb9955a0e7cfa95 parent: 0d118d7f49c8aa0b74be83bc2ad134b71106cab4
Commit Summary:
cross-arch: don't corrupt personality flags upon exec()
Diffstat:
1 file changed, 2 insertions, 1 deletion
diff --git a/arch/h8300/include/asm/elf.h b/arch/h8300/include/asm/elf.h
index c24fa250d653..41193c396bff 100644
--- a/arch/h8300/include/asm/elf.h
+++ b/arch/h8300/include/asm/elf.h
@@ -54,7 +54,8 @@ typedef unsigned long elf_fpregset_t;
 
 #define ELF_PLATFORM  (NULL)
 
-#define SET_PERSONALITY(ex) set_personality(PER_LINUX)
+#define SET_PERSONALITY(ex) \
+	set_personality(PER_LINUX | (current->personality & (~PER_MASK)))
 
 #define R_H8_NONE       0
 #define R_H8_DIR32      1