All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kees Cook <kees@kernel.org>
To: Venkat Rao Bagalkote <venkat88@linux.ibm.com>
Cc: Stephen Rothwell <sfr@canb.auug.org.au>,
	nathan@kernel.org, hch@lst.de,
	Madhavan Srinivasan <maddy@linux.ibm.com>,
	LKML <linux-kernel@vger.kernel.org>,
	Linux Next Mailing List <linux-next@vger.kernel.org>
Subject: Re: [linux-next-20250422] Build failure: Wvla-larger-than=0 is meaningless
Date: Fri, 25 Apr 2025 22:50:40 -0700	[thread overview]
Message-ID: <202504252249.6F09D31FD1@keescook> (raw)
In-Reply-To: <7780883c-0ac8-4aaa-b850-469e33b50672@linux.ibm.com>

On Wed, Apr 23, 2025 at 07:11:43PM +0530, Venkat Rao Bagalkote wrote:
> I am observing linux-next build failure on IBM Power8 server.
> 
> 
> Repo: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
> 
> Branch: master
> 
> GCC: 8.5.0 20210514
> 
> ldd (GNU libc) 2.28
> 
> Attached is the .config file.
> 
> 
> Build errors:
> 
> 
> [[01m^[[Kcc1:^[[m^[[K ^[[01;36m^[[Knote: ^[[m^[[K-Wvla-larger-than=0 is
> meaningless

Weird that it doesn't get dropped by "cc-option". I reproduced the
issue, and this patch seems to fix it:

diff --git a/scripts/Makefile.extrawarn b/scripts/Makefile.extrawarn
index 70ff932fd5ec..59d3d196fe4f 100644
--- a/scripts/Makefile.extrawarn
+++ b/scripts/Makefile.extrawarn
@@ -51,7 +51,7 @@ KBUILD_CFLAGS += $(call cc-disable-warning, dangling-pointer)
 # types, so depend on GCC for now to keep stack VLAs out of the tree.
 # https://github.com/llvm/llvm-project/issues/57098
 # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98217
-KBUILD_CFLAGS += $(call cc-option,-Wvla-larger-than=0)
+KBUILD_CFLAGS += $(call cc-option,-Wvla-larger-than=1)
 
 # disable pointer signed / unsigned warnings in gcc 4.0
 KBUILD_CFLAGS += -Wno-pointer-sign


-- 
Kees Cook

  parent reply	other threads:[~2025-04-26  5:50 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-23 13:41 [linux-next-20250422] Build failure: Wvla-larger-than=0 is meaningless Venkat Rao Bagalkote
2025-04-26  5:21 ` Venkat Rao Bagalkote
2025-04-26  5:50 ` Kees Cook [this message]
2025-04-26 14:53   ` Venkat Rao Bagalkote

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202504252249.6F09D31FD1@keescook \
    --to=kees@kernel.org \
    --cc=hch@lst.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=maddy@linux.ibm.com \
    --cc=nathan@kernel.org \
    --cc=sfr@canb.auug.org.au \
    --cc=venkat88@linux.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.