summaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
authorWill Deacon <will.deacon@arm.com>2014-09-11 14:38:16 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-10-05 14:52:10 -0700
commitdcab7dc976758948c325e4d6d887d01ff4770b82 (patch)
treef1c7b48bac25efad94b9b96eba2b496ec509abfb /kernel
parent42dd6eb155777748a1c8637614f9a03c9ebc69b6 (diff)
arm64: flush TLS registers during exec
commit eb35bdd7bca29a13c8ecd44e6fd747a84ce675db upstream. Nathan reports that we leak TLS information from the parent context during an exec, as we don't clear the TLS registers when flushing the thread state. This patch updates the flushing code so that we: (1) Unconditionally zero the tpidr_el0 register (since this is fully context switched for native tasks and zeroed for compat tasks) (2) Zero the tp_value state in thread_info before clearing the tpidrr0_el0 register for compat tasks (since this is only writable by the set_tls compat syscall and therefore not fully switched). A missing compiler barrier is also added to the compat set_tls syscall. Acked-by: Nathan Lynch <Nathan_Lynch@mentor.com> Reported-by: Nathan Lynch <Nathan_Lynch@mentor.com> Signed-off-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'kernel')
0 files changed, 0 insertions, 0 deletions