mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Muhammad Usama Anjum <usama.anjum@collabora.com>
To: "Thomas Weißschuh" <thomas.weissschuh@linutronix.de>,
	"Andy Lutomirski" <luto@kernel.org>,
	"Thomas Gleixner" <tglx@linutronix.de>,
	"Vincenzo Frascino" <vincenzo.frascino@arm.com>,
	"Shuah Khan" <shuah@kernel.org>,
	"Jason A. Donenfeld" <Jason@zx2c4.com>
Cc: usama.anjum@collabora.com, Shuah Khan <skhan@linuxfoundation.org>,
	linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org
Subject: Re: [PATCH 7/7] selftests: vDSO: vdso_config: Avoid -Wunused-variables
Date: Fri, 2 May 2025 18:49:01 +0500	[thread overview]
Message-ID: <27d03a23-ec61-4dbe-b9ca-1c0cf3d52d29@collabora.com> (raw)
In-Reply-To: <20250502-selftests-vdso-fixes-v1-7-fb5d640a4f78@linutronix.de>

On 5/2/25 5:40 PM, Thomas Weißschuh wrote:
> Not all users of this header make use of all its variables.
> For example vdso_test_correctness.c does not use "versions":
> 
> In file included from vdso_test_correctness.c:22:
> vdso_config.h:61:20: warning: ‘versions’ defined but not used [-Wunused-variable]
>    61 | static const char *versions[7] = {
>       |                    ^~~~~~~~
> 
> Avoid those warnings through attribute((unused)).
> 
> Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
Reviewed-by: Muhammad Usama Anjum <usama.anjum@collabora.com>

> ---
>  tools/testing/selftests/vDSO/vdso_config.h | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/tools/testing/selftests/vDSO/vdso_config.h b/tools/testing/selftests/vDSO/vdso_config.h
> index 722260f9756198956f0dfccced907284b6851e76..5fdd0f36233742bc47ae79f23d2cfae5a0f56dee 100644
> --- a/tools/testing/selftests/vDSO/vdso_config.h
> +++ b/tools/testing/selftests/vDSO/vdso_config.h
> @@ -58,6 +58,7 @@
>  #define VDSO_NAMES		1
>  #endif
>  
> +__attribute__((unused))
>  static const char *versions[7] = {
>  	"LINUX_2.6",
>  	"LINUX_2.6.15",
> @@ -68,6 +69,7 @@ static const char *versions[7] = {
>  	"LINUX_5.10"
>  };
>  
> +__attribute__((unused))
>  static const char *names[2][7] = {
>  	{
>  		"__kernel_gettimeofday",
> 


-- 
Regards,
Usama

      reply	other threads:[~2025-05-02 13:49 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-02 12:40 [PATCH 0/7] selftests: vDSO: Some cleanups and fixes Thomas Weißschuh
2025-05-02 12:40 ` [PATCH 1/7] selftests: vDSO: chacha: Correctly skip test if necessary Thomas Weißschuh
2025-05-02 13:42   ` Muhammad Usama Anjum
2025-05-02 12:40 ` [PATCH 2/7] selftests: vDSO: clock_getres: Drop unused include of err.h Thomas Weißschuh
2025-05-02 13:43   ` Muhammad Usama Anjum
2025-05-02 12:40 ` [PATCH 3/7] selftests: vDSO: vdso_test_correctness: Fix -Wold-style-definitions Thomas Weißschuh
2025-05-02 13:44   ` Muhammad Usama Anjum
2025-05-02 12:40 ` [PATCH 4/7] selftests: vDSO: vdso_test_getrandom: Drop unused include of linux/compiler.h Thomas Weißschuh
2025-05-02 12:40 ` [PATCH 5/7] selftests: vDSO: vdso_test_getrandom: Drop some dead code Thomas Weißschuh
2025-05-02 13:46   ` Muhammad Usama Anjum
2025-05-02 12:40 ` [PATCH 6/7] selftests: vDSO: vdso_test_getrandom: Always print TAP header Thomas Weißschuh
2025-05-02 13:48   ` Muhammad Usama Anjum
2025-05-02 12:40 ` [PATCH 7/7] selftests: vDSO: vdso_config: Avoid -Wunused-variables Thomas Weißschuh
2025-05-02 13:49   ` Muhammad Usama Anjum [this message]

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=27d03a23-ec61-4dbe-b9ca-1c0cf3d52d29@collabora.com \
    --to=usama.anjum@collabora.com \
    --cc=Jason@zx2c4.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=luto@kernel.org \
    --cc=shuah@kernel.org \
    --cc=skhan@linuxfoundation.org \
    --cc=tglx@linutronix.de \
    --cc=thomas.weissschuh@linutronix.de \
    --cc=vincenzo.frascino@arm.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®