Re: [PATCH] libxl config file convertion: correct `type=netfront' to 'type=vif'

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

 



On 04/08/2016 08:26 AM, Chunyan Liu wrote:
> According to current xl.cfg docs and xl codes, it uses type=vif
> instead of type=netfront.
> 
> Currently after domxml-to-native, libvirt xml model=netfront will be
> converted to xl type=netfront. This has no problem before, xen codes
> for a long time just check type=ioemu, if not, set type to _VIF.
> 
> Since libxl uses parse_nic_config to avoid duplicate codes, it
> compares 'type=vif' and 'type=ioemu' for valid parameters, others
> are considered as invalid, thus we have problem with type=netfront
> in xl config file.
>  #xl create sles12gm-hvm.orig
>  Parsing config from sles12gm-hvm.orig
>  Invalid parameter `type'.
> 
> Correct the convertion in libvirt, so that it matchs libxl codes
> and also xl.cfg.
> 
> Signed-off-by: Chunyan Liu <cyliu@xxxxxxxx>
> ---
> Since type=netfront config has been used for a very long time, at
> lease for xm/xend, it has no problem. I'm not sure if we need to
> split into xenParseXLVif vs xenParseXMVif, and xenFormatXLVif vs
> xenFormatXMVif for this change?
> 
Hm, although looking at xend code (xen 4.4, 4.3) it seems that only type=ioemu
is tested against too, which means the patch as is looks good and XM would
accept "vif" same as the previous netfront". Though splitting that into two
functions as you suggest would perhaps be "safer" as the behavior is no longer
kept the same across XM and XL -  but may be that isn't a concern.

Joao

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



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]