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: <CAHB1NagijZv=M28x+QDF8aS7rVGaPsXdaLgJvRyLODPL0DTe0w@mail.gmail.com>
Date: Tue, 23 Jul 2024 23:03:53 -0400
From: Julian Sun <sunjunchao2870@...il.com>
To: Andrew Morton <akpm@...ux-foundation.org>
Cc: linux-wireless@...r.kernel.org, linux-kernel@...r.kernel.org, 
	linux-fsdevel@...r.kernel.org, jack@...e.cz, brauner@...nel.org, 
	viro@...iv.linux.org.uk, masahiroy@...nel.org, n.schier@....de, 
	ojeda@...nel.org, djwong@...nel.org, kvalo@...nel.org
Subject: Re: [PATCH] scripts: add macro_checker script to check unused
 parameters in macros

Andrew Morton <akpm@...ux-foundation.org> 于2024年7月23日周二 18:09写道:
>
> On Tue, 23 Jul 2024 05:11:54 -0400 Julian Sun <sunjunchao2870@...il.com> wrote:
>
> > Hi,
> >
> > Recently, I saw a patch[1] on the ext4 mailing list regarding
> > the correction of a macro definition error. Jan mentioned
> > that "The bug in the macro is a really nasty trap...".
> > Because existing compilers are unable to detect
> > unused parameters in macro definitions. This inspired me
> > to write a script to check for unused parameters in
> > macro definitions and to run it.
>
>
> > Seems a useful contribution thanks.  And a nice changelog!
Thanks for your review and kind words.
>
> >  scripts/macro_checker.py | 101 +++++++++++++++++++++++++++++++++++++++
>
>
> > Makes me wonder who will run this, and why.  Perhaps a few people will
> > run ls and wonder "hey, what's that".  But many people who might have
> > been interested in running this simply won't know about it.
Yeah. For example, I am not familiar with these current checking tools...
>
>
> > "make help | grep check" shows we have a few ad-hoc integrations but I
> > wonder if we would benefit from a top-level `make static-checks'
> > target?
I have another idea. I asked some of my friends,  they are familiar
with scripts/checkpatch.pl and usually use it to check patches before
submitting them. Therefore, can we integrate some checking tools like
includecheck and macro_checker into checkpatch? This way, when
contributors use this tool, it will automatically check the modified
source files. The benefit is that contributors can benefit from these
tools without knowing their existence, and over time, all source files
will be checked.


Best regards,
-- 
Julian Sun <sunjunchao2870@...il.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ