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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <7425c8905127ddd078500d4c14a2147bd00422a0.camel@hpe.com>
Date:   Tue, 19 Feb 2019 18:28:30 +0000
From:   "Kani, Toshi" <toshi.kani@....com>
To:     "yuehaibing@...wei.com" <yuehaibing@...wei.com>,
        "cpandya@...eaurora.org" <cpandya@...eaurora.org>,
        "tglx@...utronix.de" <tglx@...utronix.de>,
        "akpm@...ux-foundation.org" <akpm@...ux-foundation.org>,
        "will.deacon@....com" <will.deacon@....com>
CC:     "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "kernel-janitors@...r.kernel.org" <kernel-janitors@...r.kernel.org>
Subject: Re: [PATCH -next] mm: fix set but not used warning

On Mon, 2019-02-18 at 13:57 +0000, YueHaibing wrote:
> Fixes gcc '-Wunused-but-set-variable' warning:
> 
> lib/ioremap.c: In function 'ioremap_page_range':
> lib/ioremap.c:203:16: warning:
>  variable 'start' set but not used [-Wunused-but-set-variable]
> 
> flush_cache_vmap may no need param, so add __maybe_unused fix this warning.

I think flush_cache_vmap should have a proper prototype with
__maybe_unused for its args.  But, there are so many arch-specific
definitions at glace, and I am not sure how manageable such change is,
though...

Thanks,
-Toshi

> 
> Signed-off-by: YueHaibing <yuehaibing@...wei.com>
> ---
>  lib/ioremap.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/lib/ioremap.c b/lib/ioremap.c
> index 063213685563..d1c7a488e731 100644
> --- a/lib/ioremap.c
> +++ b/lib/ioremap.c
> @@ -200,7 +200,7 @@ int ioremap_page_range(unsigned long addr,
>  		       unsigned long end, phys_addr_t phys_addr, pgprot_t prot)
>  {
>  	pgd_t *pgd;
> -	unsigned long start;
> +	unsigned long __maybe_unused start;
>  	unsigned long next;
>  	int err;
> 
> 
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ