All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michael Ellerman <mpe@ellerman.id.au>
To: wuyonggang001@208suo.com, shuah@kernel.org
Cc: linuxppc-dev@lists.ozlabs.org, linux-kselftest@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] selftests/powerpc: Remove unneeded variable
Date: Thu, 15 Jun 2023 13:51:48 +1000	[thread overview]
Message-ID: <87a5x1fkmj.fsf@mail.lhotse> (raw)
In-Reply-To: <553bb6053c7b7bee60eda3ca90470ac3@208suo.com>

wuyonggang001@208suo.com writes:
> Fix the following coccicheck warning:
>
> tools/testing/selftests/powerpc/alignment/alignment_handler.c:558:5-7: 
> Unneeded variable: "rc". Return "0"

The check is wrong.

> diff --git 
> a/tools/testing/selftests/powerpc/alignment/alignment_handler.c 
> b/tools/testing/selftests/powerpc/alignment/alignment_handler.c
> index 33ee34fc0828..4980656c3f70 100644
> --- a/tools/testing/selftests/powerpc/alignment/alignment_handler.c
> +++ b/tools/testing/selftests/powerpc/alignment/alignment_handler.c
> @@ -332,7 +332,7 @@ int test_alignment_handler_vsx_206(void)
>       STORE_VSX_XFORM_TEST(stxvd2x);
>       STORE_VSX_XFORM_TEST(stxvw4x);
>       STORE_VSX_XFORM_TEST(stxsdx);
> -    return rc;
> +    return 0;

rc is used in the macros.

cheers

WARNING: multiple messages have this Message-ID (diff)
From: Michael Ellerman <mpe@ellerman.id.au>
To: wuyonggang001@208suo.com, shuah@kernel.org
Cc: linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org,
	linux-kselftest@vger.kernel.org
Subject: Re: [PATCH] selftests/powerpc: Remove unneeded variable
Date: Thu, 15 Jun 2023 13:51:48 +1000	[thread overview]
Message-ID: <87a5x1fkmj.fsf@mail.lhotse> (raw)
In-Reply-To: <553bb6053c7b7bee60eda3ca90470ac3@208suo.com>

wuyonggang001@208suo.com writes:
> Fix the following coccicheck warning:
>
> tools/testing/selftests/powerpc/alignment/alignment_handler.c:558:5-7: 
> Unneeded variable: "rc". Return "0"

The check is wrong.

> diff --git 
> a/tools/testing/selftests/powerpc/alignment/alignment_handler.c 
> b/tools/testing/selftests/powerpc/alignment/alignment_handler.c
> index 33ee34fc0828..4980656c3f70 100644
> --- a/tools/testing/selftests/powerpc/alignment/alignment_handler.c
> +++ b/tools/testing/selftests/powerpc/alignment/alignment_handler.c
> @@ -332,7 +332,7 @@ int test_alignment_handler_vsx_206(void)
>       STORE_VSX_XFORM_TEST(stxvd2x);
>       STORE_VSX_XFORM_TEST(stxvw4x);
>       STORE_VSX_XFORM_TEST(stxsdx);
> -    return rc;
> +    return 0;

rc is used in the macros.

cheers

  reply	other threads:[~2023-06-15  3:51 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20230614070926.36395-1-zhanglibing@cdjrlc.com>
2023-06-14  7:12 ` [PATCH] selftests/powerpc: Remove unneeded variable wuyonggang001
2023-06-14  7:12   ` wuyonggang001
2023-06-15  3:51   ` Michael Ellerman [this message]
2023-06-15  3:51     ` Michael Ellerman
     [not found] <20230614064848.5648-1-luojianhong@cdjrlc.com>
2023-06-14  6:51 ` [PATCH] selftests/powerpc: remove " baomingtong001

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87a5x1fkmj.fsf@mail.lhotse \
    --to=mpe@ellerman.id.au \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=shuah@kernel.org \
    --cc=wuyonggang001@208suo.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.