From: Thomas Huth <thuth@redhat.com>
To: Peter Maydell <peter.maydell@linaro.org>,
Michael Tokarev <mjt@tls.msk.ru>
Cc: QEMU Developers <qemu-devel@nongnu.org>,
QEMU Trivial <qemu-trivial@nongnu.org>,
KONRAD Frederic <fred.konrad@greensocs.com>
Subject: Re: [Qemu-devel] [PULL 7/7] hw/misc/mmio_interface: Return after error_setg() to avoid crash
Date: Mon, 14 Aug 2017 13:52:53 +0200 [thread overview]
Message-ID: <ff54b90d-9912-ce03-31cf-9fd08571eab2@redhat.com> (raw)
In-Reply-To: <CAFEAcA-Jac8wFzQ9vRyKjcEwDKYBdXysNyDP7ERFfXFhVcF56w@mail.gmail.com>
On 14.08.2017 13:45, Peter Maydell wrote:
> On 14 August 2017 at 12:07, Michael Tokarev <mjt@tls.msk.ru> wrote:
>> From: Thomas Huth <thuth@redhat.com>
>>
>> QEMU currently abort()s if the user tries to specify the mmio_interface
>> device without parameters:
>>
>> x86_64-softmmu/qemu-system-x86_64 -nographic -device mmio_interface
>> qemu-system-x86_64: /home/thuth/devel/qemu/util/error.c:57: error_setv:
>> Assertion `*errp == ((void *)0)' failed.
>> Aborted (core dumped)
>>
>> This happens because the realize function is trying to set the errp
>> twice in this case. After setting an error, the realize function
>> should immediately return instead.
>
> It seems like it should be an error to permit this to be
> created from the command line at all
That's also what thought first ... but the commit message of commit
7cc2298c46a6afa4f4ff7e5cd262809c782d701b says that it "can be
hotplugged/hotunplugged" ? ... that's confusing ...
Frederic, I think some more comments in the header of the file would be
really useful here.
Thomas
next prev parent reply other threads:[~2017-08-14 11:53 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-08-14 11:07 [Qemu-devel] [PULL 0/7] Trivial patches for 2017-08-14 Michael Tokarev
2017-08-14 11:07 ` [Qemu-devel] [PULL 1/7] unicore32: abort when entering "x 0" on the monitor Michael Tokarev
2017-08-14 11:07 ` [Qemu-devel] [PULL 2/7] libqtest: Fix typo in comments Michael Tokarev
2017-08-14 11:07 ` [Qemu-devel] [PULL 3/7] qemu-doc: Fix "-net van" typo Michael Tokarev
2017-08-14 11:07 ` [Qemu-devel] [PULL 4/7] qemu-iotests: get rid of _full_imgproto_details() Michael Tokarev
2017-08-14 11:07 ` [Qemu-devel] [PULL 5/7] qemu-iotests: remove commented out variables Michael Tokarev
2017-08-14 11:07 ` [Qemu-devel] [PULL 6/7] qemu-iotests: remove comment about root privileges requirement Michael Tokarev
2017-08-14 11:07 ` [Qemu-devel] [PULL 7/7] hw/misc/mmio_interface: Return after error_setg() to avoid crash Michael Tokarev
2017-08-14 11:45 ` Peter Maydell
2017-08-14 11:52 ` Thomas Huth [this message]
2017-08-14 11:55 ` Peter Maydell
2017-08-17 12:40 ` KONRAD Frederic
2017-08-14 13:11 ` Igor Mammedov
2017-08-14 12:35 ` [Qemu-devel] [PULL 0/7] Trivial patches for 2017-08-14 Peter Maydell
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=ff54b90d-9912-ce03-31cf-9fd08571eab2@redhat.com \
--to=thuth@redhat.com \
--cc=fred.konrad@greensocs.com \
--cc=mjt@tls.msk.ru \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=qemu-trivial@nongnu.org \
/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).