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-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240715172826.wbmlg52ckdxze7sg@quack3>
Date: Mon, 15 Jul 2024 19:28:26 +0200
From: Jan Kara <jack@...e.cz>
To: Mirsad Todorovac <mtodorovac69@...il.com>
Cc: Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	"Gustavo A. R. Silva" <gustavoars@...nel.org>,
	Kees Cook <kees@...nel.org>, Christian Brauner <brauner@...nel.org>,
	Jan Kara <jack@...e.cz>,
	"Matthew Wilcox (Oracle)" <willy@...radead.org>,
	Al Viro <viro@...iv.linux.org.uk>, Jeff Layton <jlayton@...nel.org>,
	reiserfs-devel@...r.kernel.org
Subject: Re: [PROBLEM linux-next] fs/reiserfs/do_balan.c:1147:13: error: variable ‘leaf_mi’ set but not used [-Werror=unused-but-set-variable]

Hello Mirsad!

On Wed 10-07-24 20:09:27, Mirsad Todorovac wrote:
> On the linux-next vanilla next-20240709 tree, I have attempted the seed KCONFIG_SEED=0xEE7AB52F
> which was known from before to trigger various errors in compile and build process.
> 
> Though this might seem as contributing to channel noise, Linux refuses to build this config,
> treating warnings as errors, using this build line:
> 
> $ time nice make W=1 -k -j 36 |& tee ../err-next-20230709-01a.log; date
> 
> As I know that the Chief Penguin doesn't like warnings, but I am also aware that there are plenty
> left, there seems to be more tedious work ahead to make the compilers happy.
> 
> The compiler output is:
> 
> ---------------------------------------------------------------------------------------------------------
> fs/reiserfs/do_balan.c: In function ‘balance_leaf_new_nodes_paste_whole’:
> fs/reiserfs/do_balan.c:1147:13: error: variable ‘leaf_mi’ set but not used [-Werror=unused-but-set-variable]
>  1147 |         int leaf_mi;
>       |             ^~~~~~~

Frankly, I wouldn't bother with reiserfs. The warning is there for ages,
the code is going to get removed in two releases, so I guess we can live
with these warnings for a few more months...

								Honza


>   CC      fs/reiserfs/lbalance.o
> fs/reiserfs/fix_node.c: In function ‘dc_check_balance_leaf’:
> fs/reiserfs/fix_node.c:1938:13: error: variable ‘maxsize’ set but not used [-Werror=unused-but-set-variable]
>  1938 |         int maxsize, ret;
>       |             ^~~~~~~
> fs/reiserfs/fix_node.c:1935:13: error: variable ‘levbytes’ set but not used [-Werror=unused-but-set-variable]
>  1935 |         int levbytes;
>       |             ^~~~~~~~
> fs/reiserfs/prints.c: In function ‘prepare_error_buf’:
> fs/reiserfs/prints.c:221:17: error: function ‘prepare_error_buf’ might be a candidate for ‘gnu_printf’ format attribute [-Werror=suggest-attribute=format]
>   221 |                 p += vscnprintf(p, end - p, fmt1, args);
>       |                 ^
> fs/reiserfs/prints.c:260:9: error: function ‘prepare_error_buf’ might be a candidate for ‘gnu_printf’ format attribute [-Werror=suggest-attribute=format]
>   260 |         p += vscnprintf(p, end - p, fmt1, args);
>       |         ^
> make[4]: Target 'arch/x86/kernel/' not remade because of errors.
> make[3]: *** [scripts/Makefile.build:485: arch/x86/kernel] Error 2
> make[3]: Target 'arch/x86/' not remade because of errors.
> make[2]: *** [scripts/Makefile.build:485: arch/x86] Error 2
> fs/reiserfs/lbalance.c: In function ‘leaf_copy_items’:
> fs/reiserfs/lbalance.c:524:29: error: variable ‘dest’ set but not used [-Werror=unused-but-set-variable]
>   524 |         struct buffer_head *dest;
>       |                             ^~~~
> cc1: all warnings being treated as errors
> make[4]: *** [scripts/Makefile.build:244: fs/reiserfs/do_balan.o] Error 1
> cc1: all warnings being treated as errors
> make[4]: *** [scripts/Makefile.build:244: fs/reiserfs/prints.o] Error 1
> cc1: all warnings being treated as errors
> make[4]: *** [scripts/Makefile.build:244: fs/reiserfs/fix_node.o] Error 1
> ---------------------------------------------------------------------------------------------------------
> 
> In fs/reiserfs/fix_node.c:1938:13, fs/reiserfs/fix_node.c:1935:13, and fs/reiserfs/lbalance.c:524:29,
> the problem seem to lie within the construct RFALSE(), like
> 
>  521 static int leaf_copy_items(struct buffer_info *dest_bi, struct buffer_head *src,
>  522                            int last_first, int cpy_num, int cpy_bytes)
>  523 {
>  524         struct buffer_head *dest;
>  525         int pos, i, src_nr_item, bytes;
>  526 
>  527         dest = dest_bi->bi_bh;
>  528         RFALSE(!dest || !src, "vs-10210: !dest || !src");
>  529         RFALSE(last_first != FIRST_TO_LAST && last_first != LAST_TO_FIRST,
>  530                "vs-10220:last_first != FIRST_TO_LAST && last_first != LAST_TO_FIRST");
>  531         RFALSE(B_NR_ITEMS(src) < cpy_num,
>  532                "vs-10230: No enough items: %d, req. %d", B_NR_ITEMS(src),
>  533                cpy_num);
>  534         RFALSE(cpy_num < 0, "vs-10240: cpy_num < 0 (%d)", cpy_num);
> 
> Hope this helps.
> 
> Best regards,
> Mirsad Todorovac
> 
-- 
Jan Kara <jack@...e.com>
SUSE Labs, CR

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ