1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-01-29 21:47:02 +03:00

feature #3028: check all needed pci params for deployment file

This commit is contained in:
Javi Fontan 2015-08-26 11:40:52 +02:00
parent 18946ff3b8
commit 415e0b6c96

View File

@ -976,6 +976,14 @@ int LibVirtDriver::deployment_description_kvm(
slot = pci->vector_value("SLOT");
func = pci->vector_value("FUNCTION");
if ( domain.empty() || bus.empty() || slot.empty() || func.empty() )
{
vm->log("VMM", Log::WARNING,
"DOMAIN, BUS, SLOT and FUNC must be defined for PCI "
"passthrough. Ignored.");
continue;
}
file << "\t\t<hostdev mode='subsystem' type='pci' managed='yes'>";
file << endl;
file << "\t\t\t<source>" << endl;