qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2 1/3] fdc: Drop deprecated floppy configuration


From: Markus Armbruster
Subject: Re: [PATCH v2 1/3] fdc: Drop deprecated floppy configuration
Date: Thu, 04 Mar 2021 17:23:05 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux)

Daniel P. Berrangé <berrange@redhat.com> writes:

> On Thu, Mar 04, 2021 at 03:26:55PM +0100, Markus Armbruster wrote:
>> Daniel P. Berrangé <berrange@redhat.com> writes:
>> 
>> > On Thu, Mar 04, 2021 at 11:00:57AM +0100, Markus Armbruster wrote:
>> >> Drop the crap deprecated in commit 4a27a638e7 "fdc: Deprecate
>> >> configuring floppies with -global isa-fdc" (v5.1.0).
>> >> 
>> >> Signed-off-by: Markus Armbruster <armbru@redhat.com>
>> >> ---
>> >>  docs/system/deprecated.rst       |  26 --
>> >>  docs/system/removed-features.rst |  26 ++
>> >>  hw/block/fdc.c                   |  54 +--
>> >>  tests/qemu-iotests/172           |  31 +-
>> >>  tests/qemu-iotests/172.out       | 562 +------------------------------
>> >>  5 files changed, 30 insertions(+), 669 deletions(-)
>> >> 
>> >> diff --git a/docs/system/deprecated.rst b/docs/system/deprecated.rst
>> >> index 2fcac7861e..6a22bc07e2 100644
>> >> --- a/docs/system/deprecated.rst
>> >> +++ b/docs/system/deprecated.rst
>> >> @@ -94,32 +94,6 @@ QEMU 5.1 has three options:
>> >>        to the user to load all the images they need.
>> >>   3. ``-bios <file>`` - Tells QEMU to load the specified file as the 
>> >> firmwrae.
>> >>  
>> >> -``Configuring floppies with ``-global``
>> >> -'''''''''''''''''''''''''''''''''''''''
>> >> -
>> >> -Use ``-device floppy,...`` instead:
>> >> -::
>> >> -
>> >> -    -global isa-fdc.driveA=...
>> >> -    -global sysbus-fdc.driveA=...
>> >> -    -global SUNW,fdtwo.drive=...
>> >> -
>> >> -become
>> >> -::
>> >> -
>> >> -    -device floppy,unit=0,drive=...
>> >> -
>> >> -and
>> >> -::
>> >> -
>> >> -    -global isa-fdc.driveB=...
>> >> -    -global sysbus-fdc.driveB=...
>> >> -
>> >> -become
>> >> -::
>> >> -
>> >> -    -device floppy,unit=1,drive=...
>> >> -
>> >>  ``-drive`` with bogus interface type
>> >>  ''''''''''''''''''''''''''''''''''''
>> >>  
>> >> diff --git a/docs/system/removed-features.rst 
>> >> b/docs/system/removed-features.rst
>> >> index c8481cafbd..b0e7350408 100644
>> >> --- a/docs/system/removed-features.rst
>> >> +++ b/docs/system/removed-features.rst
>> >> @@ -38,6 +38,32 @@ or ``-display default,show-cursor=on`` instead.
>> >>  QEMU 5.0 introduced an alternative syntax to specify the size of the 
>> >> translation
>> >>  block cache, ``-accel tcg,tb-size=``.
>> >>  
>> >> +``Configuring floppies with ``-global`` (removed in 6.0)
>> >> +''''''''''''''''''''''''''''''''''''''''''''''''''''''''
>> >> +
>> >> +Use ``-device floppy,...`` instead:
>> >> +::
>> >> +
>> >> +    -global isa-fdc.driveA=...
>> >> +    -global sysbus-fdc.driveA=...
>> >> +    -global SUNW,fdtwo.drive=...
>> >
>> > It looks like we're not actually removing the use of -global, rather
>> > we're removing the driveA= and driveB= properties entirely, which
>> > simply means there's nothing to be set via -global. The distinction
>> > is important, because IIUC, it means that libvirt's use of these
>> > properties via -device is also impacted eg
>> >
>> >   -device isa-fdc,driveA=drive-fdc0-0-0,bootindexA=1,driveB=drive-fdc0-0-1
>> >
>> > will no longer work too ?
>> 
>> Correct.
>> 
>> This was deprecated in commit 4a27a638e7 "fdc: Deprecate configuring
>> floppies with -global isa-fdc" (v5.1.0).  Since then, its use triggers a
>> warning:
>> 
>>     $ qemu-system-x86_64 -nodefaults -M q35 -display none -drive 
>> if=none,id=drive-fdc0-0-0 -device isa-fdc,driveA=drive-fdc0-0-0,bootindexA=1
>>     qemu-system-x86_64: -device isa-fdc,driveA=drive-fdc0-0-0,bootindexA=1: 
>> warning: warning: property isa-fdc.driveA is deprecated
>>     Use -device floppy,unit=0,drive=... instead.
>> 
>> Note the -M q35.  Needed because the default machine type has an onboard
>> isa-fdc, which cannot be configured this way.
>> 
>> Sadly, the commit's update of docs/system/deprecated.rst neglects to
>> cover this use.  Looks the series overtaxed my capacity to juggle
>> details; my apologies.
>> 
>> Is libvirt still using these properties?
>
> Unfortunately yes, but it seems like it ought to be fairly easy to
> change the syntax. Just need to figure out what the right way to
> detect the availability of the new syntax is. Presumably just look
> for existance of the 'floppy' device type ?

Yes.  The device type was added in merge commit fd209e4a7, v2.8.0.

> Can you confirm that switching from -global to the new -device floppy
> does /not/ have any live migration impact ?

Yes, it must not affect migration.

When Kevin split the floppy device type off the floppy controller, he
had to add some moderately ugly hackery to keep the old qdev properties
working.  Think propagate property values to floppy from controller,
which otherwise ignores them.

The way you get the values into the floppy device cannot affect the
migration data.  Only different values can.

This patch removes a deprecated way.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]