Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/17208/?format=api
https://patches.dpdk.org/api/patches/17208/?format=api", "web_url": "https://patches.dpdk.org/project/dpdk/patch/20161123210006.7113-1-maxime.coquelin@redhat.com/", "project": { "id": 1, "url": "https://patches.dpdk.org/api/projects/1/?format=api", "name": "DPDK", "link_name": "dpdk", "list_id": "dev.dpdk.org", "list_email": "dev@dpdk.org", "web_url": "http://core.dpdk.org", "scm_url": "git://dpdk.org/dpdk", "webscm_url": "http://git.dpdk.org/dpdk", "list_archive_url": "https://inbox.dpdk.org/dev", "list_archive_url_format": "https://inbox.dpdk.org/dev/{}", "commit_url_format": "" }, "msgid": "<20161123210006.7113-1-maxime.coquelin@redhat.com>", "list_archive_url": "https://inbox.dpdk.org/dev/20161123210006.7113-1-maxime.coquelin@redhat.com", "date": "2016-11-23T21:00:06", "name": "[dpdk-dev] doc: introduce PVP reference benchmark", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": true, "hash": "bd46595748ba1ca319027748f62a90913c3c945d", "submitter": { "id": 512, "url": "https://patches.dpdk.org/api/people/512/?format=api", "name": "Maxime Coquelin", "email": "maxime.coquelin@redhat.com" }, "delegate": { "id": 1, "url": "https://patches.dpdk.org/api/users/1/?format=api", "username": "tmonjalo", "first_name": "Thomas", "last_name": "Monjalon", "email": "thomas@monjalon.net" }, "mbox": "https://patches.dpdk.org/project/dpdk/patch/20161123210006.7113-1-maxime.coquelin@redhat.com/mbox/", "series": [], "comments": "https://patches.dpdk.org/api/patches/17208/comments/", "check": "warning", "checks": "https://patches.dpdk.org/api/patches/17208/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<dev-bounces@dpdk.org>", "X-Original-To": "patchwork@dpdk.org", "Delivered-To": "patchwork@dpdk.org", "Received": [ "from [92.243.14.124] (localhost [IPv6:::1])\n\tby dpdk.org (Postfix) with ESMTP id 39B092BBD;\n\tWed, 23 Nov 2016 22:00:21 +0100 (CET)", "from mx1.redhat.com (mx1.redhat.com [209.132.183.28])\n\tby dpdk.org (Postfix) with ESMTP id 2D9652BA7\n\tfor <dev@dpdk.org>; Wed, 23 Nov 2016 22:00:18 +0100 (CET)", "from int-mx09.intmail.prod.int.phx2.redhat.com\n\t(int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256\n\tbits)) (No client certificate requested)\n\tby mx1.redhat.com (Postfix) with ESMTPS id DAE103F1F5;\n\tWed, 23 Nov 2016 21:00:16 +0000 (UTC)", "from max-t460s.redhat.com (vpn1-5-151.ams2.redhat.com\n\t[10.36.5.151])\n\tby int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with\n\tESMTP id uANL0C8F010760; Wed, 23 Nov 2016 16:00:12 -0500" ], "From": "Maxime Coquelin <maxime.coquelin@redhat.com>", "To": "yuanhan.liu@linux.intel.com, thomas.monjalon@6wind.com,\n\tjohn.mcnamara@intel.com, zhiyong.yang@intel.com, dev@dpdk.org", "Cc": "fbaudin@redhat.com, Maxime Coquelin <maxime.coquelin@redhat.com>", "Date": "Wed, 23 Nov 2016 22:00:06 +0100", "Message-Id": "<20161123210006.7113-1-maxime.coquelin@redhat.com>", "X-Scanned-By": "MIMEDefang 2.68 on 10.5.11.22", "X-Greylist": "Sender IP whitelisted, not delayed by milter-greylist-4.5.16\n\t(mx1.redhat.com [10.5.110.30]); Wed, 23 Nov 2016 21:00:17 +0000 (UTC)", "Subject": "[dpdk-dev] [PATCH] doc: introduce PVP reference benchmark", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.15", "Precedence": "list", "List-Id": "patches and discussions about DPDK <dev.dpdk.org>", "List-Unsubscribe": "<http://dpdk.org/ml/options/dev>,\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>", "List-Archive": "<http://dpdk.org/ml/archives/dev/>", "List-Post": "<mailto:dev@dpdk.org>", "List-Help": "<mailto:dev-request@dpdk.org?subject=help>", "List-Subscribe": "<http://dpdk.org/ml/listinfo/dev>,\n\t<mailto:dev-request@dpdk.org?subject=subscribe>", "Errors-To": "dev-bounces@dpdk.org", "Sender": "\"dev\" <dev-bounces@dpdk.org>" }, "content": "Having reference benchmarks is important in order to obtain\nreproducible performance figures.\n\nThis patch describes required steps to configure a PVP setup\nusing testpmd in both host and guest.\n\nNot relying on external vSwitch ease integration in a CI loop by\nnot being impacted by DPDK API changes.\n\nSigned-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>\n---\n doc/guides/howto/img/pvp_2nics.svg | 556 +++++++++++++++++++++++++++\n doc/guides/howto/index.rst | 1 +\n doc/guides/howto/pvp_reference_benchmark.rst | 389 +++++++++++++++++++\n 3 files changed, 946 insertions(+)\n create mode 100644 doc/guides/howto/img/pvp_2nics.svg\n create mode 100644 doc/guides/howto/pvp_reference_benchmark.rst", "diff": "diff --git a/doc/guides/howto/img/pvp_2nics.svg b/doc/guides/howto/img/pvp_2nics.svg\nnew file mode 100644\nindex 0000000..517a800\n--- /dev/null\n+++ b/doc/guides/howto/img/pvp_2nics.svg\n@@ -0,0 +1,556 @@\n+<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\n+<!-- Created with Inkscape (http://www.inkscape.org/) -->\n+\n+<svg\n+ xmlns:dc=\"http://purl.org/dc/elements/1.1/\"\n+ xmlns:cc=\"http://creativecommons.org/ns#\"\n+ xmlns:rdf=\"http://www.w3.org/1999/02/22-rdf-syntax-ns#\"\n+ xmlns:svg=\"http://www.w3.org/2000/svg\"\n+ xmlns=\"http://www.w3.org/2000/svg\"\n+ xmlns:sodipodi=\"http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd\"\n+ xmlns:inkscape=\"http://www.inkscape.org/namespaces/inkscape\"\n+ width=\"127.46428mm\"\n+ height=\"139.41411mm\"\n+ viewBox=\"0 0 451.64508 493.987\"\n+ id=\"svg2\"\n+ version=\"1.1\"\n+ inkscape:version=\"0.92pre2 r\"\n+ sodipodi:docname=\"pvp_2nics.svg\"\n+ inkscape:export-filename=\"/home/max/Pictures/dpdk/pvp/pvp.png\"\n+ inkscape:export-xdpi=\"90\"\n+ inkscape:export-ydpi=\"90\">\n+ <defs\n+ id=\"defs4\">\n+ <marker\n+ inkscape:stockid=\"Arrow1Lend\"\n+ orient=\"auto\"\n+ refY=\"0\"\n+ refX=\"0\"\n+ id=\"marker4760\"\n+ style=\"overflow:visible\"\n+ inkscape:isstock=\"true\">\n+ <path\n+ inkscape:connector-curvature=\"0\"\n+ id=\"path4762\"\n+ d=\"M 0,0 5,-5 -12.5,0 5,5 Z\"\n+ style=\"fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:#ff0000;stroke-width:1.00000003pt;stroke-opacity:1\"\n+ transform=\"matrix(-0.8,0,0,-0.8,-10,0)\" />\n+ </marker>\n+ <marker\n+ inkscape:stockid=\"Arrow1Lend\"\n+ orient=\"auto\"\n+ refY=\"0\"\n+ refX=\"0\"\n+ id=\"marker4642\"\n+ style=\"overflow:visible\"\n+ inkscape:isstock=\"true\">\n+ <path\n+ inkscape:connector-curvature=\"0\"\n+ id=\"path4644\"\n+ d=\"M 0,0 5,-5 -12.5,0 5,5 Z\"\n+ style=\"fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:#ff0000;stroke-width:1.00000003pt;stroke-opacity:1\"\n+ transform=\"matrix(-0.8,0,0,-0.8,-10,0)\" />\n+ </marker>\n+ <marker\n+ inkscape:stockid=\"Arrow1Lstart\"\n+ orient=\"auto\"\n+ refY=\"0\"\n+ refX=\"0\"\n+ id=\"marker10370\"\n+ style=\"overflow:visible\"\n+ inkscape:isstock=\"true\">\n+ <path\n+ id=\"path10372\"\n+ d=\"M 0,0 5,-5 -12.5,0 5,5 Z\"\n+ style=\"fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:#ff0000;stroke-width:1.00000003pt;stroke-opacity:1\"\n+ transform=\"matrix(0.8,0,0,0.8,10,0)\"\n+ inkscape:connector-curvature=\"0\" />\n+ </marker>\n+ <marker\n+ inkscape:isstock=\"true\"\n+ style=\"overflow:visible\"\n+ id=\"marker10306\"\n+ refX=\"0\"\n+ refY=\"0\"\n+ orient=\"auto\"\n+ inkscape:stockid=\"Arrow1Lend\">\n+ <path\n+ transform=\"matrix(-0.8,0,0,-0.8,-10,0)\"\n+ style=\"fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:#ff0000;stroke-width:1.00000003pt;stroke-opacity:1\"\n+ d=\"M 0,0 5,-5 -12.5,0 5,5 Z\"\n+ id=\"path10308\"\n+ inkscape:connector-curvature=\"0\" />\n+ </marker>\n+ <marker\n+ inkscape:isstock=\"true\"\n+ style=\"overflow:visible\"\n+ id=\"marker9757\"\n+ refX=\"0\"\n+ refY=\"0\"\n+ orient=\"auto\"\n+ inkscape:stockid=\"Arrow1Lend\"\n+ inkscape:collect=\"always\">\n+ <path\n+ transform=\"matrix(-0.8,0,0,-0.8,-10,0)\"\n+ style=\"fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:#ff0000;stroke-width:1.00000003pt;stroke-opacity:1\"\n+ d=\"M 0,0 5,-5 -12.5,0 5,5 Z\"\n+ id=\"path9759\"\n+ inkscape:connector-curvature=\"0\" />\n+ </marker>\n+ <marker\n+ inkscape:stockid=\"Arrow1Lstart\"\n+ orient=\"auto\"\n+ refY=\"0\"\n+ refX=\"0\"\n+ id=\"Arrow1Lstart\"\n+ style=\"overflow:visible\"\n+ inkscape:isstock=\"true\">\n+ <path\n+ id=\"path4224\"\n+ d=\"M 0,0 5,-5 -12.5,0 5,5 Z\"\n+ style=\"fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000003pt;stroke-opacity:1\"\n+ transform=\"matrix(0.8,0,0,0.8,10,0)\"\n+ inkscape:connector-curvature=\"0\" />\n+ </marker>\n+ <marker\n+ inkscape:stockid=\"Arrow1Lend\"\n+ orient=\"auto\"\n+ refY=\"0\"\n+ refX=\"0\"\n+ id=\"Arrow1Lend\"\n+ style=\"overflow:visible\"\n+ inkscape:isstock=\"true\">\n+ <path\n+ id=\"path4227\"\n+ d=\"M 0,0 5,-5 -12.5,0 5,5 Z\"\n+ style=\"fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000003pt;stroke-opacity:1\"\n+ transform=\"matrix(-0.8,0,0,-0.8,-10,0)\"\n+ inkscape:connector-curvature=\"0\" />\n+ </marker>\n+ <marker\n+ inkscape:stockid=\"Arrow1Lend\"\n+ orient=\"auto\"\n+ refY=\"0\"\n+ refX=\"0\"\n+ id=\"Arrow1Lend-1\"\n+ style=\"overflow:visible\"\n+ inkscape:isstock=\"true\">\n+ <path\n+ inkscape:connector-curvature=\"0\"\n+ id=\"path4227-27\"\n+ d=\"M 0,0 5,-5 -12.5,0 5,5 Z\"\n+ style=\"fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000003pt;stroke-opacity:1\"\n+ transform=\"matrix(-0.8,0,0,-0.8,-10,0)\" />\n+ </marker>\n+ <marker\n+ inkscape:stockid=\"Arrow1Lstart\"\n+ orient=\"auto\"\n+ refY=\"0\"\n+ refX=\"0\"\n+ id=\"Arrow1Lstart-9\"\n+ style=\"overflow:visible\"\n+ inkscape:isstock=\"true\">\n+ <path\n+ inkscape:connector-curvature=\"0\"\n+ id=\"path4224-3\"\n+ d=\"M 0,0 5,-5 -12.5,0 5,5 Z\"\n+ style=\"fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000003pt;stroke-opacity:1\"\n+ transform=\"matrix(0.8,0,0,0.8,10,0)\" />\n+ </marker>\n+ <marker\n+ inkscape:isstock=\"true\"\n+ style=\"overflow:visible\"\n+ id=\"marker9757-0\"\n+ refX=\"0\"\n+ refY=\"0\"\n+ orient=\"auto\"\n+ inkscape:stockid=\"Arrow1Lend\">\n+ <path\n+ transform=\"matrix(-0.8,0,0,-0.8,-10,0)\"\n+ style=\"fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:#ff0000;stroke-width:1.00000003pt;stroke-opacity:1\"\n+ d=\"M 0,0 5,-5 -12.5,0 5,5 Z\"\n+ id=\"path9759-6\"\n+ inkscape:connector-curvature=\"0\" />\n+ </marker>\n+ <marker\n+ inkscape:stockid=\"Arrow1Lstart\"\n+ orient=\"auto\"\n+ refY=\"0\"\n+ refX=\"0\"\n+ id=\"Arrow1Lstart-6\"\n+ style=\"overflow:visible\"\n+ inkscape:isstock=\"true\">\n+ <path\n+ inkscape:connector-curvature=\"0\"\n+ id=\"path4224-0\"\n+ d=\"M 0,0 5,-5 -12.5,0 5,5 Z\"\n+ style=\"fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000003pt;stroke-opacity:1\"\n+ transform=\"matrix(0.8,0,0,0.8,10,0)\" />\n+ </marker>\n+ <marker\n+ inkscape:stockid=\"Arrow1Lend\"\n+ orient=\"auto\"\n+ refY=\"0\"\n+ refX=\"0\"\n+ id=\"Arrow1Lend-62\"\n+ style=\"overflow:visible\"\n+ inkscape:isstock=\"true\">\n+ <path\n+ inkscape:connector-curvature=\"0\"\n+ id=\"path4227-6\"\n+ d=\"M 0,0 5,-5 -12.5,0 5,5 Z\"\n+ style=\"fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000003pt;stroke-opacity:1\"\n+ transform=\"matrix(-0.8,0,0,-0.8,-10,0)\" />\n+ </marker>\n+ <marker\n+ inkscape:stockid=\"Arrow1Lstart\"\n+ orient=\"auto\"\n+ refY=\"0\"\n+ refX=\"0\"\n+ id=\"marker10370-7\"\n+ style=\"overflow:visible\"\n+ inkscape:isstock=\"true\">\n+ <path\n+ inkscape:connector-curvature=\"0\"\n+ id=\"path10372-9\"\n+ d=\"M 0,0 5,-5 -12.5,0 5,5 Z\"\n+ style=\"fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:#ff0000;stroke-width:1.00000003pt;stroke-opacity:1\"\n+ transform=\"matrix(0.8,0,0,0.8,10,0)\" />\n+ </marker>\n+ <marker\n+ inkscape:isstock=\"true\"\n+ style=\"overflow:visible\"\n+ id=\"marker9757-2\"\n+ refX=\"0\"\n+ refY=\"0\"\n+ orient=\"auto\"\n+ inkscape:stockid=\"Arrow1Lend\">\n+ <path\n+ transform=\"matrix(-0.8,0,0,-0.8,-10,0)\"\n+ style=\"fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:#ff0000;stroke-width:1.00000003pt;stroke-opacity:1\"\n+ d=\"M 0,0 5,-5 -12.5,0 5,5 Z\"\n+ id=\"path9759-0\"\n+ inkscape:connector-curvature=\"0\" />\n+ </marker>\n+ <marker\n+ inkscape:stockid=\"Arrow1Lstart\"\n+ orient=\"auto\"\n+ refY=\"0\"\n+ refX=\"0\"\n+ id=\"Arrow1Lstart-9-2\"\n+ style=\"overflow:visible\"\n+ inkscape:isstock=\"true\">\n+ <path\n+ inkscape:connector-curvature=\"0\"\n+ id=\"path4224-3-3\"\n+ d=\"M 0,0 5,-5 -12.5,0 5,5 Z\"\n+ style=\"fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000003pt;stroke-opacity:1\"\n+ transform=\"matrix(0.8,0,0,0.8,10,0)\" />\n+ </marker>\n+ <marker\n+ inkscape:stockid=\"Arrow1Lend\"\n+ orient=\"auto\"\n+ refY=\"0\"\n+ refX=\"0\"\n+ id=\"Arrow1Lend-1-7\"\n+ style=\"overflow:visible\"\n+ inkscape:isstock=\"true\">\n+ <path\n+ inkscape:connector-curvature=\"0\"\n+ id=\"path4227-27-5\"\n+ d=\"M 0,0 5,-5 -12.5,0 5,5 Z\"\n+ style=\"fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000003pt;stroke-opacity:1\"\n+ transform=\"matrix(-0.8,0,0,-0.8,-10,0)\" />\n+ </marker>\n+ </defs>\n+ <sodipodi:namedview\n+ id=\"base\"\n+ pagecolor=\"#ffffff\"\n+ bordercolor=\"#666666\"\n+ borderopacity=\"1.0\"\n+ inkscape:pageopacity=\"0.0\"\n+ inkscape:pageshadow=\"2\"\n+ inkscape:zoom=\"0.49497475\"\n+ inkscape:cx=\"206.7485\"\n+ inkscape:cy=\"227.93958\"\n+ inkscape:document-units=\"px\"\n+ inkscape:current-layer=\"layer1\"\n+ showgrid=\"false\"\n+ inkscape:object-nodes=\"true\"\n+ inkscape:window-width=\"1916\"\n+ inkscape:window-height=\"1040\"\n+ inkscape:window-x=\"0\"\n+ inkscape:window-y=\"38\"\n+ inkscape:window-maximized=\"0\"\n+ inkscape:snap-grids=\"true\"\n+ inkscape:snap-to-guides=\"true\"\n+ inkscape:snap-others=\"false\"\n+ inkscape:snap-nodes=\"false\"\n+ inkscape:snap-global=\"false\" />\n+ <metadata\n+ id=\"metadata7\">\n+ <rdf:RDF>\n+ <cc:Work\n+ rdf:about=\"\">\n+ <dc:format>image/svg+xml</dc:format>\n+ <dc:type\n+ rdf:resource=\"http://purl.org/dc/dcmitype/StillImage\" />\n+ <dc:title></dc:title>\n+ </cc:Work>\n+ </rdf:RDF>\n+ </metadata>\n+ <g\n+ inkscape:label=\"Layer 1\"\n+ inkscape:groupmode=\"layer\"\n+ id=\"layer1\"\n+ transform=\"translate(-5.3301459,-7.348317)\">\n+ <rect\n+ style=\"fill:none;fill-opacity:1;stroke:#000000;stroke-width:1.78969002;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1\"\n+ id=\"rect4140\"\n+ width=\"434.38919\"\n+ height=\"75.295639\"\n+ x=\"21.691195\"\n+ y=\"404.59354\" />\n+ <text\n+ xml:space=\"preserve\"\n+ style=\"font-style:normal;font-weight:normal;font-size:40px;line-height:125%;font-family:sans-serif;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1\"\n+ x=\"421.47873\"\n+ y=\"501.3353\"\n+ id=\"text4142\"><tspan\n+ sodipodi:role=\"line\"\n+ id=\"tspan4144\"\n+ x=\"421.47873\"\n+ y=\"501.3353\"\n+ style=\"font-size:25px;line-height:125%\">TE</tspan></text>\n+ <rect\n+ style=\"fill:none;fill-opacity:1;stroke:#000000;stroke-width:1.46599996;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1\"\n+ id=\"rect4146\"\n+ width=\"92.934036\"\n+ height=\"32.324883\"\n+ x=\"182.57764\"\n+ y=\"372.03574\" />\n+ <text\n+ xml:space=\"preserve\"\n+ style=\"font-style:normal;font-weight:normal;font-size:40px;line-height:125%;font-family:sans-serif;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1\"\n+ x=\"183.5878\"\n+ y=\"397.28958\"\n+ id=\"text4148\"><tspan\n+ sodipodi:role=\"line\"\n+ id=\"tspan4150\"\n+ x=\"183.5878\"\n+ y=\"397.28958\"\n+ style=\"font-size:25px\">10G NIC</tspan></text>\n+ <text\n+ xml:space=\"preserve\"\n+ style=\"font-style:normal;font-weight:normal;font-size:40px;line-height:125%;font-family:sans-serif;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1\"\n+ x=\"166.92024\"\n+ y=\"451.33276\"\n+ id=\"text4152\"><tspan\n+ sodipodi:role=\"line\"\n+ id=\"tspan4154\"\n+ x=\"166.92024\"\n+ y=\"451.33276\">Moongen</tspan></text>\n+ <rect\n+ style=\"fill:none;fill-opacity:1;stroke:#000000;stroke-width:1.39882457;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1\"\n+ id=\"rect4156\"\n+ width=\"449.73071\"\n+ height=\"244.32167\"\n+ x=\"6.0295582\"\n+ y=\"29.046324\" />\n+ <text\n+ xml:space=\"preserve\"\n+ style=\"font-style:normal;font-weight:normal;font-size:40px;line-height:125%;font-family:sans-serif;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1\"\n+ x=\"405.31628\"\n+ y=\"25.048317\"\n+ id=\"text4158\"><tspan\n+ sodipodi:role=\"line\"\n+ id=\"tspan4160\"\n+ x=\"405.31628\"\n+ y=\"25.048317\"\n+ style=\"font-size:25px\">DUT</tspan></text>\n+ <rect\n+ style=\"fill:none;fill-opacity:1;stroke:#000000;stroke-width:1.14168489;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1\"\n+ id=\"rect4162\"\n+ width=\"418.69415\"\n+ height=\"107.50462\"\n+ x=\"19.038134\"\n+ y=\"41.044758\" />\n+ <text\n+ xml:space=\"preserve\"\n+ style=\"font-style:normal;font-weight:normal;font-size:40px;line-height:125%;font-family:sans-serif;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1\"\n+ x=\"395.38812\"\n+ y=\"66.496857\"\n+ id=\"text4164\"><tspan\n+ sodipodi:role=\"line\"\n+ id=\"tspan4166\"\n+ x=\"395.38812\"\n+ y=\"66.496857\"\n+ style=\"font-size:25px\">VM</tspan></text>\n+ <rect\n+ style=\"fill:none;fill-opacity:1;stroke:#000000;stroke-width:1.46599996;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1\"\n+ id=\"rect4146-3\"\n+ width=\"92.934036\"\n+ height=\"32.324883\"\n+ x=\"183.0827\"\n+ y=\"274.05093\" />\n+ <text\n+ xml:space=\"preserve\"\n+ style=\"font-style:normal;font-weight:normal;font-size:40px;line-height:125%;font-family:sans-serif;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1\"\n+ x=\"184.09286\"\n+ y=\"299.30475\"\n+ id=\"text4148-6\"><tspan\n+ sodipodi:role=\"line\"\n+ id=\"tspan4150-7\"\n+ x=\"184.09286\"\n+ y=\"299.30475\"\n+ style=\"font-size:25px\">10G NIC</tspan></text>\n+ <rect\n+ style=\"fill:none;fill-opacity:1;stroke:#000000;stroke-width:2.4804399;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1\"\n+ id=\"rect4189\"\n+ width=\"398.00476\"\n+ height=\"65.451302\"\n+ x=\"26.901583\"\n+ y=\"82.647781\" />\n+ <text\n+ xml:space=\"preserve\"\n+ style=\"font-style:normal;font-weight:normal;font-size:25px;line-height:125%;font-family:sans-serif;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1\"\n+ x=\"30.683046\"\n+ y=\"108.31288\"\n+ id=\"text4191\"><tspan\n+ sodipodi:role=\"line\"\n+ id=\"tspan4193\"\n+ x=\"30.683046\"\n+ y=\"108.31288\">TestPMD</tspan><tspan\n+ sodipodi:role=\"line\"\n+ x=\"30.683046\"\n+ y=\"139.56288\"\n+ id=\"tspan10476\">(macswap)</tspan></text>\n+ <rect\n+ style=\"fill:none;fill-opacity:1;stroke:#000000;stroke-width:2.49124122;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1\"\n+ id=\"rect4189-5\"\n+ width=\"397.22263\"\n+ height=\"66.152573\"\n+ x=\"29.743357\"\n+ y=\"207.6543\" />\n+ <text\n+ xml:space=\"preserve\"\n+ style=\"font-style:normal;font-weight:normal;font-size:25px;line-height:125%;font-family:sans-serif;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1\"\n+ x=\"42.720772\"\n+ y=\"231.14902\"\n+ id=\"text4191-3\"><tspan\n+ sodipodi:role=\"line\"\n+ id=\"tspan4193-5\"\n+ x=\"42.720772\"\n+ y=\"231.14902\">TestPMD </tspan><tspan\n+ sodipodi:role=\"line\"\n+ x=\"42.720772\"\n+ y=\"262.39902\"\n+ id=\"tspan9747\">(io)</tspan></text>\n+ <path\n+ style=\"fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:0.97838062px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow1Lend)\"\n+ d=\"M 202.56669,371.44487 V 308.37034\"\n+ id=\"path4218\"\n+ inkscape:connector-curvature=\"0\" />\n+ <path\n+ style=\"fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.97297633px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#Arrow1Lstart)\"\n+ d=\"M 252.03098,369.63533 V 307.25568\"\n+ id=\"path4218-9\"\n+ inkscape:connector-curvature=\"0\" />\n+ <path\n+ style=\"fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:0.92982113px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow1Lend-1)\"\n+ d=\"M 198.63811,207.44389 V 150.47507\"\n+ id=\"path4218-0\"\n+ inkscape:connector-curvature=\"0\" />\n+ <path\n+ style=\"fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.95360273px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#Arrow1Lstart-9)\"\n+ d=\"M 255.56859,206.9303 V 147.01008\"\n+ id=\"path4218-9-6\"\n+ inkscape:connector-curvature=\"0\" />\n+ <path\n+ style=\"fill:none;fill-rule:evenodd;stroke:#ff0000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:3, 1;stroke-dashoffset:0;stroke-opacity:1;marker-end:url(#marker9757)\"\n+ d=\"M 199.50513,271.00921 V 207.3696\"\n+ id=\"path9749\"\n+ inkscape:connector-curvature=\"0\" />\n+ <path\n+ style=\"fill:none;fill-rule:evenodd;stroke:#ff0000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:3, 1;stroke-dashoffset:0;stroke-opacity:1;marker-start:url(#marker10370)\"\n+ d=\"M 255.56859,270.56991 V 206.9303\"\n+ id=\"path9749-2\"\n+ inkscape:connector-curvature=\"0\" />\n+ <rect\n+ style=\"fill:none;fill-opacity:1;stroke:#000000;stroke-width:1.46599996;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1\"\n+ id=\"rect4146-36\"\n+ width=\"92.934036\"\n+ height=\"32.324883\"\n+ x=\"304.05591\"\n+ y=\"372.52954\" />\n+ <text\n+ xml:space=\"preserve\"\n+ style=\"font-style:normal;font-weight:normal;font-size:40px;line-height:125%;font-family:sans-serif;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1\"\n+ x=\"305.06607\"\n+ y=\"397.78339\"\n+ id=\"text4148-7\"><tspan\n+ sodipodi:role=\"line\"\n+ id=\"tspan4150-5\"\n+ x=\"305.06607\"\n+ y=\"397.78339\"\n+ style=\"font-size:25px\">10G NIC</tspan></text>\n+ <rect\n+ style=\"fill:none;fill-opacity:1;stroke:#000000;stroke-width:1.46599996;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1\"\n+ id=\"rect4146-3-3\"\n+ width=\"92.934036\"\n+ height=\"32.324883\"\n+ x=\"306.07623\"\n+ y=\"273.53461\" />\n+ <text\n+ xml:space=\"preserve\"\n+ style=\"font-style:normal;font-weight:normal;font-size:40px;line-height:125%;font-family:sans-serif;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1\"\n+ x=\"307.0864\"\n+ y=\"298.78842\"\n+ id=\"text4148-6-5\"><tspan\n+ sodipodi:role=\"line\"\n+ id=\"tspan4150-7-6\"\n+ x=\"307.0864\"\n+ y=\"298.78842\"\n+ style=\"font-size:25px\">10G NIC</tspan></text>\n+ <path\n+ style=\"fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:0.97838062px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow1Lend-62)\"\n+ d=\"M 323.7504,370.24835 V 307.17382\"\n+ id=\"path4218-1\"\n+ inkscape:connector-curvature=\"0\" />\n+ <path\n+ style=\"fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.97297633px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#Arrow1Lstart-6)\"\n+ d=\"M 373.21469,368.43881 V 306.05916\"\n+ id=\"path4218-9-8\"\n+ inkscape:connector-curvature=\"0\" />\n+ <path\n+ style=\"fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:0.92982113px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow1Lend-1-7)\"\n+ d=\"M 324.93036,207.24894 V 150.28012\"\n+ id=\"path4218-0-9\"\n+ inkscape:connector-curvature=\"0\" />\n+ <path\n+ style=\"fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.95360273px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#Arrow1Lstart-9-2)\"\n+ d=\"M 381.86084,206.73535 V 146.81513\"\n+ id=\"path4218-9-6-2\"\n+ inkscape:connector-curvature=\"0\" />\n+ <path\n+ style=\"fill:none;fill-rule:evenodd;stroke:#ff0000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:3, 1;stroke-dashoffset:0;stroke-opacity:1;marker-end:url(#marker9757-2)\"\n+ d=\"M 325.79738,270.81426 V 207.17465\"\n+ id=\"path9749-28\"\n+ inkscape:connector-curvature=\"0\" />\n+ <path\n+ style=\"fill:none;fill-rule:evenodd;stroke:#ff0000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:3, 1;stroke-dashoffset:0;stroke-opacity:1;marker-start:url(#marker10370-7)\"\n+ d=\"M 381.86084,270.37496 V 206.73535\"\n+ id=\"path9749-2-9\"\n+ inkscape:connector-curvature=\"0\" />\n+ <path\n+ style=\"fill:none;fill-rule:evenodd;stroke:#ff0000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:2, 1;stroke-dashoffset:0;stroke-opacity:1;marker-end:url(#marker4642)\"\n+ d=\"M 198.57143,148.79077 V 95.93363 h 182.85714 v 50\"\n+ id=\"path3748\"\n+ inkscape:connector-curvature=\"0\" />\n+ <path\n+ style=\"fill:none;fill-rule:evenodd;stroke:#ff0000;stroke-width:1.01005316;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:2.02010632, 1.01005316;stroke-dashoffset:0;stroke-opacity:1;marker-end:url(#marker4760)\"\n+ d=\"m 325.70774,148.78714 v -32.84999 h -70.7012 v 30.70761\"\n+ id=\"path4634\"\n+ inkscape:connector-curvature=\"0\" />\n+ </g>\n+</svg>\ndiff --git a/doc/guides/howto/index.rst b/doc/guides/howto/index.rst\nindex 5575b27..712a9f3 100644\n--- a/doc/guides/howto/index.rst\n+++ b/doc/guides/howto/index.rst\n@@ -38,3 +38,4 @@ HowTo Guides\n lm_bond_virtio_sriov\n lm_virtio_vhost_user\n flow_bifurcation\n+ pvp_reference_benchmark\ndiff --git a/doc/guides/howto/pvp_reference_benchmark.rst b/doc/guides/howto/pvp_reference_benchmark.rst\nnew file mode 100644\nindex 0000000..042c6aa\n--- /dev/null\n+++ b/doc/guides/howto/pvp_reference_benchmark.rst\n@@ -0,0 +1,389 @@\n+.. BSD LICENSE\n+ Copyright(c) 2016 Red Hat, Inc. All rights reserved.\n+ All rights reserved.\n+\n+ Redistribution and use in source and binary forms, with or without\n+ modification, are permitted provided that the following conditions\n+ are met:\n+\n+ * Redistributions of source code must retain the above copyright\n+ notice, this list of conditions and the following disclaimer.\n+ * Redistributions in binary form must reproduce the above copyright\n+ notice, this list of conditions and the following disclaimer in\n+ the documentation and/or other materials provided with the\n+ distribution.\n+ * Neither the name of Intel Corporation nor the names of its\n+ contributors may be used to endorse or promote products derived\n+ from this software without specific prior written permission.\n+\n+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS\n+ \"AS IS\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT\n+ LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR\n+ A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT\n+ OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,\n+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,\n+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY\n+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\n+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\n+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n+\n+PVP reference benchmark setup using testpmd\n+===========================================\n+\n+This guide lists the steps required to setup PVP benchmark using testpmd as a\n+simple forwarder between NICs and Vhost interfaces. The goal of this setup is\n+to have a reference PVP benchmark not using external vSwitches (OVS, VPP, ...),\n+making easier to obtain reproducible results and easing continuous integration\n+testing.\n+\n+The guide covers two way for launching the VM, either by calling directly QEMU\n+command line, or by relying on libvirt. It has been tested working with DPDK\n+v16.11, using RHEL7 for both host and guest.\n+\n+Setup overview\n+..............\n+\n+.. figure:: img/pvp_2nics.svg\n+\n+ PVP setup using 2 NICs\n+\n+In this diagram, each red arrow represents one logical core. This use-case\n+requires 6 dedicated logical cores. A setup consisting in doing forwarding\n+with a single NIC is also possible, requiring 3 logical cores. \n+\n+Host setup\n+..........\n+\n+In this setup, we isolate 6 cores (from CPU2 to CPU7) in a same NUMA node. Two\n+cores are assigned to the VM vCPUs running testpmd, four are assigned to\n+testpmd on host.\n+\n+Host tuning\n+~~~~~~~~~~~\n+\n+#. Append these options to Kernel command line:\n+\n+ .. code-block:: console\n+\n+ intel_pstate=disable mce=ignore_ce default_hugepagesz=1G hugepagesz=1G hugepages=6 isolcpus=2-7 rcu_nocbs=2-7 nohz_full=2-7 iommu=pt intel_iommu=on\n+\n+#. Disable hyper-threads at runtime if necessary and BIOS not accessible:\n+\n+ .. code-block:: console\n+\n+ cat /sys/devices/system/cpu/cpu*[0-9]/topology/thread_siblings_list \\\n+ | sort | uniq \\\n+ | awk -F, '{system(\"echo 0 > /sys/devices/system/cpu/cpu\"$2\"/online\")}'\n+\n+#. Disable NMIs:\n+\n+ .. code-block:: console\n+\n+ echo 0 > /proc/sys/kernel/nmi_watchdog\n+\n+#. Exclude isolated CPUs from the writeback cpumask:\n+\n+ .. code-block:: console\n+\n+ echo ffffff03 > /sys/bus/workqueue/devices/writeback/cpumask\n+\n+#. Isolate CPUs from IRQs:\n+\n+ .. code-block:: console\n+\n+ clear_mask=0xfc #Isolate CPU2 to CPU7 from IRQs\n+ for i in /proc/irq/*/smp_affinity\n+ do\n+ echo \"obase=16;$(( 0x$(cat $i) & ~$clear_mask ))\" | bc > $i\n+ done\n+\n+Qemu build\n+~~~~~~~~~~\n+\n+ .. code-block:: console\n+\n+ git clone git://dpdk.org/dpdk\n+ cd dpdk\n+ export RTE_SDK=$PWD\n+ make install T=x86_64-native-linuxapp-gcc DESTDIR=install\n+\n+DPDK build\n+~~~~~~~~~~\n+\n+ .. code-block:: console\n+\n+ git clone git://dpdk.org/dpdk\n+ cd dpdk\n+ export RTE_SDK=$PWD\n+ make install T=x86_64-native-linuxapp-gcc DESTDIR=install\n+\n+Testpmd launch\n+~~~~~~~~~~~~~~\n+\n+#. Assign NICs to DPDK:\n+\n+ .. code-block:: console\n+\n+ modprobe vfio-pci\n+ $RTE_SDK/install/sbin/dpdk-devbind -b vfio-pci 0000:11:00.0 0000:11:00.1\n+\n+*Note: Sandy Bridge family seems to have some limitations wrt its IOMMU,\n+giving poor performance results. To achieve good performance on these machines,\n+consider using UIO instead.*\n+\n+#. Launch testpmd application:\n+\n+ .. code-block:: console\n+\n+ $RTE_SDK/install/bin/testpmd -l 0,2,3,4,5 --socket-mem=1024 -n 4 \\\n+ --vdev 'net_vhost0,iface=/tmp/vhost-user1' \\\n+ --vdev 'net_vhost1,iface=/tmp/vhost-user2' -- \\\n+ --portmask=f --disable-hw-vlan -i --rxq=1 --txq=1\n+ --nb-cores=4 --forward-mode=io\n+\n+#. In testpmd interactive mode, set the portlist to obtin the right chaining:\n+\n+ .. code-block:: console\n+\n+ set portlist 0,2,1,3\n+ start\n+\n+VM launch\n+~~~~~~~~~\n+\n+The VM may be launched ezither by calling directly QEMU, or by using libvirt.\n+\n+#. Qemu way:\n+\n+Launch QEMU with two Virtio-net devices paired to the vhost-user sockets created by testpmd:\n+\n+ .. code-block:: console\n+\n+ <QEMU path>/bin/x86_64-softmmu/qemu-system-x86_64 \\\n+ -enable-kvm -cpu host -m 3072 -smp 3 \\\n+ -chardev socket,id=char0,path=/tmp/vhost-user1 \\\n+ -netdev type=vhost-user,id=mynet1,chardev=char0,vhostforce \\\n+ -device virtio-net-pci,netdev=mynet1,mac=52:54:00:02:d9:01,addr=0x10 \\\n+ -chardev socket,id=char1,path=/tmp/vhost-user2 \\\n+ -netdev type=vhost-user,id=mynet2,chardev=char1,vhostforce \\\n+ -device virtio-net-pci,netdev=mynet2,mac=52:54:00:02:d9:02,addr=0x11 \\\n+ -object memory-backend-file,id=mem,size=3072M,mem-path=/dev/hugepages,share=on \\\n+ -numa node,memdev=mem -mem-prealloc \\\n+ -net user,hostfwd=tcp::1002$1-:22 -net nic \\\n+ -qmp unix:/tmp/qmp.socket,server,nowait \\\n+ -monitor stdio <vm_image>.qcow2\n+\n+You can use this qmp-vcpu-pin script to pin vCPUs:\n+\n+ .. code-block:: python\n+\n+ #!/usr/bin/python\n+ # QEMU vCPU pinning tool\n+ #\n+ # Copyright (C) 2016 Red Hat Inc.\n+ #\n+ # Authors:\n+ # Maxime Coquelin <maxime.coquelin@redhat.com>\n+ #\n+ # This work is licensed under the terms of the GNU GPL, version 2. See\n+ # the COPYING file in the top-level directory\n+ import argparse\n+ import json\n+ import os\n+\n+ from subprocess import call\n+ from qmp import QEMUMonitorProtocol\n+\n+ pinned = []\n+\n+ parser = argparse.ArgumentParser(description='Pin QEMU vCPUs to physical CPUs')\n+ parser.add_argument('-s', '--server', type=str, required=True,\n+ help='QMP server path or address:port')\n+ parser.add_argument('cpu', type=int, nargs='+',\n+ help='Physical CPUs IDs')\n+ args = parser.parse_args()\n+\n+ devnull = open(os.devnull, 'w')\n+\n+ srv = QEMUMonitorProtocol(args.server)\n+ srv.connect()\n+\n+ for vcpu in srv.command('query-cpus'):\n+ vcpuid = vcpu['CPU']\n+ tid = vcpu['thread_id']\n+ if tid in pinned:\n+ print 'vCPU{}\\'s tid {} already pinned, skipping'.format(vcpuid, tid)\n+ continue\n+\n+ cpuid = args.cpu[vcpuid % len(args.cpu)]\n+ print 'Pin vCPU {} (tid {}) to physical CPU {}'.format(vcpuid, tid, cpuid)\n+ try:\n+ call(['taskset', '-pc', str(cpuid), str(tid)], stdout=devnull)\n+ pinned.append(tid)\n+ except OSError:\n+ print 'Failed to pin vCPU{} to CPU{}'.format(vcpuid, cpuid)\n+\n+\n+That can be used this way, for example to pin 3 vCPUs to CPUs 1, 6 and 7:\n+\n+ .. code-block:: console\n+\n+ export PYTHONPATH=$PYTHONPATH:<QEMU path>/scripts/qmp\n+ ./qmp-vcpu-pin -s /tmp/qmp.socket 1 6 7\n+\n+#. Libvirt way:\n+\n+Some initial steps are required for libvirt to be able to connect to testpmd's\n+sockets.\n+\n+First, SELinux policy needs to be set to permissiven, as testpmd is run as root\n+(reboot required):\n+\n+ .. code-block:: console\n+\n+ cat /etc/selinux/config\n+\n+ # This file controls the state of SELinux on the system.\n+ # SELINUX= can take one of these three values:\n+ # enforcing - SELinux security policy is enforced.\n+ # permissive - SELinux prints warnings instead of enforcing.\n+ # disabled - No SELinux policy is loaded.\n+ SELINUX=permissive\n+ # SELINUXTYPE= can take one of three two values:\n+ # targeted - Targeted processes are protected,\n+ # minimum - Modification of targeted policy. Only selected processes are protected. \n+ # mls - Multi Level Security protection.\n+ SELINUXTYPE=targeted\n+\n+\n+Also, Qemu needs to be run as root, which has to be specified in /etc/libvirt/qemu.conf:\n+\n+ .. code-block:: console\n+\n+ user = \"root\"\n+\n+Once the domain created, following snippset is an extract of most important\n+information (hugepages, vCPU pinning, Virtio PCI devices):\n+\n+ .. code-block:: xml\n+\n+ <domain type='kvm'>\n+ <memory unit='KiB'>3145728</memory>\n+ <currentMemory unit='KiB'>3145728</currentMemory>\n+ <memoryBacking>\n+ <hugepages>\n+ <page size='1048576' unit='KiB' nodeset='0'/>\n+ </hugepages>\n+ <locked/>\n+ </memoryBacking>\n+ <vcpu placement='static'>3</vcpu>\n+ <cputune>\n+ <vcpupin vcpu='0' cpuset='1'/>\n+ <vcpupin vcpu='1' cpuset='6'/>\n+ <vcpupin vcpu='2' cpuset='7'/>\n+ <emulatorpin cpuset='0'/>\n+ </cputune>\n+ <numatune>\n+ <memory mode='strict' nodeset='0'/>\n+ </numatune>\n+ <os>\n+ <type arch='x86_64' machine='pc-i440fx-rhel7.0.0'>hvm</type>\n+ <boot dev='hd'/>\n+ </os>\n+ <cpu mode='host-passthrough'>\n+ <topology sockets='1' cores='3' threads='1'/>\n+ <numa>\n+ <cell id='0' cpus='0-2' memory='3145728' unit='KiB' memAccess='shared'/>\n+ </numa>\n+ </cpu>\n+ <devices>\n+ <interface type='vhostuser'>\n+ <mac address='56:48:4f:53:54:01'/>\n+ <source type='unix' path='/tmp/vhost-user1' mode='client'/>\n+ <model type='virtio'/>\n+ <driver name='vhost' rx_queue_size='256' />\n+ <address type='pci' domain='0x0000' bus='0x00' slot='0x10' function='0x0'/>\n+ </interface>\n+ <interface type='vhostuser'>\n+ <mac address='56:48:4f:53:54:02'/>\n+ <source type='unix' path='/tmp/vhost-user2' mode='client'/>\n+ <model type='virtio'/>\n+ <driver name='vhost' rx_queue_size='256' />\n+ <address type='pci' domain='0x0000' bus='0x00' slot='0x11' function='0x0'/>\n+ </interface>\n+ </devices>\n+ </domain>\n+\n+Guest setup\n+...........\n+\n+Guest tuning\n+~~~~~~~~~~~~\n+\n+#. Append these options to Kernel command line:\n+\n+ .. code-block:: console\n+\n+ default_hugepagesz=1G hugepagesz=1G hugepages=1 intel_iommu=on iommu=pt isolcpus=1,2 rcu_nocbs=1,2 nohz_full=1,2\n+\n+#. Disable NMIs:\n+\n+ .. code-block:: console\n+\n+ echo 0 > /proc/sys/kernel/nmi_watchdog\n+\n+#. Exclude isolated CPU1 and CPU2 from the writeback wq cpumask:\n+\n+ .. code-block:: console\n+\n+ echo 1 > /sys/bus/workqueue/devices/writeback/cpumask\n+\n+#. Isolate CPUs from IRQs:\n+\n+ .. code-block:: console\n+\n+ clear_mask=0x6 #Isolate CPU1 and CPU2 from IRQs\n+ for i in /proc/irq/*/smp_affinity\n+ do\n+ echo \"obase=16;$(( 0x$(cat $i) & ~$clear_mask ))\" | bc > $i\n+ done\n+\n+DPDK build\n+~~~~~~~~~~\n+\n+ .. code-block:: console\n+\n+ git clone git://dpdk.org/dpdk\n+ cd dpdk\n+ export RTE_SDK=$PWD\n+ make install T=x86_64-native-linuxapp-gcc DESTDIR=install\n+\n+Testpmd launch\n+~~~~~~~~~~~~~~\n+\n+Probe vfio module without iommu:\n+\n+ .. code-block:: console\n+\n+ modprobe -r vfio_iommu_type1\n+ modprobe -r vfio\n+ modprobe vfio enable_unsafe_noiommu_mode=1\n+ cat /sys/module/vfio/parameters/enable_unsafe_noiommu_mode\n+ modprobe vfio-pci\n+\n+Bind virtio-net devices to DPDK:\n+\n+ .. code-block:: console\n+\n+ $RTE_SDK/tools/dpdk-devbind.py -b vfio-pci 0000:00:10.0 0000:00:11.0\n+\n+Start testpmd:\n+\n+ .. code-block:: console\n+\n+ $RTE_SDK/install/bin/testpmd -l 0,1,2 --socket-mem 1024 -n 4 \\\n+ --proc-type auto --file-prefix pg -- \\\n+ --portmask=3 --forward-mode=macswap --port-topology=chained \\\n+ --disable-hw-vlan --disable-rss -i --rxq=1 --txq=1 \\\n+ --rxd=256 --txd=256 --nb-cores=2 --auto-start\n", "prefixes": [ "dpdk-dev" ] }{ "id": 17208, "url": "