From: Pavel Hrdina <phrdina@redhat.com>
To: Kevin Wolf <kwolf@redhat.com>
Cc: Stefan Hajnoczi <stefanha@gmail.com>,
qemu-devel@nongnu.org, armbru@redhat.com,
Luiz Capitulino <lcapitulino@redhat.com>
Subject: Re: [Qemu-devel] [PATCH v2 2/2] block: move the bdrv_dev_change_media_cb()
Date: Tue, 18 Jun 2013 08:26:19 +0200 [thread overview]
Message-ID: <51BFFD8B.1060503@redhat.com> (raw)
In-Reply-To: <20130617151642.GG3994@dhcp-200-207.str.redhat.com>
On 17.6.2013 17:16, Kevin Wolf wrote:
> Am 17.06.2013 um 16:59 hat Luiz Capitulino geschrieben:
>> On Mon, 17 Jun 2013 16:49:11 +0200
>> Kevin Wolf <kwolf@redhat.com> wrote:
>>
>>> Am 17.06.2013 um 15:51 hat Luiz Capitulino geschrieben:
>>>> On Mon, 17 Jun 2013 15:46:52 +0200
>>>> Kevin Wolf <kwolf@redhat.com> wrote:
>>>>
>>>>> Am 17.06.2013 um 15:38 hat Pavel Hrdina geschrieben:
>>>>>>>>>>> It's just a warning, that you used a password for a block device that
>>>>>>>>>>> doesn't require it. The device is opened successfully and should be
>>>>>>>>>>> handled correctly (call the bdrv_dev_change_media_cb() ).
>>>>>>>>>>
>>>>>>>>>> Yep, IMO it's worth a comment that this isn't an "error" just a
>>>>>>>>>> "warning".
>>>>>>>>>
>>>>>>>>> Actually, you can't have such a warning in QMP. You either fail or you
>>>>>>>>> succeed. We should just do what the current code does.
>>>>>>>>>
>>>>>>>>
>>>>>>>> This is the same logic as the old one. The device is loaded but the
>>>>>>>> error is emitted.
>>>>>>>
>>>>>>> That's a bug if the operation succeeded.
>>>>>>>
>>>>>>
>>>>>> In that case, how do you think, that we should handle the situation
>>>>>> that user is trying to open device that isn't require the password, but
>>>>>> user will provide the password?
>>>>>>
>>>>>> I don't think that we should fail and abort that operation.
>>>>>
>>>>> I think we should. The image and the options passed for it don't fit
>>>>> together, this is an error condition. Probably the user meant to pass a
>>>>> different image.
>>>>
>>>> I agree in principle, but I fear this might be an incompatible change as
>>>> there might be clients out there assuming the VM is up and running (because
>>>> it's what ends up happening).
>>>>
>>>> Thinking about this again though, the client does get an error...
>>>
>>> Do you think any client is sending passwords for unencrypted images?
>>> Because if there is none (and I think we have reason to believe so), we
>>> don't break anything if we change the behaviour. And if something
>>> does break, we have uncovered a management tool bug, so that's not too
>>> bad either.
>>
>> Yes, I agree. I was being overly cautious when I suggested dropping the
>> error, but I think you're right: we do send an error, so a well written
>> client should just fail and shouldn't brake if we do the right thing.
>>
>> So let's do the Right Thing, but I also suggest to do this in a separate
>> commit so that it's easy to spot.
>
> Sure, I agree with one patch per logical change.
>
> Kevin
>
In that case the v3 series is ready for apply?
I will write another patch to fix this bug.
Pavel
next prev parent reply other threads:[~2013-06-18 6:26 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-05-29 16:18 [Qemu-devel] [PATCH v2 0/2] block: fix spurious DEVICE_TRAY_MOVED events on shutdown Pavel Hrdina
2013-05-29 16:18 ` [Qemu-devel] [PATCH v2 1/2] block: make bdrv_dev_change_media_cb() public Pavel Hrdina
2013-05-29 16:18 ` [Qemu-devel] [PATCH v2 2/2] block: move the bdrv_dev_change_media_cb() Pavel Hrdina
2013-06-05 13:23 ` Stefan Hajnoczi
2013-06-17 9:46 ` Pavel Hrdina
2013-06-17 12:33 ` Stefan Hajnoczi
2013-06-17 13:22 ` Luiz Capitulino
2013-06-17 13:25 ` Pavel Hrdina
2013-06-17 13:32 ` Luiz Capitulino
2013-06-17 13:38 ` Pavel Hrdina
2013-06-17 13:46 ` Luiz Capitulino
2013-06-17 13:46 ` Kevin Wolf
2013-06-17 13:51 ` Luiz Capitulino
2013-06-17 14:49 ` Kevin Wolf
2013-06-17 14:59 ` Luiz Capitulino
2013-06-17 15:16 ` Kevin Wolf
2013-06-18 6:26 ` Pavel Hrdina [this message]
2013-05-30 15:51 ` [Qemu-devel] [PATCH v2 0/2] block: fix spurious DEVICE_TRAY_MOVED events on shutdown Luiz Capitulino
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=51BFFD8B.1060503@redhat.com \
--to=phrdina@redhat.com \
--cc=armbru@redhat.com \
--cc=kwolf@redhat.com \
--cc=lcapitulino@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.