]> git.ipfire.org Git - thirdparty/libvirt.git/commit
conf: Fix generating addresses for SCSI hostdev
authorJohn Ferlan <jferlan@redhat.com>
Tue, 5 Dec 2017 16:36:01 +0000 (11:36 -0500)
committerJohn Ferlan <jferlan@redhat.com>
Thu, 4 Jan 2018 15:30:43 +0000 (10:30 -0500)
commit8d424f1b23b95c25655dae446a7a62df7b42cfcb
tree6391ddbf975effd9d57571a0f50785419735c2c8
parentc52dbafe9faf89c38b49188ce994198b36c3aa1e
conf: Fix generating addresses for SCSI hostdev

https://bugzilla.redhat.com/show_bug.cgi?id=1519130

Commit id 'dc692438' reverted the automagic addition of a SCSI
controller attempt during virDomainHostdevAssignAddress; however,
the logic to determine where to place the next_unit depended upon
the "new" controller being added.  Without the new controller the
the next time through the call for the next SCSI hostdev found
would result in the "next_unit" never changing from 0 (zero) and
as a result the addition of the device will fail due to being a
duplicate unit number of the first with the error message:

  virDomainDefCheckDuplicateDriveAddresses:$line : unsupported
      configuration: SCSI host address controller='0' bus='1'
      target='0' unit='0' in use by another SCSI host device

So instead of walking the controller list looking for SCSI
controllers, all we can do is "pretend" that they exist and
allow other code to create them later as necessary.
src/conf/domain_conf.c