[libvirt] [PATCH 4/4] conf: Fix generating addresses for SCSI hostdev

Ján Tomko jtomko at redhat.com
Thu Jan 4 14:03:20 UTC 2018


On Thu, Jan 04, 2018 at 07:24:30AM -0500, John Ferlan wrote:
>
>Jan -
>
>ping on the question from my response to your review...
>
>On 12/20/2017 01:33 PM, John Ferlan wrote:
>>
>>
>> On 12/20/2017 07:38 AM, Ján Tomko wrote:

[...]

>>>
>>> Easier to read as:
>>> for (next_unit = -1; next_unit < -1; controller++)
>>>    next_unit = virDomainControllerSCSINextUnit(def, max_unit, controller);
>>>
>>
>> Not functionally the same comparisons... Caused
>> hostdev-scsi-autogen-address to fail... There's 11 hostdevs and only 1
>> controller. We never get controller==1 from that for loop.
>>
>> I can change @ret above to be @next_unit though
>>
>
>Is changing to use next_unit enough?

Yes.

>Or did you have some other easier
>to read loop that actually works that you'd prefer to see?
>

I do not.

Jan
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: Digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20180104/acbee971/attachment-0001.sig>


More information about the libvir-list mailing list