[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-block] [RFC PATCH 05/10] block: Add 'keep_old_opts' parameter
From: |
Kevin Wolf |
Subject: |
Re: [Qemu-block] [RFC PATCH 05/10] block: Add 'keep_old_opts' parameter to bdrv_reopen_queue() |
Date: |
Mon, 18 Jun 2018 18:15:46 +0200 |
User-agent: |
Mutt/1.9.1 (2017-09-22) |
Am 18.06.2018 um 17:28 hat Alberto Garcia geschrieben:
> On Mon 18 Jun 2018 04:15:07 PM CEST, Kevin Wolf wrote:
>
> >> @@ -2850,7 +2850,8 @@ static BlockReopenQueue
> >> *bdrv_reopen_queue_child(BlockReopenQueue *bs_queue,
> >> int flags,
> >> const BdrvChildRole
> >> *role,
> >> QDict *parent_options,
> >> - int parent_flags)
> >> + int parent_flags,
> >> + bool keep_old_opts)
> >
> > Can we change the semantics of keep_old_opts so that flags is completely
> > ignored for keep_old_opts=false?
> >
> > Flags are one of the reasons why the behaviour of bdrv_reopen() is
> > rather complex and I'd prefer not having that complexity in a public
> > interface. To be honest, I wouldn't be sure that I could write a
> > correct documentation with it.
>
> I think so. In this series if keep_old_opts is false the only possible
> flags are either 0 or BDRV_O_RDWR | BDRV_O_ALLOW_RDWR, depending on the
> value of "read-only" option.
I assume the default options that you have to set in
qmp_x_blockdev_reopen() are only because update_options_from_flags()
would break things otherwise. So if we get rid of the latter, maybe we
can simplify qmp_x_blockdev_reopen(), too.
Well, or maybe my assumption is just wrong, of course.
KEvin
- [Qemu-block] [RFC PATCH 00/10] Add a 'x-blockdev-reopen' QMP command, Alberto Garcia, 2018/06/14
- [Qemu-block] [RFC PATCH 02/10] block: Allow changing 'discard' on reopen, Alberto Garcia, 2018/06/14
- [Qemu-block] [RFC PATCH 03/10] block: Allow changing 'detect-zeroes' on reopen, Alberto Garcia, 2018/06/14
- [Qemu-block] [RFC PATCH 01/10] file-posix: Forbid trying to change unsupported options during reopen, Alberto Garcia, 2018/06/14
- [Qemu-block] [RFC PATCH 08/10] block: Add bdrv_reset_options_allowed(), Alberto Garcia, 2018/06/14
- [Qemu-block] [RFC PATCH 04/10] block: Allow changing 'force-share' on reopen, Alberto Garcia, 2018/06/14
- [Qemu-block] [RFC PATCH 05/10] block: Add 'keep_old_opts' parameter to bdrv_reopen_queue(), Alberto Garcia, 2018/06/14
- [Qemu-block] [RFC PATCH 06/10] block: Allow changing the backing file on reopen, Alberto Garcia, 2018/06/14
- Re: [Qemu-block] [RFC PATCH 06/10] block: Allow changing the backing file on reopen, Kevin Wolf, 2018/06/18
- Re: [Qemu-block] [RFC PATCH 06/10] block: Allow changing the backing file on reopen, Alberto Garcia, 2018/06/18
- Re: [Qemu-block] [RFC PATCH 06/10] block: Allow changing the backing file on reopen, Kevin Wolf, 2018/06/18
- Re: [Qemu-block] [RFC PATCH 06/10] block: Allow changing the backing file on reopen, Alberto Garcia, 2018/06/19
- Re: [Qemu-block] [RFC PATCH 06/10] block: Allow changing the backing file on reopen, Kevin Wolf, 2018/06/19
- Re: [Qemu-block] [RFC PATCH 06/10] block: Allow changing the backing file on reopen, Alberto Garcia, 2018/06/19
- Re: [Qemu-block] [RFC PATCH 06/10] block: Allow changing the backing file on reopen, Kevin Wolf, 2018/06/20
- Re: [Qemu-block] [RFC PATCH 06/10] block: Allow changing the backing file on reopen, Alberto Garcia, 2018/06/20
- Re: [Qemu-block] [RFC PATCH 06/10] block: Allow changing the backing file on reopen, Kevin Wolf, 2018/06/21