You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cloudstack.apache.org by Pawit Pornkitprasan <p....@gmail.com> on 2013/06/26 05:02:44 UTC

Review Request 12098: Add PCI Passthrough to CloudStack on KVM Hypervisor

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/12098/
-----------------------------------------------------------

Review request for cloudstack.


Repository: cloudstack-git


Description
-------

This patch adds PCI Passthrough support to CloudStack on the KVM Hypervisor as previously mentioned on the mailing list

PCI Passthrough may be useful for high-performance networking devices
or other hardware accelerators. This patch does not care what kind of
the device it is or attempt to configure it, leaving it to the guest.

Because the devices available at each agent may be different, the
available devices for passthrough are configured at the agent
configuration file (/etc/cloudstack/agent/agent.properties).
Configuration is a comma separated list of available PCI devices and
its given name.

pci.devices=28:00.1|10GE,28:00.2|10GE,28:00.3|10GE,28:00.4|10GE,28:00.5|10GE,28:00.6|10GE,28:00.7|10GE,28:01.0|10GE

At agent startup, the list of PCI devices is parsed and sent together
with StartupRoutingCommand (in a new field, not in details). The
management server then stores it in a new table “op_host_pci_devices”.
If a device is added, removed, or renamed, the table is updated
accordingly. The agent also probes libvirt which devices are currently
in-use and send it with the command in attempt to synchronize any
potential difference between the database and the actual status.

The “name” of the PCI device is what is used to assign a device. In a
compute offering, the user can specify the name of one or more PCI
devices (as a comma-separated list) and CloudStack will find a host
with the PCI device of the specified name available and assign it.

A new manager, PciDeviceManager, is created to handle the
allocation of PCI device. The manager implements StateListener and
assigns PCI devices on state change to “starting” and also release the
devices VM stop. First fit allocator and first fit planner are also
modified to check for PCI device availability accordingly.

For migration, intrusive migration is implementated. The PCI device is
detached before migration and attached it again at the target host.
This will interrupt whatever is using the device on the VM. However,
it may be desirable for networking devices where the VM can use a
bonding device to channel network traffic through the normal
virtualized network device while the PCI Passthrough device is down.


Diffs
-----

  api/src/com/cloud/agent/api/to/PciDeviceTO.java PRE-CREATION 
  api/src/com/cloud/agent/api/to/VirtualMachineTO.java e6240ff 
  api/src/com/cloud/offering/ServiceOffering.java 45d5f38 
  api/src/com/cloud/pci/PciDevice.java PRE-CREATION 
  api/src/org/apache/cloudstack/api/ApiConstants.java 8ac7c3f 
  api/src/org/apache/cloudstack/api/command/admin/offering/CreateServiceOfferingCmd.java decac29 
  api/src/org/apache/cloudstack/api/response/ServiceOfferingResponse.java 288f76b 
  client/WEB-INF/classes/resources/messages.properties ad8d29d 
  client/tomcatconf/applicationContext.xml.in ac1f3e4 
  core/src/com/cloud/agent/api/AttachPciDevicesCommand.java PRE-CREATION 
  core/src/com/cloud/agent/api/StartupRoutingCommand.java 5961ab0 
  engine/schema/src/com/cloud/host/HostPciDeviceVO.java PRE-CREATION 
  engine/schema/src/com/cloud/host/HostVO.java c814b94 
  engine/schema/src/com/cloud/host/dao/HostDaoImpl.java 810b973 
  engine/schema/src/com/cloud/host/dao/HostPciDevicesDao.java PRE-CREATION 
  engine/schema/src/com/cloud/host/dao/HostPciDevicesDaoImpl.java PRE-CREATION 
  engine/schema/src/com/cloud/migration/ServiceOffering21VO.java 7a49e63 
  engine/schema/src/com/cloud/service/ServiceOfferingVO.java 9a262c5 
  plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtComputingResource.java 60cde8c 
  plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtDomainXMLParser.java a283768 
  plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtVMDef.java 5120870 
  server/src/com/cloud/agent/manager/allocator/impl/FirstFitAllocator.java b6286aa 
  server/src/com/cloud/alert/AlertManagerImpl.java 9b7cd27 
  server/src/com/cloud/api/query/dao/ServiceOfferingJoinDaoImpl.java 6f6e277 
  server/src/com/cloud/api/query/vo/ServiceOfferingJoinVO.java 05ff5f3 
  server/src/com/cloud/configuration/ConfigurationManager.java 98eae37 
  server/src/com/cloud/configuration/ConfigurationManagerImpl.java 704162e 
  server/src/com/cloud/deploy/DeploymentPlanningManagerImpl.java 4ef2152 
  server/src/com/cloud/hypervisor/HypervisorGuruBase.java 50bfb30 
  server/src/com/cloud/pci/PciDeviceManager.java PRE-CREATION 
  server/src/com/cloud/pci/PciDeviceManagerImpl.java PRE-CREATION 
  server/src/com/cloud/resource/ResourceManagerImpl.java fe91cb3 
  server/src/com/cloud/vm/UserVmManagerImpl.java 66103fb 
  server/test/com/cloud/vpc/MockConfigurationManagerImpl.java 95230a5 
  setup/db/db/schema-410to420.sql 325924b 
  ui/dictionary.jsp 7809cdb 
  ui/scripts/configuration.js 7f0e1a5 
  ui/scripts/docs.js 5aa352a 

Diff: https://reviews.apache.org/r/12098/diff/


Testing
-------

Testing done with Mellanox ConnectX-2 NIC with SR-IOV on Ubuntu Raring.


Thanks,

Pawit Pornkitprasan


Re: Review Request 12098: Add PCI Passthrough to CloudStack on KVM Hypervisor

Posted by Pawit Pornkitprasan <p....@gmail.com>.
I've discussed this on the mailing list before.

http://mail-archives.apache.org/mod_mbox/cloudstack-dev/201306.mbox/%3CCAJA5wJTAXH0Oi0c=fXy53MB=aQyk_oCtmM5Cvet0d7L7B+T-2A@mail.gmail.com%3E

The idea is that I'd like the implementation to be flexible enough to
support any kind of PCI Passthrough device, not just a GPU or a
network card. Note that the tag specifies the name of the PCI device,
not the physical ID which will be assigned by CloudStack based on
available devices.

To be honest, this work was assigned to me as a part of a 2-month
internship program. Now that the program is over and my studies
resume, I don't really have time to work on this feature anymore. Paul
(CCed) has expressed interest in this feature, so he might like to
continue my work.

Pawit

On Fri, Aug 9, 2013 at 3:18 AM, Chiradeep Vittal
<Ch...@citrix.com> wrote:
> As someone noted, ReviewBoard is down for now. In the meanwhile, can you
> create a wiki document and JIRA bug
> https://cwiki.apache.org/confluence/x/0h-VAQ
> https://cwiki.apache.org/confluence/x/ni-VAQ
> https://cwiki.apache.org/confluence/x/XUfVAQ
>
>
> As an end-user of the Cloud, I am not going to have any idea what or which
> PCI device is available, so the compute offering tag is not going to make
> any sense.
> On the other hand, if it is a tag like "GPU enabled", then that would make
> more sense?
>
>
> On 8/8/13 8:44 AM, "Pawit Pornkitprasan" <p....@gmail.com> wrote:
>
>>
>>-----------------------------------------------------------
>>This is an automatically generated e-mail. To reply, visit:
>>https://reviews.apache.org/r/12098/
>>-----------------------------------------------------------
>>
>>(Updated Aug. 8, 2013, 3:44 p.m.)
>>
>>
>>Review request for cloudstack.
>>
>>
>>Changes
>>-------
>>
>>Rebased on master
>>
>>
>>Repository: cloudstack-git
>>
>>
>>Description
>>-------
>>
>>This patch adds PCI Passthrough support to CloudStack on the KVM
>>Hypervisor as previously mentioned on the mailing list
>>
>>PCI Passthrough may be useful for high-performance networking devices
>>or other hardware accelerators. This patch does not care what kind of
>>the device it is or attempt to configure it, leaving it to the guest.
>>
>>Because the devices available at each agent may be different, the
>>available devices for passthrough are configured at the agent
>>configuration file (/etc/cloudstack/agent/agent.properties).
>>Configuration is a comma separated list of available PCI devices and
>>its given name.
>>
>>pci.devices=28:00.1|10GE,28:00.2|10GE,28:00.3|10GE,28:00.4|10GE,28:00.5|10
>>GE,28:00.6|10GE,28:00.7|10GE,28:01.0|10GE
>>
>>At agent startup, the list of PCI devices is parsed and sent together
>>with StartupRoutingCommand (in a new field, not in details). The
>>management server then stores it in a new table ³op_host_pci_devices².
>>If a device is added, removed, or renamed, the table is updated
>>accordingly. The agent also probes libvirt which devices are currently
>>in-use and send it with the command in attempt to synchronize any
>>potential difference between the database and the actual status.
>>
>>The ³name² of the PCI device is what is used to assign a device. In a
>>compute offering, the user can specify the name of one or more PCI
>>devices (as a comma-separated list) and CloudStack will find a host
>>with the PCI device of the specified name available and assign it.
>>
>>A new manager, PciDeviceManager, is created to handle the
>>allocation of PCI device. The manager implements StateListener and
>>assigns PCI devices on state change to ³starting² and also release the
>>devices VM stop. First fit allocator and first fit planner are also
>>modified to check for PCI device availability accordingly.
>>
>>For migration, intrusive migration is implementated. The PCI device is
>>detached before migration and attached it again at the target host.
>>This will interrupt whatever is using the device on the VM. However,
>>it may be desirable for networking devices where the VM can use a
>>bonding device to channel network traffic through the normal
>>virtualized network device while the PCI Passthrough device is down.
>>
>>
>>Diffs (updated)
>>-----
>>
>>  api/src/com/cloud/agent/api/to/PciDeviceTO.java PRE-CREATION
>>  api/src/com/cloud/agent/api/to/VirtualMachineTO.java e6240ff
>>  api/src/com/cloud/offering/ServiceOffering.java 45d5f38
>>  api/src/com/cloud/pci/PciDevice.java PRE-CREATION
>>  api/src/org/apache/cloudstack/api/ApiConstants.java 00d526d
>>
>>api/src/org/apache/cloudstack/api/command/admin/offering/CreateServiceOffe
>>ringCmd.java decac29
>>  api/src/org/apache/cloudstack/api/response/ServiceOfferingResponse.java
>>5c5b369
>>  client/WEB-INF/classes/resources/messages.properties 4fc09ee
>>  client/tomcatconf/applicationContext.xml.in b832b09
>>  core/src/com/cloud/agent/api/AttachPciDevicesCommand.java PRE-CREATION
>>  core/src/com/cloud/agent/api/StartupRoutingCommand.java 5961ab0
>>  engine/schema/src/com/cloud/host/HostPciDeviceVO.java PRE-CREATION
>>  engine/schema/src/com/cloud/host/HostVO.java c814b94
>>  engine/schema/src/com/cloud/host/dao/HostDaoImpl.java dd26941
>>  engine/schema/src/com/cloud/host/dao/HostPciDevicesDao.java
>>PRE-CREATION
>>  engine/schema/src/com/cloud/host/dao/HostPciDevicesDaoImpl.java
>>PRE-CREATION
>>  engine/schema/src/com/cloud/migration/ServiceOffering21VO.java 7a49e63
>>  engine/schema/src/com/cloud/service/ServiceOfferingVO.java 9a262c5
>>
>>plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtCompu
>>tingResource.java 542136a
>>
>>plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtDomai
>>nXMLParser.java a283768
>>
>>plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtVMDef
>>.java 6aaabc5
>>
>>server/src/com/cloud/agent/manager/allocator/impl/FirstFitAllocator.java
>>088591f
>>  server/src/com/cloud/alert/AlertManagerImpl.java c437a8c
>>  server/src/com/cloud/api/query/dao/ServiceOfferingJoinDaoImpl.java
>>945e67b
>>  server/src/com/cloud/api/query/vo/ServiceOfferingJoinVO.java 05ff5f3
>>  server/src/com/cloud/configuration/ConfigurationManager.java 775601a
>>  server/src/com/cloud/configuration/ConfigurationManagerImpl.java
>>00503c5
>>  server/src/com/cloud/deploy/DeploymentPlanningManagerImpl.java b896b84
>>  server/src/com/cloud/hypervisor/HypervisorGuruBase.java 8a9df03
>>  server/src/com/cloud/pci/PciDeviceManager.java PRE-CREATION
>>  server/src/com/cloud/pci/PciDeviceManagerImpl.java PRE-CREATION
>>  server/src/com/cloud/resource/ResourceManagerImpl.java beb5f4e
>>  server/src/com/cloud/vm/UserVmManagerImpl.java 07d5f64
>>  server/test/com/cloud/vpc/MockConfigurationManagerImpl.java 840f539
>>  setup/db/db/schema-420to430.sql 52b8391
>>  ui/dictionary.jsp 3dfdefe
>>  ui/scripts/configuration.js f9c2498
>>  ui/scripts/docs.js e3be08c
>>
>>Diff: https://reviews.apache.org/r/12098/diff/
>>
>>
>>Testing
>>-------
>>
>>Testing done with Mellanox ConnectX-2 NIC with SR-IOV on Ubuntu Raring.
>>
>>
>>Thanks,
>>
>>Pawit Pornkitprasan
>>
>

Re: Review Request 12098: Add PCI Passthrough to CloudStack on KVM Hypervisor

Posted by Chiradeep Vittal <Ch...@citrix.com>.
As someone noted, ReviewBoard is down for now. In the meanwhile, can you
create a wiki document and JIRA bug
https://cwiki.apache.org/confluence/x/0h-VAQ
https://cwiki.apache.org/confluence/x/ni-VAQ
https://cwiki.apache.org/confluence/x/XUfVAQ


As an end-user of the Cloud, I am not going to have any idea what or which
PCI device is available, so the compute offering tag is not going to make
any sense. 
On the other hand, if it is a tag like "GPU enabled", then that would make
more sense?


On 8/8/13 8:44 AM, "Pawit Pornkitprasan" <p....@gmail.com> wrote:

>
>-----------------------------------------------------------
>This is an automatically generated e-mail. To reply, visit:
>https://reviews.apache.org/r/12098/
>-----------------------------------------------------------
>
>(Updated Aug. 8, 2013, 3:44 p.m.)
>
>
>Review request for cloudstack.
>
>
>Changes
>-------
>
>Rebased on master
>
>
>Repository: cloudstack-git
>
>
>Description
>-------
>
>This patch adds PCI Passthrough support to CloudStack on the KVM
>Hypervisor as previously mentioned on the mailing list
>
>PCI Passthrough may be useful for high-performance networking devices
>or other hardware accelerators. This patch does not care what kind of
>the device it is or attempt to configure it, leaving it to the guest.
>
>Because the devices available at each agent may be different, the
>available devices for passthrough are configured at the agent
>configuration file (/etc/cloudstack/agent/agent.properties).
>Configuration is a comma separated list of available PCI devices and
>its given name.
>
>pci.devices=28:00.1|10GE,28:00.2|10GE,28:00.3|10GE,28:00.4|10GE,28:00.5|10
>GE,28:00.6|10GE,28:00.7|10GE,28:01.0|10GE
>
>At agent startup, the list of PCI devices is parsed and sent together
>with StartupRoutingCommand (in a new field, not in details). The
>management server then stores it in a new table ³op_host_pci_devices².
>If a device is added, removed, or renamed, the table is updated
>accordingly. The agent also probes libvirt which devices are currently
>in-use and send it with the command in attempt to synchronize any
>potential difference between the database and the actual status.
>
>The ³name² of the PCI device is what is used to assign a device. In a
>compute offering, the user can specify the name of one or more PCI
>devices (as a comma-separated list) and CloudStack will find a host
>with the PCI device of the specified name available and assign it.
>
>A new manager, PciDeviceManager, is created to handle the
>allocation of PCI device. The manager implements StateListener and
>assigns PCI devices on state change to ³starting² and also release the
>devices VM stop. First fit allocator and first fit planner are also
>modified to check for PCI device availability accordingly.
>
>For migration, intrusive migration is implementated. The PCI device is
>detached before migration and attached it again at the target host.
>This will interrupt whatever is using the device on the VM. However,
>it may be desirable for networking devices where the VM can use a
>bonding device to channel network traffic through the normal
>virtualized network device while the PCI Passthrough device is down.
>
>
>Diffs (updated)
>-----
>
>  api/src/com/cloud/agent/api/to/PciDeviceTO.java PRE-CREATION
>  api/src/com/cloud/agent/api/to/VirtualMachineTO.java e6240ff
>  api/src/com/cloud/offering/ServiceOffering.java 45d5f38
>  api/src/com/cloud/pci/PciDevice.java PRE-CREATION
>  api/src/org/apache/cloudstack/api/ApiConstants.java 00d526d
>  
>api/src/org/apache/cloudstack/api/command/admin/offering/CreateServiceOffe
>ringCmd.java decac29
>  api/src/org/apache/cloudstack/api/response/ServiceOfferingResponse.java
>5c5b369 
>  client/WEB-INF/classes/resources/messages.properties 4fc09ee
>  client/tomcatconf/applicationContext.xml.in b832b09
>  core/src/com/cloud/agent/api/AttachPciDevicesCommand.java PRE-CREATION
>  core/src/com/cloud/agent/api/StartupRoutingCommand.java 5961ab0
>  engine/schema/src/com/cloud/host/HostPciDeviceVO.java PRE-CREATION
>  engine/schema/src/com/cloud/host/HostVO.java c814b94
>  engine/schema/src/com/cloud/host/dao/HostDaoImpl.java dd26941
>  engine/schema/src/com/cloud/host/dao/HostPciDevicesDao.java
>PRE-CREATION 
>  engine/schema/src/com/cloud/host/dao/HostPciDevicesDaoImpl.java
>PRE-CREATION 
>  engine/schema/src/com/cloud/migration/ServiceOffering21VO.java 7a49e63
>  engine/schema/src/com/cloud/service/ServiceOfferingVO.java 9a262c5
>  
>plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtCompu
>tingResource.java 542136a
>  
>plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtDomai
>nXMLParser.java a283768
>  
>plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtVMDef
>.java 6aaabc5 
>  
>server/src/com/cloud/agent/manager/allocator/impl/FirstFitAllocator.java
>088591f 
>  server/src/com/cloud/alert/AlertManagerImpl.java c437a8c
>  server/src/com/cloud/api/query/dao/ServiceOfferingJoinDaoImpl.java
>945e67b 
>  server/src/com/cloud/api/query/vo/ServiceOfferingJoinVO.java 05ff5f3
>  server/src/com/cloud/configuration/ConfigurationManager.java 775601a
>  server/src/com/cloud/configuration/ConfigurationManagerImpl.java
>00503c5 
>  server/src/com/cloud/deploy/DeploymentPlanningManagerImpl.java b896b84
>  server/src/com/cloud/hypervisor/HypervisorGuruBase.java 8a9df03
>  server/src/com/cloud/pci/PciDeviceManager.java PRE-CREATION
>  server/src/com/cloud/pci/PciDeviceManagerImpl.java PRE-CREATION
>  server/src/com/cloud/resource/ResourceManagerImpl.java beb5f4e
>  server/src/com/cloud/vm/UserVmManagerImpl.java 07d5f64
>  server/test/com/cloud/vpc/MockConfigurationManagerImpl.java 840f539
>  setup/db/db/schema-420to430.sql 52b8391
>  ui/dictionary.jsp 3dfdefe
>  ui/scripts/configuration.js f9c2498
>  ui/scripts/docs.js e3be08c
>
>Diff: https://reviews.apache.org/r/12098/diff/
>
>
>Testing
>-------
>
>Testing done with Mellanox ConnectX-2 NIC with SR-IOV on Ubuntu Raring.
>
>
>Thanks,
>
>Pawit Pornkitprasan
>


Re: Review Request 12098: Add PCI Passthrough to CloudStack on KVM Hypervisor

Posted by Pawit Pornkitprasan <p....@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/12098/
-----------------------------------------------------------

(Updated Aug. 8, 2013, 3:44 p.m.)


Review request for cloudstack.


Changes
-------

Rebased on master


Repository: cloudstack-git


Description
-------

This patch adds PCI Passthrough support to CloudStack on the KVM Hypervisor as previously mentioned on the mailing list

PCI Passthrough may be useful for high-performance networking devices
or other hardware accelerators. This patch does not care what kind of
the device it is or attempt to configure it, leaving it to the guest.

Because the devices available at each agent may be different, the
available devices for passthrough are configured at the agent
configuration file (/etc/cloudstack/agent/agent.properties).
Configuration is a comma separated list of available PCI devices and
its given name.

pci.devices=28:00.1|10GE,28:00.2|10GE,28:00.3|10GE,28:00.4|10GE,28:00.5|10GE,28:00.6|10GE,28:00.7|10GE,28:01.0|10GE

At agent startup, the list of PCI devices is parsed and sent together
with StartupRoutingCommand (in a new field, not in details). The
management server then stores it in a new table “op_host_pci_devices”.
If a device is added, removed, or renamed, the table is updated
accordingly. The agent also probes libvirt which devices are currently
in-use and send it with the command in attempt to synchronize any
potential difference between the database and the actual status.

The “name” of the PCI device is what is used to assign a device. In a
compute offering, the user can specify the name of one or more PCI
devices (as a comma-separated list) and CloudStack will find a host
with the PCI device of the specified name available and assign it.

A new manager, PciDeviceManager, is created to handle the
allocation of PCI device. The manager implements StateListener and
assigns PCI devices on state change to “starting” and also release the
devices VM stop. First fit allocator and first fit planner are also
modified to check for PCI device availability accordingly.

For migration, intrusive migration is implementated. The PCI device is
detached before migration and attached it again at the target host.
This will interrupt whatever is using the device on the VM. However,
it may be desirable for networking devices where the VM can use a
bonding device to channel network traffic through the normal
virtualized network device while the PCI Passthrough device is down.


Diffs (updated)
-----

  api/src/com/cloud/agent/api/to/PciDeviceTO.java PRE-CREATION 
  api/src/com/cloud/agent/api/to/VirtualMachineTO.java e6240ff 
  api/src/com/cloud/offering/ServiceOffering.java 45d5f38 
  api/src/com/cloud/pci/PciDevice.java PRE-CREATION 
  api/src/org/apache/cloudstack/api/ApiConstants.java 00d526d 
  api/src/org/apache/cloudstack/api/command/admin/offering/CreateServiceOfferingCmd.java decac29 
  api/src/org/apache/cloudstack/api/response/ServiceOfferingResponse.java 5c5b369 
  client/WEB-INF/classes/resources/messages.properties 4fc09ee 
  client/tomcatconf/applicationContext.xml.in b832b09 
  core/src/com/cloud/agent/api/AttachPciDevicesCommand.java PRE-CREATION 
  core/src/com/cloud/agent/api/StartupRoutingCommand.java 5961ab0 
  engine/schema/src/com/cloud/host/HostPciDeviceVO.java PRE-CREATION 
  engine/schema/src/com/cloud/host/HostVO.java c814b94 
  engine/schema/src/com/cloud/host/dao/HostDaoImpl.java dd26941 
  engine/schema/src/com/cloud/host/dao/HostPciDevicesDao.java PRE-CREATION 
  engine/schema/src/com/cloud/host/dao/HostPciDevicesDaoImpl.java PRE-CREATION 
  engine/schema/src/com/cloud/migration/ServiceOffering21VO.java 7a49e63 
  engine/schema/src/com/cloud/service/ServiceOfferingVO.java 9a262c5 
  plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtComputingResource.java 542136a 
  plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtDomainXMLParser.java a283768 
  plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtVMDef.java 6aaabc5 
  server/src/com/cloud/agent/manager/allocator/impl/FirstFitAllocator.java 088591f 
  server/src/com/cloud/alert/AlertManagerImpl.java c437a8c 
  server/src/com/cloud/api/query/dao/ServiceOfferingJoinDaoImpl.java 945e67b 
  server/src/com/cloud/api/query/vo/ServiceOfferingJoinVO.java 05ff5f3 
  server/src/com/cloud/configuration/ConfigurationManager.java 775601a 
  server/src/com/cloud/configuration/ConfigurationManagerImpl.java 00503c5 
  server/src/com/cloud/deploy/DeploymentPlanningManagerImpl.java b896b84 
  server/src/com/cloud/hypervisor/HypervisorGuruBase.java 8a9df03 
  server/src/com/cloud/pci/PciDeviceManager.java PRE-CREATION 
  server/src/com/cloud/pci/PciDeviceManagerImpl.java PRE-CREATION 
  server/src/com/cloud/resource/ResourceManagerImpl.java beb5f4e 
  server/src/com/cloud/vm/UserVmManagerImpl.java 07d5f64 
  server/test/com/cloud/vpc/MockConfigurationManagerImpl.java 840f539 
  setup/db/db/schema-420to430.sql 52b8391 
  ui/dictionary.jsp 3dfdefe 
  ui/scripts/configuration.js f9c2498 
  ui/scripts/docs.js e3be08c 

Diff: https://reviews.apache.org/r/12098/diff/


Testing
-------

Testing done with Mellanox ConnectX-2 NIC with SR-IOV on Ubuntu Raring.


Thanks,

Pawit Pornkitprasan


Re: Review Request 12098: Add PCI Passthrough to CloudStack on KVM Hypervisor

Posted by Amogh Vasekar <am...@citrix.com>.

> On Aug. 7, 2013, 10:30 a.m., Pawit Pornkitprasan wrote:
> > I will rebase it in a few days.
> > 
> > This patch only includes support for KVM, but the concepts used can apply for all hypervisors supporting PCI Passthrough so additional patches can add support for XenServer. (Just to be clear, I'm not planning on adding support for other hypervisors myself.)
> > 
> > When used with other hypervisors, any attempt to start any VM requesting PCI Passthrough will gracefully fail in planning step as no host will be able to provide the request PCI devices.

Reminder - 
Hi,
This review has been pending for long. Please update to "submitted" if this has already been committed.
Thanks


- Amogh


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/12098/#review24788
-----------------------------------------------------------


On Aug. 8, 2013, 3:44 p.m., Pawit Pornkitprasan wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/12098/
> -----------------------------------------------------------
> 
> (Updated Aug. 8, 2013, 3:44 p.m.)
> 
> 
> Review request for cloudstack.
> 
> 
> Repository: cloudstack-git
> 
> 
> Description
> -------
> 
> This patch adds PCI Passthrough support to CloudStack on the KVM Hypervisor as previously mentioned on the mailing list
> 
> PCI Passthrough may be useful for high-performance networking devices
> or other hardware accelerators. This patch does not care what kind of
> the device it is or attempt to configure it, leaving it to the guest.
> 
> Because the devices available at each agent may be different, the
> available devices for passthrough are configured at the agent
> configuration file (/etc/cloudstack/agent/agent.properties).
> Configuration is a comma separated list of available PCI devices and
> its given name.
> 
> pci.devices=28:00.1|10GE,28:00.2|10GE,28:00.3|10GE,28:00.4|10GE,28:00.5|10GE,28:00.6|10GE,28:00.7|10GE,28:01.0|10GE
> 
> At agent startup, the list of PCI devices is parsed and sent together
> with StartupRoutingCommand (in a new field, not in details). The
> management server then stores it in a new table “op_host_pci_devices”.
> If a device is added, removed, or renamed, the table is updated
> accordingly. The agent also probes libvirt which devices are currently
> in-use and send it with the command in attempt to synchronize any
> potential difference between the database and the actual status.
> 
> The “name” of the PCI device is what is used to assign a device. In a
> compute offering, the user can specify the name of one or more PCI
> devices (as a comma-separated list) and CloudStack will find a host
> with the PCI device of the specified name available and assign it.
> 
> A new manager, PciDeviceManager, is created to handle the
> allocation of PCI device. The manager implements StateListener and
> assigns PCI devices on state change to “starting” and also release the
> devices VM stop. First fit allocator and first fit planner are also
> modified to check for PCI device availability accordingly.
> 
> For migration, intrusive migration is implementated. The PCI device is
> detached before migration and attached it again at the target host.
> This will interrupt whatever is using the device on the VM. However,
> it may be desirable for networking devices where the VM can use a
> bonding device to channel network traffic through the normal
> virtualized network device while the PCI Passthrough device is down.
> 
> 
> Diffs
> -----
> 
>   api/src/com/cloud/agent/api/to/PciDeviceTO.java PRE-CREATION 
>   api/src/com/cloud/agent/api/to/VirtualMachineTO.java e6240ff 
>   api/src/com/cloud/offering/ServiceOffering.java 45d5f38 
>   api/src/com/cloud/pci/PciDevice.java PRE-CREATION 
>   api/src/org/apache/cloudstack/api/ApiConstants.java 00d526d 
>   api/src/org/apache/cloudstack/api/command/admin/offering/CreateServiceOfferingCmd.java decac29 
>   api/src/org/apache/cloudstack/api/response/ServiceOfferingResponse.java 5c5b369 
>   client/WEB-INF/classes/resources/messages.properties 4fc09ee 
>   client/tomcatconf/applicationContext.xml.in b832b09 
>   core/src/com/cloud/agent/api/AttachPciDevicesCommand.java PRE-CREATION 
>   core/src/com/cloud/agent/api/StartupRoutingCommand.java 5961ab0 
>   engine/schema/src/com/cloud/host/HostPciDeviceVO.java PRE-CREATION 
>   engine/schema/src/com/cloud/host/HostVO.java c814b94 
>   engine/schema/src/com/cloud/host/dao/HostDaoImpl.java dd26941 
>   engine/schema/src/com/cloud/host/dao/HostPciDevicesDao.java PRE-CREATION 
>   engine/schema/src/com/cloud/host/dao/HostPciDevicesDaoImpl.java PRE-CREATION 
>   engine/schema/src/com/cloud/migration/ServiceOffering21VO.java 7a49e63 
>   engine/schema/src/com/cloud/service/ServiceOfferingVO.java 9a262c5 
>   plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtComputingResource.java 542136a 
>   plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtDomainXMLParser.java a283768 
>   plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtVMDef.java 6aaabc5 
>   server/src/com/cloud/agent/manager/allocator/impl/FirstFitAllocator.java 088591f 
>   server/src/com/cloud/alert/AlertManagerImpl.java c437a8c 
>   server/src/com/cloud/api/query/dao/ServiceOfferingJoinDaoImpl.java 945e67b 
>   server/src/com/cloud/api/query/vo/ServiceOfferingJoinVO.java 05ff5f3 
>   server/src/com/cloud/configuration/ConfigurationManager.java 775601a 
>   server/src/com/cloud/configuration/ConfigurationManagerImpl.java 00503c5 
>   server/src/com/cloud/deploy/DeploymentPlanningManagerImpl.java b896b84 
>   server/src/com/cloud/hypervisor/HypervisorGuruBase.java 8a9df03 
>   server/src/com/cloud/pci/PciDeviceManager.java PRE-CREATION 
>   server/src/com/cloud/pci/PciDeviceManagerImpl.java PRE-CREATION 
>   server/src/com/cloud/resource/ResourceManagerImpl.java beb5f4e 
>   server/src/com/cloud/vm/UserVmManagerImpl.java 07d5f64 
>   server/test/com/cloud/vpc/MockConfigurationManagerImpl.java 840f539 
>   setup/db/db/schema-420to430.sql 52b8391 
>   ui/dictionary.jsp 3dfdefe 
>   ui/scripts/configuration.js f9c2498 
>   ui/scripts/docs.js e3be08c 
> 
> Diff: https://reviews.apache.org/r/12098/diff/
> 
> 
> Testing
> -------
> 
> Testing done with Mellanox ConnectX-2 NIC with SR-IOV on Ubuntu Raring.
> 
> 
> Thanks,
> 
> Pawit Pornkitprasan
> 
>


Re: Review Request 12098: Add PCI Passthrough to CloudStack on KVM Hypervisor

Posted by Pawit Pornkitprasan <p....@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/12098/#review24788
-----------------------------------------------------------


I will rebase it in a few days.

This patch only includes support for KVM, but the concepts used can apply for all hypervisors supporting PCI Passthrough so additional patches can add support for XenServer. (Just to be clear, I'm not planning on adding support for other hypervisors myself.)

When used with other hypervisors, any attempt to start any VM requesting PCI Passthrough will gracefully fail in planning step as no host will be able to provide the request PCI devices.

- Pawit Pornkitprasan


On July 2, 2013, 7:12 a.m., Pawit Pornkitprasan wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/12098/
> -----------------------------------------------------------
> 
> (Updated July 2, 2013, 7:12 a.m.)
> 
> 
> Review request for cloudstack.
> 
> 
> Repository: cloudstack-git
> 
> 
> Description
> -------
> 
> This patch adds PCI Passthrough support to CloudStack on the KVM Hypervisor as previously mentioned on the mailing list
> 
> PCI Passthrough may be useful for high-performance networking devices
> or other hardware accelerators. This patch does not care what kind of
> the device it is or attempt to configure it, leaving it to the guest.
> 
> Because the devices available at each agent may be different, the
> available devices for passthrough are configured at the agent
> configuration file (/etc/cloudstack/agent/agent.properties).
> Configuration is a comma separated list of available PCI devices and
> its given name.
> 
> pci.devices=28:00.1|10GE,28:00.2|10GE,28:00.3|10GE,28:00.4|10GE,28:00.5|10GE,28:00.6|10GE,28:00.7|10GE,28:01.0|10GE
> 
> At agent startup, the list of PCI devices is parsed and sent together
> with StartupRoutingCommand (in a new field, not in details). The
> management server then stores it in a new table “op_host_pci_devices”.
> If a device is added, removed, or renamed, the table is updated
> accordingly. The agent also probes libvirt which devices are currently
> in-use and send it with the command in attempt to synchronize any
> potential difference between the database and the actual status.
> 
> The “name” of the PCI device is what is used to assign a device. In a
> compute offering, the user can specify the name of one or more PCI
> devices (as a comma-separated list) and CloudStack will find a host
> with the PCI device of the specified name available and assign it.
> 
> A new manager, PciDeviceManager, is created to handle the
> allocation of PCI device. The manager implements StateListener and
> assigns PCI devices on state change to “starting” and also release the
> devices VM stop. First fit allocator and first fit planner are also
> modified to check for PCI device availability accordingly.
> 
> For migration, intrusive migration is implementated. The PCI device is
> detached before migration and attached it again at the target host.
> This will interrupt whatever is using the device on the VM. However,
> it may be desirable for networking devices where the VM can use a
> bonding device to channel network traffic through the normal
> virtualized network device while the PCI Passthrough device is down.
> 
> 
> Diffs
> -----
> 
>   api/src/com/cloud/agent/api/to/PciDeviceTO.java PRE-CREATION 
>   api/src/com/cloud/agent/api/to/VirtualMachineTO.java e6240ff 
>   api/src/com/cloud/offering/ServiceOffering.java 45d5f38 
>   api/src/com/cloud/pci/PciDevice.java PRE-CREATION 
>   api/src/org/apache/cloudstack/api/ApiConstants.java 8ac7c3f 
>   api/src/org/apache/cloudstack/api/command/admin/offering/CreateServiceOfferingCmd.java decac29 
>   api/src/org/apache/cloudstack/api/response/ServiceOfferingResponse.java 288f76b 
>   client/WEB-INF/classes/resources/messages.properties ad8d29d 
>   client/tomcatconf/applicationContext.xml.in ac1f3e4 
>   core/src/com/cloud/agent/api/AttachPciDevicesCommand.java PRE-CREATION 
>   core/src/com/cloud/agent/api/StartupRoutingCommand.java 5961ab0 
>   engine/schema/src/com/cloud/host/HostPciDeviceVO.java PRE-CREATION 
>   engine/schema/src/com/cloud/host/HostVO.java c814b94 
>   engine/schema/src/com/cloud/host/dao/HostDaoImpl.java 810b973 
>   engine/schema/src/com/cloud/host/dao/HostPciDevicesDao.java PRE-CREATION 
>   engine/schema/src/com/cloud/host/dao/HostPciDevicesDaoImpl.java PRE-CREATION 
>   engine/schema/src/com/cloud/migration/ServiceOffering21VO.java 7a49e63 
>   engine/schema/src/com/cloud/service/ServiceOfferingVO.java 9a262c5 
>   plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtComputingResource.java 60cde8c 
>   plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtDomainXMLParser.java a283768 
>   plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtVMDef.java 5120870 
>   server/src/com/cloud/agent/manager/allocator/impl/FirstFitAllocator.java b6286aa 
>   server/src/com/cloud/alert/AlertManagerImpl.java 9b7cd27 
>   server/src/com/cloud/api/query/dao/ServiceOfferingJoinDaoImpl.java 6f6e277 
>   server/src/com/cloud/api/query/vo/ServiceOfferingJoinVO.java 05ff5f3 
>   server/src/com/cloud/configuration/ConfigurationManager.java 98eae37 
>   server/src/com/cloud/configuration/ConfigurationManagerImpl.java 704162e 
>   server/src/com/cloud/deploy/DeploymentPlanningManagerImpl.java 4ef2152 
>   server/src/com/cloud/hypervisor/HypervisorGuruBase.java 50bfb30 
>   server/src/com/cloud/pci/PciDeviceManager.java PRE-CREATION 
>   server/src/com/cloud/pci/PciDeviceManagerImpl.java PRE-CREATION 
>   server/src/com/cloud/resource/ResourceManagerImpl.java fe91cb3 
>   server/src/com/cloud/vm/UserVmManagerImpl.java 66103fb 
>   server/test/com/cloud/vpc/MockConfigurationManagerImpl.java 95230a5 
>   setup/db/db/schema-410to420.sql 325924b 
>   ui/dictionary.jsp 7809cdb 
>   ui/scripts/configuration.js 7f0e1a5 
>   ui/scripts/docs.js 5aa352a 
> 
> Diff: https://reviews.apache.org/r/12098/diff/
> 
> 
> Testing
> -------
> 
> Testing done with Mellanox ConnectX-2 NIC with SR-IOV on Ubuntu Raring.
> 
> 
> Thanks,
> 
> Pawit Pornkitprasan
> 
>


Re: Review Request 12098: Add PCI Passthrough to CloudStack on KVM Hypervisor

Posted by Chiradeep Vittal <ch...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/12098/#review24763
-----------------------------------------------------------


Can you rebase against latest master? How does this apply to Xenserver?

- Chiradeep Vittal


On July 2, 2013, 7:12 a.m., Pawit Pornkitprasan wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/12098/
> -----------------------------------------------------------
> 
> (Updated July 2, 2013, 7:12 a.m.)
> 
> 
> Review request for cloudstack.
> 
> 
> Repository: cloudstack-git
> 
> 
> Description
> -------
> 
> This patch adds PCI Passthrough support to CloudStack on the KVM Hypervisor as previously mentioned on the mailing list
> 
> PCI Passthrough may be useful for high-performance networking devices
> or other hardware accelerators. This patch does not care what kind of
> the device it is or attempt to configure it, leaving it to the guest.
> 
> Because the devices available at each agent may be different, the
> available devices for passthrough are configured at the agent
> configuration file (/etc/cloudstack/agent/agent.properties).
> Configuration is a comma separated list of available PCI devices and
> its given name.
> 
> pci.devices=28:00.1|10GE,28:00.2|10GE,28:00.3|10GE,28:00.4|10GE,28:00.5|10GE,28:00.6|10GE,28:00.7|10GE,28:01.0|10GE
> 
> At agent startup, the list of PCI devices is parsed and sent together
> with StartupRoutingCommand (in a new field, not in details). The
> management server then stores it in a new table “op_host_pci_devices”.
> If a device is added, removed, or renamed, the table is updated
> accordingly. The agent also probes libvirt which devices are currently
> in-use and send it with the command in attempt to synchronize any
> potential difference between the database and the actual status.
> 
> The “name” of the PCI device is what is used to assign a device. In a
> compute offering, the user can specify the name of one or more PCI
> devices (as a comma-separated list) and CloudStack will find a host
> with the PCI device of the specified name available and assign it.
> 
> A new manager, PciDeviceManager, is created to handle the
> allocation of PCI device. The manager implements StateListener and
> assigns PCI devices on state change to “starting” and also release the
> devices VM stop. First fit allocator and first fit planner are also
> modified to check for PCI device availability accordingly.
> 
> For migration, intrusive migration is implementated. The PCI device is
> detached before migration and attached it again at the target host.
> This will interrupt whatever is using the device on the VM. However,
> it may be desirable for networking devices where the VM can use a
> bonding device to channel network traffic through the normal
> virtualized network device while the PCI Passthrough device is down.
> 
> 
> Diffs
> -----
> 
>   api/src/com/cloud/agent/api/to/PciDeviceTO.java PRE-CREATION 
>   api/src/com/cloud/agent/api/to/VirtualMachineTO.java e6240ff 
>   api/src/com/cloud/offering/ServiceOffering.java 45d5f38 
>   api/src/com/cloud/pci/PciDevice.java PRE-CREATION 
>   api/src/org/apache/cloudstack/api/ApiConstants.java 8ac7c3f 
>   api/src/org/apache/cloudstack/api/command/admin/offering/CreateServiceOfferingCmd.java decac29 
>   api/src/org/apache/cloudstack/api/response/ServiceOfferingResponse.java 288f76b 
>   client/WEB-INF/classes/resources/messages.properties ad8d29d 
>   client/tomcatconf/applicationContext.xml.in ac1f3e4 
>   core/src/com/cloud/agent/api/AttachPciDevicesCommand.java PRE-CREATION 
>   core/src/com/cloud/agent/api/StartupRoutingCommand.java 5961ab0 
>   engine/schema/src/com/cloud/host/HostPciDeviceVO.java PRE-CREATION 
>   engine/schema/src/com/cloud/host/HostVO.java c814b94 
>   engine/schema/src/com/cloud/host/dao/HostDaoImpl.java 810b973 
>   engine/schema/src/com/cloud/host/dao/HostPciDevicesDao.java PRE-CREATION 
>   engine/schema/src/com/cloud/host/dao/HostPciDevicesDaoImpl.java PRE-CREATION 
>   engine/schema/src/com/cloud/migration/ServiceOffering21VO.java 7a49e63 
>   engine/schema/src/com/cloud/service/ServiceOfferingVO.java 9a262c5 
>   plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtComputingResource.java 60cde8c 
>   plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtDomainXMLParser.java a283768 
>   plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtVMDef.java 5120870 
>   server/src/com/cloud/agent/manager/allocator/impl/FirstFitAllocator.java b6286aa 
>   server/src/com/cloud/alert/AlertManagerImpl.java 9b7cd27 
>   server/src/com/cloud/api/query/dao/ServiceOfferingJoinDaoImpl.java 6f6e277 
>   server/src/com/cloud/api/query/vo/ServiceOfferingJoinVO.java 05ff5f3 
>   server/src/com/cloud/configuration/ConfigurationManager.java 98eae37 
>   server/src/com/cloud/configuration/ConfigurationManagerImpl.java 704162e 
>   server/src/com/cloud/deploy/DeploymentPlanningManagerImpl.java 4ef2152 
>   server/src/com/cloud/hypervisor/HypervisorGuruBase.java 50bfb30 
>   server/src/com/cloud/pci/PciDeviceManager.java PRE-CREATION 
>   server/src/com/cloud/pci/PciDeviceManagerImpl.java PRE-CREATION 
>   server/src/com/cloud/resource/ResourceManagerImpl.java fe91cb3 
>   server/src/com/cloud/vm/UserVmManagerImpl.java 66103fb 
>   server/test/com/cloud/vpc/MockConfigurationManagerImpl.java 95230a5 
>   setup/db/db/schema-410to420.sql 325924b 
>   ui/dictionary.jsp 7809cdb 
>   ui/scripts/configuration.js 7f0e1a5 
>   ui/scripts/docs.js 5aa352a 
> 
> Diff: https://reviews.apache.org/r/12098/diff/
> 
> 
> Testing
> -------
> 
> Testing done with Mellanox ConnectX-2 NIC with SR-IOV on Ubuntu Raring.
> 
> 
> Thanks,
> 
> Pawit Pornkitprasan
> 
>


Re: Review Request 12098: Add PCI Passthrough to CloudStack on KVM Hypervisor

Posted by Pawit Pornkitprasan <p....@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/12098/
-----------------------------------------------------------

(Updated July 2, 2013, 7:12 a.m.)


Review request for cloudstack.


Changes
-------

Updated patchset: fix missing check in migrateVirtualMachineWithVolume


Repository: cloudstack-git


Description
-------

This patch adds PCI Passthrough support to CloudStack on the KVM Hypervisor as previously mentioned on the mailing list

PCI Passthrough may be useful for high-performance networking devices
or other hardware accelerators. This patch does not care what kind of
the device it is or attempt to configure it, leaving it to the guest.

Because the devices available at each agent may be different, the
available devices for passthrough are configured at the agent
configuration file (/etc/cloudstack/agent/agent.properties).
Configuration is a comma separated list of available PCI devices and
its given name.

pci.devices=28:00.1|10GE,28:00.2|10GE,28:00.3|10GE,28:00.4|10GE,28:00.5|10GE,28:00.6|10GE,28:00.7|10GE,28:01.0|10GE

At agent startup, the list of PCI devices is parsed and sent together
with StartupRoutingCommand (in a new field, not in details). The
management server then stores it in a new table “op_host_pci_devices”.
If a device is added, removed, or renamed, the table is updated
accordingly. The agent also probes libvirt which devices are currently
in-use and send it with the command in attempt to synchronize any
potential difference between the database and the actual status.

The “name” of the PCI device is what is used to assign a device. In a
compute offering, the user can specify the name of one or more PCI
devices (as a comma-separated list) and CloudStack will find a host
with the PCI device of the specified name available and assign it.

A new manager, PciDeviceManager, is created to handle the
allocation of PCI device. The manager implements StateListener and
assigns PCI devices on state change to “starting” and also release the
devices VM stop. First fit allocator and first fit planner are also
modified to check for PCI device availability accordingly.

For migration, intrusive migration is implementated. The PCI device is
detached before migration and attached it again at the target host.
This will interrupt whatever is using the device on the VM. However,
it may be desirable for networking devices where the VM can use a
bonding device to channel network traffic through the normal
virtualized network device while the PCI Passthrough device is down.


Diffs (updated)
-----

  api/src/com/cloud/agent/api/to/PciDeviceTO.java PRE-CREATION 
  api/src/com/cloud/agent/api/to/VirtualMachineTO.java e6240ff 
  api/src/com/cloud/offering/ServiceOffering.java 45d5f38 
  api/src/com/cloud/pci/PciDevice.java PRE-CREATION 
  api/src/org/apache/cloudstack/api/ApiConstants.java 8ac7c3f 
  api/src/org/apache/cloudstack/api/command/admin/offering/CreateServiceOfferingCmd.java decac29 
  api/src/org/apache/cloudstack/api/response/ServiceOfferingResponse.java 288f76b 
  client/WEB-INF/classes/resources/messages.properties ad8d29d 
  client/tomcatconf/applicationContext.xml.in ac1f3e4 
  core/src/com/cloud/agent/api/AttachPciDevicesCommand.java PRE-CREATION 
  core/src/com/cloud/agent/api/StartupRoutingCommand.java 5961ab0 
  engine/schema/src/com/cloud/host/HostPciDeviceVO.java PRE-CREATION 
  engine/schema/src/com/cloud/host/HostVO.java c814b94 
  engine/schema/src/com/cloud/host/dao/HostDaoImpl.java 810b973 
  engine/schema/src/com/cloud/host/dao/HostPciDevicesDao.java PRE-CREATION 
  engine/schema/src/com/cloud/host/dao/HostPciDevicesDaoImpl.java PRE-CREATION 
  engine/schema/src/com/cloud/migration/ServiceOffering21VO.java 7a49e63 
  engine/schema/src/com/cloud/service/ServiceOfferingVO.java 9a262c5 
  plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtComputingResource.java 60cde8c 
  plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtDomainXMLParser.java a283768 
  plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtVMDef.java 5120870 
  server/src/com/cloud/agent/manager/allocator/impl/FirstFitAllocator.java b6286aa 
  server/src/com/cloud/alert/AlertManagerImpl.java 9b7cd27 
  server/src/com/cloud/api/query/dao/ServiceOfferingJoinDaoImpl.java 6f6e277 
  server/src/com/cloud/api/query/vo/ServiceOfferingJoinVO.java 05ff5f3 
  server/src/com/cloud/configuration/ConfigurationManager.java 98eae37 
  server/src/com/cloud/configuration/ConfigurationManagerImpl.java 704162e 
  server/src/com/cloud/deploy/DeploymentPlanningManagerImpl.java 4ef2152 
  server/src/com/cloud/hypervisor/HypervisorGuruBase.java 50bfb30 
  server/src/com/cloud/pci/PciDeviceManager.java PRE-CREATION 
  server/src/com/cloud/pci/PciDeviceManagerImpl.java PRE-CREATION 
  server/src/com/cloud/resource/ResourceManagerImpl.java fe91cb3 
  server/src/com/cloud/vm/UserVmManagerImpl.java 66103fb 
  server/test/com/cloud/vpc/MockConfigurationManagerImpl.java 95230a5 
  setup/db/db/schema-410to420.sql 325924b 
  ui/dictionary.jsp 7809cdb 
  ui/scripts/configuration.js 7f0e1a5 
  ui/scripts/docs.js 5aa352a 

Diff: https://reviews.apache.org/r/12098/diff/


Testing
-------

Testing done with Mellanox ConnectX-2 NIC with SR-IOV on Ubuntu Raring.


Thanks,

Pawit Pornkitprasan