public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Nathan Chancellor <nathan@kernel.org>
To: Alexander Gordeev <agordeev@linux.ibm.com>
Cc: Heiko Carstens <hca@linux.ibm.com>,
	Vasily Gorbik <gor@linux.ibm.com>,
	Christian Borntraeger <borntraeger@linux.ibm.com>,
	Sven Schnelle <svens@linux.ibm.com>,
	linux-s390@vger.kernel.org, linux-kernel@vger.kernel.org,
	stable@vger.kernel.org
Subject: Re: [PATCH] s390: Add '-std=gnu11' to decompressor and purgatory CFLAGS
Date: Mon, 27 Jan 2025 14:09:36 -0700	[thread overview]
Message-ID: <20250127210936.GA3733@ax162> (raw)
In-Reply-To: <Z5IcqJbvLhMGQmUw@li-008a6a4c-3549-11b2-a85c-c5cc2836eea2.ibm.com>

On Thu, Jan 23, 2025 at 11:40:40AM +0100, Alexander Gordeev wrote:
> On Wed, Jan 22, 2025 at 07:54:27PM -0700, Nathan Chancellor wrote:
> > GCC changed the default C standard dialect from gnu17 to gnu23,
> > which should not have impacted the kernel because it explicitly requests
> > the gnu11 standard in the main Makefile. However, there are certain
> > places in the s390 code that use their own CFLAGS without a '-std='
> > value, which break with this dialect change because of the kernel's own
> > definitions of bool, false, and true conflicting with the C23 reserved
> > keywords.
> > 
> >   include/linux/stddef.h:11:9: error: cannot use keyword 'false' as enumeration constant
> >      11 |         false   = 0,
> >         |         ^~~~~
> >   include/linux/stddef.h:11:9: note: 'false' is a keyword with '-std=c23' onwards
> >   include/linux/types.h:35:33: error: 'bool' cannot be defined via 'typedef'
> >      35 | typedef _Bool                   bool;
> >         |                                 ^~~~
> >   include/linux/types.h:35:33: note: 'bool' is a keyword with '-std=c23' onwards
> > 
> > Add '-std=gnu11' to the decompressor and purgatory CFLAGS to eliminate
> > these errors and make the C standard version of these areas match the
> > rest of the kernel.
> > 
> > Cc: stable@vger.kernel.org
> > Signed-off-by: Nathan Chancellor <nathan@kernel.org>
> ...
> > ---
> >  arch/s390/Makefile           | 2 +-
> >  arch/s390/purgatory/Makefile | 2 +-
> >  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> Applied, thanks!

I noticed that a Fixes tag got added to this change in the s390 tree but
I do not think it is correct, as I would expect this issue to be visible
prior to that change. I think this will need to go back to all supported
stable versions to allow building with GCC 15. It seems like maybe the
tags from the parent commit (0a89123deec3) made it into my change?

Cheers,
Nathan

  reply	other threads:[~2025-01-27 21:09 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-23  2:54 [PATCH] s390: Add '-std=gnu11' to decompressor and purgatory CFLAGS Nathan Chancellor
2025-01-23  8:29 ` Heiko Carstens
2025-01-23 10:40 ` Alexander Gordeev
2025-01-27 21:09   ` Nathan Chancellor [this message]
2025-01-28  7:53     ` Heiko Carstens
2025-01-28  8:25       ` Alexander Gordeev
2025-01-29  0:16         ` Nathan Chancellor

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=20250127210936.GA3733@ax162 \
    --to=nathan@kernel.org \
    --cc=agordeev@linux.ibm.com \
    --cc=borntraeger@linux.ibm.com \
    --cc=gor@linux.ibm.com \
    --cc=hca@linux.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-s390@vger.kernel.org \
    --cc=stable@vger.kernel.org \
    --cc=svens@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox