[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PULL 1/9] IDE: deprecate ide-drive
From: |
Paolo Bonzini |
Subject: |
Re: [PULL 1/9] IDE: deprecate ide-drive |
Date: |
Thu, 31 Oct 2019 23:02:45 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 |
On 31/10/19 11:58, John Snow wrote:
> It's an old compatibility shim that just delegates to ide-cd or ide-hd.
> I'd like to refactor these some day, and getting rid of the super-object
> will make that easier.
>
> Either way, we don't need this.
Good idea. I will prepare a similar patch for scsi-disk, even though
technically we're already in soft freeze; it makes no sense to deprecate
only one of the two.
Paolo
> Signed-off-by: John Snow <address@hidden>
> Reviewed-by: Thomas Huth <address@hidden>
> Reviewed-by: Markus Armbruster <address@hidden>
> ACKed-by: Peter Krempa <address@hidden>
> Message-id: address@hidden
> Signed-off-by: John Snow <address@hidden>
> ---
> qemu-deprecated.texi | 5 +++++
> hw/ide/qdev.c | 3 +++
> tests/qemu-iotests/051.pc.out | 6 ++++--
> 3 files changed, 12 insertions(+), 2 deletions(-)
>
> diff --git a/qemu-deprecated.texi b/qemu-deprecated.texi
> index f727bd3932..296bfc93a3 100644
> --- a/qemu-deprecated.texi
> +++ b/qemu-deprecated.texi
> @@ -254,6 +254,11 @@ quite a bit. It will be removed without replacement
> unless some users speaks
> up at the @email{qemu-devel@@nongnu.org} mailing list with information about
> their usecases.
>
> +@subsection ide-drive (since 4.2)
> +
> +The 'ide-drive' device is deprecated. Users should use 'ide-hd' or
> +'ide-cd' as appropriate to get an IDE hard disk or CD-ROM as needed.
> +
> @section System emulator machines
>
> @subsection pc-0.12, pc-0.13, pc-0.14 and pc-0.15 (since 4.0)
> diff --git a/hw/ide/qdev.c b/hw/ide/qdev.c
> index 6fba6b62b8..3666e59721 100644
> --- a/hw/ide/qdev.c
> +++ b/hw/ide/qdev.c
> @@ -279,6 +279,9 @@ static void ide_drive_realize(IDEDevice *dev, Error
> **errp)
> {
> DriveInfo *dinfo = NULL;
>
> + warn_report("'ide-drive' is deprecated, "
> + "please use 'ide-hd' or 'ide-cd' instead");
> +
> if (dev->conf.blk) {
> dinfo = blk_legacy_dinfo(dev->conf.blk);
> }
> diff --git a/tests/qemu-iotests/051.pc.out b/tests/qemu-iotests/051.pc.out
> index 000557c7c8..34849dd172 100644
> --- a/tests/qemu-iotests/051.pc.out
> +++ b/tests/qemu-iotests/051.pc.out
> @@ -158,7 +158,8 @@ QEMU X.Y.Z monitor - type 'help' for more information
>
> Testing: -drive if=none,id=disk -device ide-drive,drive=disk
> QEMU X.Y.Z monitor - type 'help' for more information
> -(qemu) QEMU_PROG: -device ide-drive,drive=disk: Device needs media, but
> drive is empty
> +(qemu) QEMU_PROG: -device ide-drive,drive=disk: warning: 'ide-drive' is
> deprecated, please use 'ide-hd' or 'ide-cd' instead
> +QEMU_PROG: -device ide-drive,drive=disk: Device needs media, but drive is
> empty
>
> Testing: -drive if=none,id=disk -device ide-hd,drive=disk
> QEMU X.Y.Z monitor - type 'help' for more information
> @@ -228,7 +229,8 @@ QEMU X.Y.Z monitor - type 'help' for more information
>
> Testing: -drive file=TEST_DIR/t.qcow2,if=none,id=disk,readonly=on -device
> ide-drive,drive=disk
> QEMU X.Y.Z monitor - type 'help' for more information
> -(qemu) QEMU_PROG: -device ide-drive,drive=disk: Block node is read-only
> +(qemu) QEMU_PROG: -device ide-drive,drive=disk: warning: 'ide-drive' is
> deprecated, please use 'ide-hd' or 'ide-cd' instead
> +QEMU_PROG: -device ide-drive,drive=disk: Block node is read-only
>
> Testing: -drive file=TEST_DIR/t.qcow2,if=none,id=disk,readonly=on -device
> ide-hd,drive=disk
> QEMU X.Y.Z monitor - type 'help' for more information
>
- [PULL 0/9] Ide patches, John Snow, 2019/10/31
- [PULL 1/9] IDE: deprecate ide-drive, John Snow, 2019/10/31
- Re: [PULL 1/9] IDE: deprecate ide-drive,
Paolo Bonzini <=
- [PULL 2/9] block: Refactor macros - fix tabbing, John Snow, 2019/10/31
- [PULL 3/9] block: Support providing LCHS from user, John Snow, 2019/10/31
- [PULL 4/9] bootdevice: Add interface to gather LCHS, John Snow, 2019/10/31
- [PULL 5/9] scsi: Propagate unrealize() callback to scsi-hd, John Snow, 2019/10/31
- [PULL 6/9] bootdevice: Gather LCHS from all relevant devices, John Snow, 2019/10/31
- [PULL 7/9] bootdevice: Refactor get_boot_devices_list, John Snow, 2019/10/31
- [PULL 8/9] bootdevice: FW_CFG interface for LCHS values, John Snow, 2019/10/31
- [PULL 9/9] hd-geo-test: Add tests for lchs override, John Snow, 2019/10/31
- Re: [libvirt] [PULL 0/9] Ide patches, no-reply, 2019/10/31
- Re: [PULL 0/9] Ide patches, Peter Maydell, 2019/10/31