Merge branch 'x86-syscall-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
[sfrench/cifs-2.6.git] / arch / arm64 / include / asm / uaccess.h
index fab46a0ea223d74781464a2a3904a4d2eac0a423..a801a48a7972aca80f101d645f4ae9523dc9b435 100644 (file)
@@ -45,6 +45,9 @@ static inline void set_fs(mm_segment_t fs)
 {
        current_thread_info()->addr_limit = fs;
 
 {
        current_thread_info()->addr_limit = fs;
 
+       /* On user-mode return, check fs is correct */
+       set_thread_flag(TIF_FSCHECK);
+
        /*
         * Enable/disable UAO so that copy_to_user() etc can access
         * kernel memory with the unprivileged instructions.
        /*
         * Enable/disable UAO so that copy_to_user() etc can access
         * kernel memory with the unprivileged instructions.