Re: [PATCH] conf: fix parsing 'cmd_per_lun' and 'max_sectors'

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 14.08.2014 09:55, Wang Rui wrote:
From: Mo yuxiang <moyuxiang@xxxxxxxxxx>

commit d9504941 introduces two new attributes "cmd_per_lun" and
"max_sectors" same with the names QEMU uses for virtio-scsi.
But the case of parsing them is not exact. Change to parse
them if controller has "driver" element.

Signed-off-by: Mo yuxiang <moyuxiang@xxxxxxxxxx>
---
  src/conf/domain_conf.c | 3 ++-
  1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c
index 934f6cb..5c762fa 100644
--- a/src/conf/domain_conf.c
+++ b/src/conf/domain_conf.c
@@ -6295,10 +6295,11 @@ virDomainControllerDefParseXML(xmlNodePtr node,
      cur = node->children;
      while (cur != NULL) {
          if (cur->type == XML_ELEMENT_NODE) {
-            if (xmlStrEqual(cur->name, BAD_CAST "driver"))
+            if (xmlStrEqual(cur->name, BAD_CAST "driver")) {
                  queues = virXMLPropString(cur, "queues");
                  cmd_per_lun = virXMLPropString(cur, "cmd_per_lun");
                  max_sectors = virXMLPropString(cur, "max_sectors");
+            }
          }
          cur = cur->next;
      }


ACKed and pushed. Unfortunately, the 1.2.7 release is broken so I'm pushing this into 1.2.7 maint branch too.

Michal

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]