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] [day] [month] [year] [list]
Message-ID: <ZtorJmTrerLhO5Xv@surfacebook.localdomain>
Date: Fri, 6 Sep 2024 01:05:26 +0300
From: Andy Shevchenko <andy.shevchenko@...il.com>
To: Andrew Morton <akpm@...ux-foundation.org>
Cc: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>, linux-mm@...ck.org,
	linux-kernel@...r.kernel.org, llvm@...ts.linux.dev,
	Nathan Chancellor <nathan@...nel.org>,
	Nick Desaulniers <ndesaulniers@...gle.com>,
	Bill Wendling <morbo@...gle.com>,
	Justin Stitt <justinstitt@...gle.com>
Subject: Re: [PATCH v1 1/1] mm/page_alloc: Mark has_unaccepted_memory() with
 __maybe_unused

Thu, Sep 05, 2024 at 02:22:20PM -0700, Andrew Morton kirjoitti:
> On Thu,  5 Sep 2024 20:15:53 +0300 Andy Shevchenko <andriy.shevchenko@...ux.intel.com> wrote:
> 
> > When has_unaccepted_memory() is unused, it prevents kernel builds
> > with clang, `make W=1` and CONFIG_WERROR=y:
> > 
> > mm/page_alloc.c:7036:20: error: unused function 'has_unaccepted_memory' [-Werror,-Wunused-function]
> >  7036 | static inline bool has_unaccepted_memory(void)
> >       |                    ^~~~~~~~~~~~~~~~~~~~~
> > 
> > Fix this by marking it with __maybe_unused (all cases for the sake of
> > symmetry).
> > 
> > See also commit 6863f5643dd7 ("kbuild: allow Clang to find unused static
> > inline functions for W=1 build").
> 
> has_unaccepted_memory() has no callers if CONFIG_UNACCEPTED_MEMORY=n. 
> Can't we do this better thing?

Sure! Please, use your patch, I'm fine with that
Reported-by: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>

-- 
With Best Regards,
Andy Shevchenko



Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ