lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230802065753.217179-1-wangzhu9@huawei.com>
Date:   Wed, 2 Aug 2023 14:57:53 +0800
From:   Zhu Wang <wangzhu9@...wei.com>
To:     <akpm@...ux-foundation.org>, <linux-kernel@...r.kernel.org>
CC:     <wangzhu9@...wei.com>
Subject: [PATCH -next] efs: fix -Wunused-const-variable= warning

When building with W=1, the following warning occurs.

In file included from fs/efs/super.c:18:0:
fs/efs/efs.h:22:19: warning: ‘cprt’ defined but not used [-Wunused-const-variable=]
 static const char cprt[] = "EFS: "EFS_VERSION" - (c) 1999 Al Smith
<Al.Smith@...chi.ch.eu.org>";
                   ^~~~
The header file is included in many C files, there are many
similar errors which are not included here. We add __maybe_unsed
to remove it.

Fixes: 45254b4fb2ae ("efs: move headers out of include/linux/")
Signed-off-by: Zhu Wang <wangzhu9@...wei.com>
---
 fs/efs/efs.h | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/fs/efs/efs.h b/fs/efs/efs.h
index 13a4d9622633..8202be1b2ade 100644
--- a/fs/efs/efs.h
+++ b/fs/efs/efs.h
@@ -19,7 +19,8 @@
 
 #define EFS_VERSION "1.0a"
 
-static const char cprt[] = "EFS: "EFS_VERSION" - (c) 1999 Al Smith <Al.Smith@...chi.ch.eu.org>";
+static const char __maybe_unused cprt[] =
+	"EFS: "EFS_VERSION" - (c) 1999 Al Smith <Al.Smith@...chi.ch.eu.org>";
 
 
 /* 1 block is 512 bytes */
-- 
2.17.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ