[libvirt] [PATCH 0/3] Remove deprecated pc-0.x machine types and related hacks

Thomas Huth posted 3 patches 4 years, 3 months ago
Failed in applying to current master (apply log)
There is a newer version of this series
hw/audio/ac97.c       |  9 -----
hw/i386/pc_piix.c     | 82 -------------------------------------------
hw/pci/pci.c          |  6 +---
include/hw/pci/pci.h  |  3 --
qemu-deprecated.texi  |  2 +-
tests/cpu-plug-test.c |  6 +---
6 files changed, 3 insertions(+), 105 deletions(-)
[libvirt] [PATCH 0/3] Remove deprecated pc-0.x machine types and related hacks
Posted by Thomas Huth 4 years, 3 months ago
These have been on the deprecation list since a year now, so it's
time to finally remove the pc-0.x machine types.

We then can also remove some compatibility hacks in the devices, i.e.
the "use_broken_id" in ac97 and "command_serr_enable" in PCI devices.

Note that there is also the "rombar" property of the PCI devices which
is now not required for the x86 machine types anymore. But it seems to
me like this is still used by various people to bypass the ROM loading
for PCI devices in certain cases, so I did not remove that property here
yet.

Thomas Huth (3):
  hw/i386: Remove the deprecated machines 0.12 up to 0.15
  hw/audio: Remove the "use_broken_id" hack from the AC97 device
  hw/pci: Remove the "command_serr_enable" property

 hw/audio/ac97.c       |  9 -----
 hw/i386/pc_piix.c     | 82 -------------------------------------------
 hw/pci/pci.c          |  6 +---
 include/hw/pci/pci.h  |  3 --
 qemu-deprecated.texi  |  2 +-
 tests/cpu-plug-test.c |  6 +---
 6 files changed, 3 insertions(+), 105 deletions(-)

-- 
2.18.1

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] [PATCH 0/3] Remove deprecated pc-0.x machine types and related hacks
Posted by Markus Armbruster 4 years, 3 months ago
Thomas Huth <thuth@redhat.com> writes:

> These have been on the deprecation list since a year now, so it's
> time to finally remove the pc-0.x machine types.
>
> We then can also remove some compatibility hacks in the devices, i.e.
> the "use_broken_id" in ac97 and "command_serr_enable" in PCI devices.
>
> Note that there is also the "rombar" property of the PCI devices which
> is now not required for the x86 machine types anymore. But it seems to
> me like this is still used by various people to bypass the ROM loading
> for PCI devices in certain cases, so I did not remove that property here
> yet.

With this series applied:

$ git-grep pc-0
hw/display/vga-pci.c:        /* compatibility with pc-0.13 and older */
hw/display/vga.c:    /* With pc-0.12 and below we map both the PCI BAR and the fixed VBE region,
hw/display/vmware_vga.c:        /* compatibility with pc-0.13 and older */
hw/i386/pc_piix.c:/* PC compat function

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] [PATCH 0/3] Remove deprecated pc-0.x machine types and related hacks
Posted by Thomas Huth 4 years, 3 months ago
On 06/12/2019 07.49, Markus Armbruster wrote:
> Thomas Huth <thuth@redhat.com> writes:
> 
>> These have been on the deprecation list since a year now, so it's
>> time to finally remove the pc-0.x machine types.
>>
>> We then can also remove some compatibility hacks in the devices, i.e.
>> the "use_broken_id" in ac97 and "command_serr_enable" in PCI devices.
>>
>> Note that there is also the "rombar" property of the PCI devices which
>> is now not required for the x86 machine types anymore. But it seems to
>> me like this is still used by various people to bypass the ROM loading
>> for PCI devices in certain cases, so I did not remove that property here
>> yet.
> 
> With this series applied:
> 
> $ git-grep pc-0
> hw/display/vga-pci.c:        /* compatibility with pc-0.13 and older */
> hw/display/vga.c:    /* With pc-0.12 and below we map both the PCI BAR and the fixed VBE region,
> hw/display/vmware_vga.c:        /* compatibility with pc-0.13 and older */

These are the "rombar" hacks that I've mentioned above. The question is
whether we want to remove them or whether I should just adjust the comments?

> hw/i386/pc_piix.c:/* PC compat function

Right, the comment still needs to be adjusted.

 Thomas

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] [PATCH 0/3] Remove deprecated pc-0.x machine types and related hacks
Posted by Gerd Hoffmann 4 years, 3 months ago
> > $ git-grep pc-0
> > hw/display/vga-pci.c:        /* compatibility with pc-0.13 and older */
> > hw/display/vga.c:    /* With pc-0.12 and below we map both the PCI BAR and the fixed VBE region,
> > hw/display/vmware_vga.c:        /* compatibility with pc-0.13 and older */
> 
> These are the "rombar" hacks that I've mentioned above. The question is
> whether we want to remove them or whether I should just adjust the comments?

Hmm.  All that cruft ...

vga maps the framebuffer @ 0xe0000000 with rombar=off. It's an alias of
the pci memory bar.  rombar=off is basically a flag for "really old
firmware" here, vgabios used to have that address hardcoded, a decade
ago.  We fixed that roughly the same timeframe where we switched to
seabios, which in turn allowed us to place the vgabios in the pci rom
bar (instead of copying it to 0xa000 in guest ram).  Which is probably
the reason why we have only one switch for both.

I don't expect anyone actually sets the rombar property for vga devices
(it's more common for NICs, for network boot tweaks), so I guess we can
get away with simply dropping the hacks in vga-pci.c and vmware_vga.c.
The comment in vga.c is not fully correct though, isa-vga needs that
too, so we have to keep vga_init_vbe for the time being ...

cheers,
  Gerd

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list