qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Eduardo Otubo <otubo@redhat.com>
To: Thomas Huth <thuth@redhat.com>
Cc: ehabkost@redhat.com, armbru@redhat.com, mjt@tls.msk.ru,
	agraf@suse.de, qemu-devel@nongnu.org, pbonzini@redhat.com
Subject: Re: [Qemu-devel] [PATCHv3] dma/i82374: avoid double creation of i82374 device
Date: Fri, 23 Mar 2018 12:04:10 +0100	[thread overview]
Message-ID: <20180323110410.GB11563@vader> (raw)
In-Reply-To: <a04427bc-3f63-9eda-dfcb-2702c4e7efcd@redhat.com>

On 16/03/2018 - 11:46:57, Thomas Huth wrote:
> On 27.11.2017 09:40, Eduardo Otubo wrote:
> > On Fri, Nov 24, 2017 at 06:44:59PM +0100, Thomas Huth wrote:
> >>  Hi Eduardo,
> >>
> >> On 24.11.2017 14:46, Eduardo Otubo wrote:
> >>> v3:
> >>>  * Removed all unecessary local_err
> >>>  * Change return of isa_bus_dma() and DMA_init() from void to int8_t,
> >>>    returning -EBUSY on error and 0 on success
> >>>  * Added qdev_cleanup_nofail() in case isa_bus_dma() returns error. The
> >>>    cleanup looks safe, but please review if I didn't miss any detail
> >>>
> >>> v2:
> >>>  * Removed user_creatable=false and replaced by error handling using
> >>>    Error **errp and error_propagate();
> >>
> >> Version changelog should go below the "---" separator, otherwise it will
> >> be included in the git changelog as well, which is kind of ugly.
> >>
> >>> QEMU fails when used with the following command line:
> >>>
> >>>     ./ppc64-softmmu/qemu-system-ppc64 -S -machine 40p,accel=tcg -device i82374
> >>>     qemu-system-ppc64: hw/isa/isa-bus.c:110: isa_bus_dma: Assertion `!bus->dma[0] && !bus->dma[1]' failed.
> >>>     Aborted (core dumped)
> >>>
> >>> The 40p machine type already created the device i82374. If specified in the
> >>> command line, it will try to create it again, hence generating the error. The
> >>> function isa_bus_dma() isn't supposed to be called twice for the same bus. One
> >>> way to avoid this problem is to set user_creatable=false.
> >>
> >> You don't do that user_creatable=false here anymore, so please remove it
> >> from the description.
> >>
> >>> A possible fix in a near future would be making
> >>> isa_bus_dma()/DMA_init()/i82374_realize() return an error instead of asserting
> >>> as well.
> >>
> >> You should rephrase that sentence as well.
> >>
> > 
> > Well, I think one mistake lead to another here. I've always put the changelog
> > before the --- and that's why the old commit message. For example:
> > 2f668be77501c0232a84aafb6a066c9915987f0e. But I guess on that context it made
> > sense to use the changelog since the commit message was too simplistic. I'm
> > gonna fix this on the v3 then, among other thigs that I need to fix. Thanks for
> > the heads up :)
> 
>  Hi,
> 
> did you ever send a v4? The problem seems still to persist...
> 

I didn't, I guess I put this on the bottom of my priority list and never got to
it.

I'll send a new version right away.
Thanks for the reminder.

-- 
Eduardo Otubo

      reply	other threads:[~2018-03-23 11:04 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-24 13:46 [Qemu-devel] [PATCHv3] dma/i82374: avoid double creation of i82374 device Eduardo Otubo
2017-11-24 13:56 ` no-reply
2017-11-24 13:56 ` no-reply
2017-11-24 14:40 ` no-reply
2017-11-24 17:44 ` Thomas Huth
2017-11-27  8:40   ` Eduardo Otubo
2018-03-16 10:46     ` Thomas Huth
2018-03-23 11:04       ` Eduardo Otubo [this message]

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=20180323110410.GB11563@vader \
    --to=otubo@redhat.com \
    --cc=agraf@suse.de \
    --cc=armbru@redhat.com \
    --cc=ehabkost@redhat.com \
    --cc=mjt@tls.msk.ru \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@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).