On Wed, Nov 27, 2013 at 03:04:26PM +0800, Osier Yang wrote: > The second parameter for virNodeDeviceLookupSCSIHostByWWN is "wwnn" > instead of "wwpn", and the API supports "flags". > --- > AUTHORS | 1 + > lib/Sys/Virt/NodeDevice.pm | 5 +++-- > 2 files changed, 4 insertions(+), 2 deletions(-) > > diff --git a/AUTHORS b/AUTHORS > index d53f191..c2af49a 100644 > --- a/AUTHORS > +++ b/AUTHORS > @@ -12,5 +12,6 @@ Patches contributed by: > Stepan Kasal <skasal-at-redhat-dot-com> > Ludwig Nussel <ludwig-dot-nussel-at-suse-dot-de> > Zhe Peng <zpeng-at-redhat-dot-com> > + Osier Yang <jyang-at-redhat-dot-com> > > -- End > diff --git a/lib/Sys/Virt/NodeDevice.pm b/lib/Sys/Virt/NodeDevice.pm > index 984910d..29ceac7 100644 > --- a/lib/Sys/Virt/NodeDevice.pm > +++ b/lib/Sys/Virt/NodeDevice.pm > @@ -51,10 +51,11 @@ sub _new { > my $self; > if (exists $params{name}) { > $self = Sys::Virt::NodeDevice::_lookup_by_name($con, $params{name}); > - } elsif (exists $params{wwpn}) { > + } elsif (exists $params{wwnn}) { > $self = Sys::Virt::NodeDevice::_lookup_scsihost_by_wwn($con, > + $params{wwnn}, > $params{wwpn}, > - $params{wwnn}); > + $params{flags}); ACK if you fix the indentation to be consistent (yes, this file is using tabs in places) > } elsif (exists $params{xml}) { > $self = Sys::Virt::NodeDevice::_create_xml($con, $params{xml}); > } else { Daniel -- |: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :| |: http://libvirt.org -o- http://virt-manager.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :| -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list