Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d0b48ca1 authored by Hiroshi Shimamoto's avatar Hiroshi Shimamoto Committed by Ingo Molnar
Browse files

x86: ia32_signal: use __put_user() instead of __copy_to_user()



Impact: cleanup

__put_user() can be used for constant size 8, like arch/x86/kernel/signal.c.

Signed-off-by: default avatarHiroshi Shimamoto <h-shimamoto@ct.jp.nec.com>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
parent ae417bb4
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -467,7 +467,7 @@ int ia32_setup_frame(int sig, struct k_sigaction *ka,
	 * These are actually not used anymore, but left because some
	 * gdb versions depend on them as a marker.
	 */
	err |= __copy_to_user(frame->retcode, &code, 8);
	err |= __put_user(*((u64 *)&code), (u64 *)frame->retcode);
	if (err)
		return -EFAULT;

@@ -554,7 +554,7 @@ int ia32_setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info,
	 * Not actually used anymore, but left because some gdb
	 * versions need it.
	 */
	err |= __copy_to_user(frame->retcode, &code, 8);
	err |= __put_user(*((u64 *)&code), (u64 *)frame->retcode);
	if (err)
		return -EFAULT;