linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] selftests/seccomp: powerpc: Fix typo in macro variable name
@ 2020-11-17 21:01 Kees Cook
  2020-11-19  6:03 ` Michael Ellerman
  0 siblings, 1 reply; 2+ messages in thread
From: Kees Cook @ 2020-11-17 21:01 UTC (permalink / raw)
  To: linux-kernel
  Cc: Kees Cook, Thadeu Lima de Souza Cascardo, Michael Ellerman,
	Andy Lutomirski, Will Drewry, linux-kselftest

A typo sneaked into the powerpc selftest. Fix the name so it builds again.

Fixes: 46138329faea ("selftests/seccomp: powerpc: Fix seccomp return value testing")
Signed-off-by: Kees Cook <keescook@chromium.org>
---
 tools/testing/selftests/seccomp/seccomp_bpf.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tools/testing/selftests/seccomp/seccomp_bpf.c b/tools/testing/selftests/seccomp/seccomp_bpf.c
index 76c458055c54..26c72f2b61b1 100644
--- a/tools/testing/selftests/seccomp/seccomp_bpf.c
+++ b/tools/testing/selftests/seccomp/seccomp_bpf.c
@@ -1758,10 +1758,10 @@ TEST_F(TRACE_poke, getpid_runs_normally)
 		 * and the code is stored as a positive value.	\
 		 */						\
 		if (_result < 0) {				\
-			SYSCALL_RET(_regs) = -result;		\
+			SYSCALL_RET(_regs) = -_result;		\
 			(_regs).ccr |= 0x10000000;		\
 		} else {					\
-			SYSCALL_RET(_regs) = result;		\
+			SYSCALL_RET(_regs) = _result;		\
 			(_regs).ccr &= ~0x10000000;		\
 		}						\
 	} while (0)
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] selftests/seccomp: powerpc: Fix typo in macro variable name
  2020-11-17 21:01 [PATCH] selftests/seccomp: powerpc: Fix typo in macro variable name Kees Cook
@ 2020-11-19  6:03 ` Michael Ellerman
  0 siblings, 0 replies; 2+ messages in thread
From: Michael Ellerman @ 2020-11-19  6:03 UTC (permalink / raw)
  To: Kees Cook, linux-kernel
  Cc: Kees Cook, Thadeu Lima de Souza Cascardo, Andy Lutomirski,
	Will Drewry, linux-kselftest

Kees Cook <keescook@chromium.org> writes:
> A typo sneaked into the powerpc selftest. Fix the name so it builds again.
>
> Fixes: 46138329faea ("selftests/seccomp: powerpc: Fix seccomp return value testing")
> Signed-off-by: Kees Cook <keescook@chromium.org>
> ---
>  tools/testing/selftests/seccomp/seccomp_bpf.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

I hit that and thought I'd sent a patch for it, but seems I never
actually sent it.

So thanks. I assume Shuah will take it.

Acked-by: Michael Ellerman <mpe@ellerman.id.au>

cheers


> diff --git a/tools/testing/selftests/seccomp/seccomp_bpf.c b/tools/testing/selftests/seccomp/seccomp_bpf.c
> index 76c458055c54..26c72f2b61b1 100644
> --- a/tools/testing/selftests/seccomp/seccomp_bpf.c
> +++ b/tools/testing/selftests/seccomp/seccomp_bpf.c
> @@ -1758,10 +1758,10 @@ TEST_F(TRACE_poke, getpid_runs_normally)
>  		 * and the code is stored as a positive value.	\
>  		 */						\
>  		if (_result < 0) {				\
> -			SYSCALL_RET(_regs) = -result;		\
> +			SYSCALL_RET(_regs) = -_result;		\
>  			(_regs).ccr |= 0x10000000;		\
>  		} else {					\
> -			SYSCALL_RET(_regs) = result;		\
> +			SYSCALL_RET(_regs) = _result;		\
>  			(_regs).ccr &= ~0x10000000;		\
>  		}						\
>  	} while (0)
> -- 
> 2.25.1

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-11-19  6:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-17 21:01 [PATCH] selftests/seccomp: powerpc: Fix typo in macro variable name Kees Cook
2020-11-19  6:03 ` Michael Ellerman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).