[dpdk-dev] [PATCH v3 3/3] doc: add VM power mgmt app

2014-12-11 Thread Iremonger, Bernard
> -Original Message-
> From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Pablo de Lara
> Sent: Tuesday, December 9, 2014 12:02 PM
> To: dev at dpdk.org
> Subject: [dpdk-dev] [PATCH v3 3/3] doc: add VM power mgmt app
> 
> Added new section in sample app UG for
> the new VM power management app.
> 
> Signed-off-by: Alan Carew 
> Signed-off-by: Pablo de Lara 

Acked-by: Bernard Iremonger 

 I have applied the patch to my tree next/dpdk-doc.


[dpdk-dev] [PATCH v3 3/3] doc: add VM power mgmt app

2014-12-09 Thread Pablo de Lara
Added new section in sample app UG for
the new VM power management app.

Signed-off-by: Alan Carew 
Signed-off-by: Pablo de Lara 
---
 doc/guides/rel_notes/rel_description.rst |2 +
 doc/guides/sample_app_ug/index.rst   |5 +
 doc/guides/sample_app_ug/vm_power_management.rst |  361 ++
 3 files changed, 368 insertions(+), 0 deletions(-)
 create mode 100644 doc/guides/sample_app_ug/vm_power_management.rst

diff --git a/doc/guides/rel_notes/rel_description.rst 
b/doc/guides/rel_notes/rel_description.rst
index 07c897b..d159b3c 100644
--- a/doc/guides/rel_notes/rel_description.rst
+++ b/doc/guides/rel_notes/rel_description.rst
@@ -149,6 +149,8 @@ The following is a list of Intel? DPDK documents in the 
suggested reading order

 *   Kernel NIC Interface (KNI)

+*   VM Power Management
+
 In addition, there are some other applications that are built when the 
libraries are created.
 The source for these applications is in the DPDK/app directory and are 
called:

diff --git a/doc/guides/sample_app_ug/index.rst 
b/doc/guides/sample_app_ug/index.rst
index db88b0d..c3b50e2 100644
--- a/doc/guides/sample_app_ug/index.rst
+++ b/doc/guides/sample_app_ug/index.rst
@@ -101,6 +101,7 @@ Copyright ? 2012 - 2014, Intel Corporation. All rights 
reserved.
 internet_proto_ip_pipeline
 test_pipeline
 dist_app
+vm_power_management

 **Figures**

@@ -152,6 +153,10 @@ Copyright ? 2012 - 2014, Intel Corporation. All rights 
reserved.

 :ref:`Figure 23.Distributor Sample Application Layout `

+:ref:`Figure 24.High level Solution `
+
+:ref:`Figure 25.VM request to scale frequency `
+
 **Tables**

 :ref:`Table 1.Output Traffic Marking `
diff --git a/doc/guides/sample_app_ug/vm_power_management.rst 
b/doc/guides/sample_app_ug/vm_power_management.rst
new file mode 100644
index 000..f5b5200
--- /dev/null
+++ b/doc/guides/sample_app_ug/vm_power_management.rst
@@ -0,0 +1,361 @@
+..  BSD LICENSE
+Copyright(c) 2010-2014 Intel Corporation. All rights reserved.
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions
+are met:
+
+* Redistributions of source code must retain the above copyright
+notice, this list of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the above copyright
+notice, this list of conditions and the following disclaimer in
+the documentation and/or other materials provided with the
+distribution.
+* Neither the name of Intel Corporation nor the names of its
+contributors may be used to endorse or promote products derived
+from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+VM Power Management Application
+===
+
+Introduction
+
+
+Applications running in Virtual Environments have an abstract view of
+the underlying hardware on the Host, in particular applications cannot see
+the binding of virtual to physical hardware.
+When looking at CPU resourcing, the pinning of Virtual CPUs(vCPUs) to
+Host Physical CPUs(pCPUS) is not apparent to an application
+and this pinning may change over time.
+Furthermore, Operating Systems on virtual machines do not have the ability
+to govern their own power policy; the Machine Specific Registers (MSRs)
+for enabling P-State transitions are not exposed to Operating Systems
+running on Virtual Machines(VMs).
+
+The Virtual Machine Power Management solution shows an example of
+how a DPDK application can indicate its processing requirements using VM local
+only information(vCPU/lcore) to a Host based Monitor which is responsible
+for accepting requests for frequency changes for a vCPU, translating the vCPU
+to a pCPU via libvirt and affecting the change in frequency.
+
+The solution is comprised of two high-level components:
+
+#. Example Host Application
+
+   Using a Command Line Interface(CLI) for VM->Host communication channel 
management
+   allows adding channels to the Monitor, setting and querying the vCPU to 
pCPU pinning,
+   inspecting and manually changing