From: Nathan Chancellor <nathan@kernel.org>
To: Alexander Gordeev <agordeev@linux.ibm.com>
Cc: akpm@linux-foundation.org, hca@linux.ibm.com, gor@linux.ibm.com,
borntraeger@linux.ibm.com, svens@linux.ibm.com,
linux-s390@vger.kernel.org, patches@lists.linux.dev
Subject: Re: [PATCH 2/2] s390/traps: Only define is_valid_bugaddr() under CONFIG_GENERIC_BUG
Date: Mon, 4 Dec 2023 09:38:49 -0700 [thread overview]
Message-ID: <20231204163849.GA7186@dev-arch.thelio-3990X> (raw)
In-Reply-To: <ZW2Wo6xlXU47HrSF@li-008a6a4c-3549-11b2-a85c-c5cc2836eea2.ibm.com>
On Mon, Dec 04, 2023 at 10:06:43AM +0100, Alexander Gordeev wrote:
> On Thu, Nov 30, 2023 at 05:22:33PM -0700, Nathan Chancellor wrote:
>
> Hi Nathan,
>
> > When building with -Wmissing-prototypes without CONFIG_GENERIC_BUG,
> > there is a warning about a missing prototype for is_valid_bugaddr():
> >
> > arch/s390/kernel/traps.c:46:5: warning: no previous prototype for 'is_valid_bugaddr' [-Wmissing-prototypes]
> > 46 | int is_valid_bugaddr(unsigned long addr)
> > | ^~~~~~~~~~~~~~~~
> >
> > The prototype is only declared with CONFIG_GENERIC_BUG, so only define
> > the function under the same condition to clear up the warning, which
> > matches other architectures.
>
> Thanks for the fix!
> The patch is fine, although I have not been able to reproduce the warning.
> How did you trigger it?
Thanks for taking a look! I am able to trigger this on v6.7-rc4 with:
# Flip off CONFIG_BUG in menuconfig
$ make -skj"$(nproc)" ARCH=s390 CROSS_COMPILE=s390-linux- KCFLAGS=-Wmissing-prototypes defconfig menuconfig arch/s390/kernel/traps.o
arch/s390/kernel/traps.c:46:5: warning: no previous prototype for 'is_valid_bugaddr' [-Wmissing-prototypes]
46 | int is_valid_bugaddr(unsigned long addr)
| ^~~~~~~~~~~~~~~~
I initially found this by testing just the tinyconfig target.
> > Signed-off-by: Nathan Chancellor <nathan@kernel.org>
> > ---
> > arch/s390/kernel/traps.c | 2 ++
> > 1 file changed, 2 insertions(+)
> ...
>
> Thanks!
next prev parent reply other threads:[~2023-12-04 16:38 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-01 0:22 [PATCH 0/2] s390: A couple of fixes for -Wmissing-prototypes Nathan Chancellor
2023-12-01 0:22 ` [PATCH 1/2] s390/dasd: Remove dasd_stats_generic_show() Nathan Chancellor
2023-12-04 7:41 ` Alexander Gordeev
2023-12-04 13:13 ` Stefan Haberland
2023-12-01 0:22 ` [PATCH 2/2] s390/traps: Only define is_valid_bugaddr() under CONFIG_GENERIC_BUG Nathan Chancellor
2023-12-04 9:06 ` Alexander Gordeev
2023-12-04 16:38 ` Nathan Chancellor [this message]
2023-12-05 12:59 ` Alexander Gordeev
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=20231204163849.GA7186@dev-arch.thelio-3990X \
--to=nathan@kernel.org \
--cc=agordeev@linux.ibm.com \
--cc=akpm@linux-foundation.org \
--cc=borntraeger@linux.ibm.com \
--cc=gor@linux.ibm.com \
--cc=hca@linux.ibm.com \
--cc=linux-s390@vger.kernel.org \
--cc=patches@lists.linux.dev \
--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