On 10/20/2016 02:38 AM, Markus Armbruster wrote:
>> @@ -1069,7 +1069,21 @@ int net_client_init(QemuOpts *opts, bool is_netdev,
>> Error **errp)
>> void *object = NULL;
>> Error *err = NULL;
>> int ret = -1;
>> - Visitor *v = opts_visitor_new(opts);
>> + /*
>> + * Needs autocreate_lists=true in order support existing
>> + * syntax for list options where the bare key is repeated
>> + *
>> + * Needs autocreate_struct_levels=3 in order to deal with
>> + * 3 level nesting in NetLegacy option args, which was
>> + * exposed as a flat namespace with OptVisitor
>> + */
>> + Visitor *v = qobject_input_visitor_new_opts(opts, true, 3, false, true,
>> + &err);
>> +
>> + if (err) {
>> + error_propagate(errp, err);
>> + return -1;
>> + }
>>
>> {
>> /* Parse convenience option format ip6-net=fec0::0[/64] */
>
> Neither NetLegacy nor Netdev are ABI, so if I understand the problem,
> perhaps I can find a way around it. Let's figure out what exactly
> requires levels=3.Netdev is not ABI only because we decided to NOT apply the last patch of QAPI-fying it in 2.7 while deciding to handle the back-compat (non-?)issues that existing netdev_add QMP command accepts both 1 and "1", but using the Netdev type would accept only 1. While working towards making netdev_add use QAPI, I intentionally left NetLegacy unchanged; but since NetLegacy is solely used by the command line, feel free to rearrange that type as long as CLI back-compat is kept. -- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature
