From: Osier Yang Date: Mon, 25 Mar 2013 16:43:39 +0000 (+0800) Subject: phyp: Prohibit fc_host adapter for phyp driver X-Git-Tag: v1.0.5-rc1~213 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b78db1c36548d42ae6d792e148e47cf6c0e562ba;p=thirdparty%2Flibvirt.git phyp: Prohibit fc_host adapter for phyp driver It's possible to support fc_host adapter for phyp driver too, but at this stage I'd like to not allow it when I'm not that clear how it works. --- diff --git a/src/phyp/phyp_driver.c b/src/phyp/phyp_driver.c index a47ed65f0a..50e8216805 100644 --- a/src/phyp/phyp_driver.c +++ b/src/phyp/phyp_driver.c @@ -2506,6 +2506,13 @@ phypBuildStoragePool(virConnectPtr conn, virStoragePoolDefPtr def) int exit_status = 0; virBuffer buf = VIR_BUFFER_INITIALIZER; + if (source.adapter.type != + VIR_STORAGE_POOL_SOURCE_ADAPTER_TYPE_SCSI_HOST) { + virReportError(VIR_ERR_XML_ERROR, "%s", + _("Only 'scsi_host' adapter is supported")); + goto cleanup; + } + if (system_type == HMC) virBufferAsprintf(&buf, "viosvrcmd -m %s --id %d -c '", managed_system, vios_id);