On 03/25/13 21:34, Laine Stump wrote:
On 03/15/2013 11:26 AM, Peter Krempa wrote:
> This patch implements the devices post parse cllback and uses it to fill
> the default qemu network card model into the XML if none is specified.
>
> Libvirt assumes that the network card model for qemu is the "rtl8139".
> Record this in the XML using the new callback to avoid user
> confusion.
As I recall (from a previous Fedora-specific patch I had to make that
forced all "fedora-13" machinetypes in configs to be changed to
"pc-0.14"), just causing the parser to fill this in will not cause the
default value to actually be written to the config files. So when we get
to the point where we want to change the default, we won't have actually
addressed the issue of making sure that existing configs continue to use
rtl8139 rather than abruptly changing the guest's hardware at next boot
(or when migrated to another host).
This isn't an issue in this case. The default is and always was to use
the realtek card. We can't change that unfortunately for anything better
:(. This is just to notify the user what is the actual model we are
using in this case so I think it isn't that important to rewrite the XML
file.
In case it's missing in the config, it will be always parsed to the
default value and when the config will be saved in the future it will be
written. But the value will still be used.
If we want to assure that existing guests have their default netdev
model written to config, we'll need to actually force the config to be
rewritten to disk. Take a look at the patch named
I don't think this is really needed, but I will have a look if this is
feasible in this case.
libvirt-qemu-replace-deprecated-fedora-13-machine.patch
in fedora-git's f16 branch for libvirt to see what I'm talking about.
It's really quite ugly :-(
Peter