The current implementation of the libvirt driver makes mixed assumptions
about the vcpu pin set returned from hardware.get_vcpu_pin_set(). Most
places in the code assume its a set and perform set operations on the
structure. However a few places assume it's a list. Given the mixed
assumptions about the structure type, the existing code was trying
to perform set operations on a list.
This patch changes the get_vcpu_pin_set() method to return a set
rather than a list and handles any edge cases where consumers need
a list. It also updates any relevant unit tests accordingly.
Reviewed: https:/ /review. openstack. org/123515 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=021202e80da 7ce587a4d36c464 c7b6835e5bface
Committed: https:/
Submitter: Jenkins
Branch: master
commit 021202e80da7ce5 87a4d36c464c7b6 835e5bface
Author: Boden R <email address hidden>
Date: Tue Sep 23 12:55:54 2014 -0400
Return vcpu pin set as set rather than list
The current implementation of the libvirt driver makes mixed assumptions get_vcpu_ pin_set( ). Most
about the vcpu pin set returned from hardware.
places in the code assume its a set and perform set operations on the
structure. However a few places assume it's a list. Given the mixed
assumptions about the structure type, the existing code was trying
to perform set operations on a list.
This patch changes the get_vcpu_pin_set() method to return a set
rather than a list and handles any edge cases where consumers need
a list. It also updates any relevant unit tests accordingly.
Change-Id: I66d5cbc0e2d370 d9d2d2ab2bad2c5 b348bedba6c
Closes-Bug: 1372829