From: "Philippe Mathieu-Daudé" <philmd@redhat.com>
To: Thomas Huth <thuth@redhat.com>, Cornelia Huck <cohuck@redhat.com>
Cc: Christian Borntraeger <borntraeger@de.ibm.com>,
qemu-s390x@nongnu.org, qemu-devel@nongnu.org
Subject: Re: [PATCH 3/4] pc-bios/s390-ccw: Silence GCC 11 stringop-overflow warning
Date: Mon, 3 May 2021 11:50:39 +0200 [thread overview]
Message-ID: <c0169589-5811-8dc5-5e5b-4580927dc90b@redhat.com> (raw)
In-Reply-To: <000ea451-915f-13d1-aebe-48eeb80277db@redhat.com>
On 5/3/21 11:31 AM, Thomas Huth wrote:
> On 03/05/2021 11.30, Philippe Mathieu-Daudé wrote:
>> On 5/3/21 11:00 AM, Cornelia Huck wrote:
>>> On Sun, 2 May 2021 19:48:35 +0200
>>> Thomas Huth <thuth@redhat.com> wrote:
>>>
>>>> From: Philippe Mathieu-Daudé <philmd@redhat.com>
>>>>
>>>> When building on Fedora 34 (gcc version 11.0.0 20210210) we get:
>>>>
>>>> In file included from pc-bios/s390-ccw/main.c:11:
>>>> In function ‘memset’,
>>>> inlined from ‘boot_setup’ at pc-bios/s390-ccw/main.c:185:5,
>>>> inlined from ‘main’ at pc-bios/s390-ccw/main.c:288:5:
>>>> pc-bios/s390-ccw/libc.h:28:14: warning: writing 1 byte into a
>>>> region of size 0 [-Wstringop-overflow=]
>>>> 28 | p[i] = c;
>>>> | ~~~~~^~~
>>>>
>>>> The offending code is:
>>>>
>>>> memset((char *)S390EP, 0, 6);
>>>>
>>>> where S390EP is a const address:
>>>>
>>>> #define S390EP 0x10008
>>>>
>>>> The compiler doesn't now how big that pointed area is, so assume its
>>>
>>> s/now/know/
>>> s/assume/it assumes that/
>>
>> Oops, thanks. Thomas, do you want me to repost this patch fixed?
>
> I can fix it up in my tree here, no need to resend.
Great, thank you!
Phil.
next prev parent reply other threads:[~2021-05-03 9:51 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-02 17:48 [PATCH 0/4] pc-bios/s390-ccw: Allow building with Clang, too Thomas Huth
2021-05-02 17:48 ` [PATCH 1/4] pc-bios/s390-ccw: Silence warning from Clang by marking panic() as noreturn Thomas Huth
2021-05-02 18:57 ` Philippe Mathieu-Daudé
2021-05-03 4:53 ` Thomas Huth
2021-05-03 7:40 ` Philippe Mathieu-Daudé
2021-05-03 4:56 ` Markus Armbruster
2021-05-03 8:54 ` Cornelia Huck
2021-05-02 17:48 ` [PATCH 2/4] pc-bios/s390-ccw: Fix the cc-option macro in the Makefile Thomas Huth
2021-05-02 17:48 ` [PATCH 3/4] pc-bios/s390-ccw: Silence GCC 11 stringop-overflow warning Thomas Huth
2021-05-03 9:00 ` Cornelia Huck
2021-05-03 9:30 ` Philippe Mathieu-Daudé
2021-05-03 9:31 ` Thomas Huth
2021-05-03 9:50 ` Philippe Mathieu-Daudé [this message]
2021-05-02 17:48 ` [PATCH 4/4] pc-bios/s390-ccw: Allow building with Clang, too Thomas Huth
2021-05-02 19:00 ` Philippe Mathieu-Daudé
2021-05-03 4:58 ` Markus Armbruster
2021-05-03 5:17 ` Thomas Huth
2021-05-03 8:10 ` David Hildenbrand
2021-05-03 8:23 ` Markus Armbruster
2021-05-03 9:14 ` Cornelia Huck
2021-05-03 9:17 ` David Hildenbrand
2021-05-03 9:23 ` Cornelia Huck
2021-05-03 9:31 ` Thomas Huth
2021-05-03 9:56 ` Cornelia Huck
2021-05-03 10:10 ` Christian Borntraeger
2021-05-03 10:00 ` Cornelia Huck
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=c0169589-5811-8dc5-5e5b-4580927dc90b@redhat.com \
--to=philmd@redhat.com \
--cc=borntraeger@de.ibm.com \
--cc=cohuck@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-s390x@nongnu.org \
--cc=thuth@redhat.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;
as well as URLs for NNTP newsgroup(s).