[libvirt] [PATCH v6] npiv: Auto-generate WWN if it's not specified

Eric Blake eblake at redhat.com
Thu Feb 9 23:05:43 UTC 2012


On 02/07/2012 07:03 AM, Osier Yang wrote:
>> I don't like this interface - it makes virrandom.c know too much.  A
>> better interface would be:
>>
>> virRandomGenerateWWN(char **wwn, const char *oui)
>>
>> where the caller is responsible for determining the appropriate OUI for
>> the hypervisor to be passed in.
>>
> 
> I have thought this, but the problem is we want auto-generate the WWN,
> the nodedevice driver doesn't known which OUI should be passed to
> virRandomGenerateWWN in this case, unless we extend the API
> virNodeDeviceCreateXML to accept a flag, or introduce a new API. I
> guess we won't want to see this in this period. :-)

I'm okay if we ditch this for now.  But I guess I still don't understand
the motivation behind this patch - what's the original scenario where we
are parsing XML where auto-generating a WWN would prove useful?  If it
is done through a connection, then we know what hypervisor we are
targetting, and that hypervisor should have the information on what OUI
to prefer.

-- 
Eric Blake   eblake at redhat.com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 620 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20120209/166b04bc/attachment-0001.sig>


More information about the libvir-list mailing list