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

Re: [libvirt] [PATCH v4 1/9] conf: Add new domain XML element 'iothreadids'



...
> ....
> 
>> @@ -3298,6 +3325,21 @@ virDomainDefPostParseInternal(virDomainDefPtr def,
>>          return -1;
>>      }
>>  
>> +    /* Fully populate the IOThread ID list */
>> +    if (def->iothreads && def->iothreads != def->niothreadids) {
>> +        unsigned int iothread_id = 1;
>> +        while (def->niothreadids != def->iothreads) {
>> +            if (!virDomainIOThreadIDFind(def, iothread_id)) {
>> +                virDomainIOThreadIDDefPtr iothrid;
>> +
>> +                if (!(iothrid = virDomainIOThreadIDAdd(def, iothread_id)))
>> +                    return -1;
> 
> Unfortunately, fixing the iothread list after you parse iothread pinning
> in patch 4 makes a loophole where you might force arbitrary iothread ID
> without using <iothreadids>.
> 
> This code will probably need to be moved after the parsing code, despite
> the fact that the postparse callback is better place to do such checks.
> 
>> +                iothrid->autofill = true;
>> +            }
>> +            iothread_id++;
>> +        }
>> +    }
>> +
>>      if (virDomainDefGetMemoryInitial(def) == 0) {
>>          virReportError(VIR_ERR_XML_ERROR, "%s",
>>                         _("Memory size must be specified via <memory> or in the "
> 
> The rest of this patch looks good, but I'd like to see the above part
> fixed before my final ACK.
> 

I'll move it and post v5 for 1/9 here as well as 4/9

I haven't yet got down to 8/9

I'd like to get this in before code freeze...

Tks -

John


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