Skip to content
Commit 537094b6 authored by Andrey Ryabinin's avatar Andrey Ryabinin Committed by Russell King
Browse files

ARM: 8051/1: put_user: fix possible data corruption in put_user



According to arm procedure call standart r2 register is call-cloberred.
So after the result of x expression was put into r2 any following
function call in p may overwrite r2. To fix this, the result of p
expression must be saved to the temporary variable before the
assigment x expression to __r2.

Signed-off-by: default avatarAndrey Ryabinin <a.ryabinin@samsung.com>
Reviewed-by: default avatarNicolas Pitre <nico@linaro.org>
Cc: stable@vger.kernel.org
Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
parent f9ff907b
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