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: <1fe6ca57-c879-2459-1a1f-24b21bd19b@inria.fr>
Date: Tue, 25 Mar 2025 12:44:58 +0100 (CET)
From: Julia Lawall <julia.lawall@...ia.fr>
To: nancyenos <nicymimz@...il.com>
cc: gregkh@...uxfoundation.org, linux-staging@...ts.linux.dev, 
    linux-kernel@...r.kernel.org, outreachy@...ts.linux.dev
Subject: Re: [PATCH] staging: octeon: Fix unused macro Argument 'x'

On Tue, 25 Mar 2025, nancyenos wrote:

> warning found by checkpath.pl
>
> Signed-off-by: nancyenos <nicymimz@...il.com>
> ---
>  drivers/staging/octeon/octeon-stubs.h | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/staging/octeon/octeon-stubs.h b/drivers/staging/octeon/octeon-stubs.h
> index 44cced319c11..0155f3c41657 100644
> --- a/drivers/staging/octeon/octeon-stubs.h
> +++ b/drivers/staging/octeon/octeon-stubs.h
> @@ -8,8 +8,8 @@
>  #define OCTEON_IRQ_WORKQ0 0
>  #define OCTEON_IRQ_RML 0
>  #define OCTEON_IRQ_TIMER1 0
> -#define OCTEON_IS_MODEL(x) 0
> -#define octeon_has_feature(x)	0
> +#define OCTEON_IS_MODEL(x) ((void)(x), 0)
> +#define octeon_has_feature(x) ((void)(x), 0)

I'm not sure that this is useful.  It seems that there may be multiple
definitions; one that has an argument and a default one that doesn't need
anything.  It's true that this change will ensure that x is checked by the
compiler, which may help find some bugs.  Have you seen other code that
makes this kind of change?

thanks,
julia

>  #define octeon_get_clock_rate()	0
>
>  #define CVMX_SYNCIOBDMA		do { } while (0)
> --
> 2.25.1
>
>
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ