From: x-fn-spp@sl.ntt-tx.co.jp
To: spp@dpdk.org
Subject: [spp] [PATCH 03/30] doc: add config_manual.md
Date: Tue, 16 Jan 2018 14:16:14 +0900 [thread overview]
Message-ID: <201801160516.w0G5GfsP009098@imss03.silk.ntt-tx.co.jp> (raw)
In-Reply-To: <3e13a243-6c3f-d849-f2f4-67732e5a44cb@intel.com>
From: Hiroyuki Nakamura <nakamura.hioryuki@po.ntt-tx.co.jp>
config_manual.md is a detailed manual for JSON config file.
Signed-off-by: Naoki Takada <takada.naoki@lab.ntt.co.jp>
---
docs/spp_vf/config_manual.md | 214 +++++++++++++++++++++++++++++++++++++++++++
1 file changed, 214 insertions(+)
create mode 100644 docs/spp_vf/config_manual.md
diff --git a/docs/spp_vf/config_manual.md b/docs/spp_vf/config_manual.md
new file mode 100644
index 0000000..370dfdb
--- /dev/null
+++ b/docs/spp_vf/config_manual.md
@@ -0,0 +1,214 @@
+# SPP_VF Config Manual
+
+## Forwarder Type
+
+There are three types of forwarder for 1:1, 1:N and N:1.
+
+ * forward: 1:1
+ * classifier_mac: 1:N (Destination is determined by MAC address)
+ * merge: N:1
+
+### Restrictions
+
+ * Different types of forwarder cannot assing on same core.
+ * Only one classifier_mac is allowed (Cannot use two or more).
+
+## Port Type
+
+There are three port types.
+
+ * nic: Physical NIC
+ * vhost: Vhost PMD for VMs
+ * ring: Ring PMD for spp components
+
+Each of ports is identified as resource ID with port type and resource ID.
+For example, resource ID of physical NIC of ID 0 is described as `nic0`.
+
+## Config Format
+
+Config files is described in JSON format.
+It consists of `vfs` and `classifier_table`.
+`vfs` defines each of spp_vf attributes and
+`classifier_table` defines MAC address and correnpond port for
+determining destination.
+
+### Attributes in Config
+
+ * vfs
+ * name: Name of spp_vf component.
+ * num_vhost: Number of vhosts spp_vf use.
+ * num_ring: Number of rings spp_vf use.
+ * functions: List of forwarders and its attributes (function means a forwarder).
+ * core: Core ID forwarder running on.
+ * type: Forwarder type (`forward`, `classifier_mac`, or `merger`).
+ * rx_port: Resource ID(s) of rx port.
+ * tx_port: Resource ID of tx port. If 1:N, which means the dest is `classifier_mac`,
+ directly described as `classifier_mac_table`.
+
+ * classifier_table
+ * name: Table name for classifier_mac, It MUST be "classifier_mac_table" in current implementation
+ * table: Set of MAC address and port for destination
+ * mac: MAC address
+ * port: Resource ID of port
+
+## Sample Config
+
+Here is default config `spp.json` and network diagram of it.
+
+```json
+{
+ "vfs": [
+ {
+ "name": "vf0",
+ "num_vhost": 4, // Number of vhosts
+ "num_ring": 9, // Number of rings
+ "functions":[ // Attributes of forward,merge or classifier_mac
+ {
+ "core": 2, // Core ID
+ "type": "merge", // Forwarder type
+ "rx_port": ["nic0", "nic1"], // Rx port, It MUST be a list for merge type
+ "tx_port": "ring8" // Tx port
+ },
+ {
+ "core": 3,
+ "type": "classifier_mac",
+ "rx_port": "ring8", // Rx port, It is not a list because type is classifier_mac
+ "tx_port_table": "classifier_mac_table" // If type is classifier_mac, tx is classifier_mac_table
+ },
+
+ {
+ "core": 4,
+ "type": "forward",
+ "rx_port": "ring0",
+ "tx_port": "vhost0"
+ },
+ {
+ "core": 5,
+ "type": "forward",
+ "rx_port": "ring1",
+ "tx_port": "vhost2"
+ },
+ {
+ "core": 6,
+ "type": "forward",
+ "rx_port": "vhost0",
+ "tx_port": "ring2"
+ },
+ {
+ "core": 7,
+ "type": "forward",
+ "rx_port": "vhost2",
+ "tx_port": "ring3"
+ },
+ {
+ "core": 8,
+ "type": "merge",
+ "rx_port": ["ring2", "ring3"],
+ "tx_port": "nic0"
+ },
+
+ {
+ "core": 9,
+ "type": "forward",
+ "rx_port": "ring4",
+ "tx_port": "vhost1"
+ },
+ {
+ "core": 10,
+ "type": "forward",
+ "rx_port": "ring5",
+ "tx_port": "vhost3"
+ },
+ {
+ "core": 11,
+ "type": "forward",
+ "rx_port": "vhost1",
+ "tx_port": "ring6"
+ },
+ {
+ "core": 12,
+ "type": "forward",
+ "rx_port": "vhost3",
+ "tx_port": "ring7"
+ },
+ {
+ "core": 13,
+ "type": "merge",
+ "rx_port": ["ring6", "ring7"],
+ "tx_port": "nic1"
+ }
+ ]
+ }
+ ],
+ "classifier_table": {
+ "name":"classifier_mac_table",
+ "table": [
+ {
+ "mac":"52:54:00:12:34:56",
+ "port":"ring0"
+ },
+ {
+ "mac":"52:54:00:12:34:57",
+ "port":"ring4"
+ },
+ {
+ "mac":"52:54:00:12:34:58",
+ "port":"ring1"
+ },
+ {
+ "mac":"52:54:00:12:34:59",
+ "port":"ring5"
+ }
+ ]
+ }
+}
+```
+
+Network diagram
+[TODO] Replace it to more readable SVG img.
+
+```
++---------+ +-----------------------------------------------------------------------------------------------+
+| host2 | | Host1 |
+| | | +------------------------------------------------------+ +-------------------+ |
+| | | | spp_vf | | | |
+| +-----+ | | +--------+ | +---+ +----+ +---+ +----+ +---+ +----------+ | | +----------+ | |
+| | nic <------> nic0 +-----> M +--> r8 +--> C +-----> r0 +--> F +--> +------> | | |
+| +-----+ | | +----+---+ | +-^-+ +----+ +-+-+ +----+ +---+ | | | | | | | |
+| | | ^ | | | | vhost0 | | | | nic | | |
+| | | | | | | +----+ +---+ | | | | | | | |
+| | | | | | +--------------+ r2 <--+ F <--+ <------+ | | |
+| | | | | | | | +----+ +---+ +----------+ | | +----------+ | |
+| | | | | | | | | | spp vm| |
+| | | | | | | | +----+ +---+ +----------+ | | +----------+ | |
+| | | | | | | +-------> r4 +--+ F +--> +------> | | |
+| | | | | | +--v--+ | +----+ +---+ | | | | | | | |
+| | | +----------------+ M | | | vhost1 | | | | nic | | |
+| | | | | +--^--+ | +----+ +---+ | | | | | | | |
+| | | | | | +------------+ r6 +--+ F <--+ <------+ | | |
+| | | | | | | | +----+ +---+ +----------+ | | +----------+ | |
+| | | | | | | | | | | |
+| | | | | | | | | +-------------------+ |
+| | | | | | | | | |
+| | | | | | | | | +-------------------+ |
+| | | | | | | | | | | |
+| +-----+ | | +--------+ | | | | | +----+ +---+ +----------+ | | +----------+ | |
+| | nic <------> nic1 +-------+ | | +-------> r1 +--+ F +--> +------> | | |
+| +-----+ | | +----+---+ | | | | +----+ +---+ | | | | | | | |
+| | | ^ | | | | | vhost2 | | | | nic | | |
+| | | | | | | | +----+ +---+ | | | | | | | |
+| | | | | +--------------+ r3 +--+ F <--+ <------+ | | |
+| | | | | | | +----+ +---+ +----------+ | | +----------+ | |
+| | | | | | | | | spp vm| |
+| | | | | | | +----+ +---+ +----------+ | | +----------+ | |
+| | | | | | +-------> r5 +--+ F +--> +------> | | |
+| | | | | +----v+ +----+ +---+ | | | | | | | |
+| | | +----------------+ M | | vhost3 | | | | nic | | |
+| | | | +--^--+ +----+ +---+ | | | | | | | |
+| | | | +--------------+ r7 +--+ F <--+ <------+ | | |
+| | | | +----+ +---+ +----------+ | | +----------+ | |
+| | | | | | | |
+| | | +------------------------------------------------------+ +-------------------+ |
+| | | |
++---------+ +-----------------------------------------------------------------------------------------------+
+```
--
1.9.1
next prev parent reply other threads:[~2018-01-16 5:16 UTC|newest]
Thread overview: 97+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-25 4:41 [spp] Proposal - spp_vf(SR-IOV like feature) addition to SPP Nakamura Hioryuki
2017-12-26 1:54 ` Yasufumi Ogawa
2017-12-28 4:55 ` [spp] [PATCH 01/57] spp_vf: add vf functions x-fn-spp
2017-12-28 8:49 ` Yasufumi Ogawa
2017-12-28 4:55 ` [spp] [PATCH 02/57] spp_vf: support multi process x-fn-spp
2018-02-07 16:50 ` Ferruh Yigit
2018-02-08 1:21 ` Yasufumi Ogawa
2018-02-08 6:44 ` [spp] [spp 02168] " Nakamura Hioryuki
2017-12-28 4:55 ` [spp] [PATCH 03/57] spp_vf: comment out check of using cores x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 04/57] spp_vf: modify classifier for upd command x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 05/57] spp_vf: add procedure that mac address is null x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 06/57] spp_vf: change config format for upd command x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 07/57] spp_vf: fix compiler warning in classifier_mac.c x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 08/57] spp_vf: modify data struct for upd command x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 09/57] spp_vf: add functions of command acceptance x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 10/57] spp_vf: add command acceptance calling x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 11/57] spp_vf: fix compiler warning in command_proc.c x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 12/57] " x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 13/57] spp_vf: refactor command acceptance/decode x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 14/57] spp_vf: fix return value overwrite problem x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 15/57] spp_vf: initialize message buffer x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 16/57] spp_vf: add const keyword to parameter x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 17/57] spp_vf: fix wrong comparison operator x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 18/57] spp_vf: fix wrong variable to be assigned x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 19/57] spp_vf: refactor parsing server ip address x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 20/57] spp_vf: fix error in command decode x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 21/57] spp_vf: fix comparison operator in spp_vf.c x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 22/57] spp_vf: check upper limit to the number of process x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 23/57] spp_vf: display usage message x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 24/57] spp_vf: split command processing source file x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 25/57] spp_vf: add new log and line break x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 26/57] spp_vf: support get-process-id command x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 27/57] spp_vf: update socket creation procedure x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 28/57] spp_vf: change log level and add line break x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 29/57] spp_vf: replace unsupported jansson api x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 30/57] spp_vf: change order of command result in json object x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 31/57] spp_vf: use prediction keywords x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 32/57] spp_vf: fix wrong comparison x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 33/57] spp_vf: update sending error status x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 34/57] spp_vf: modify conditional statement x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 35/57] spp_vf: add proc on receiving l2 multicast x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 36/57] spp_vf: extend limit on number of usable cores x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 37/57] spp_vf: add restart procedure for vhost client x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 38/57] spp_vf: fix classifier mbuf handling x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 39/57] spp_vf: add status command x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 40/57] spp_vf: add output source information in error log x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 41/57] spp_vf: change function names x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 42/57] spp_vf: change how to request commands x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 43/57] spp_vf: update command decode procedure x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 44/57] spp_vf: remove debug log output procedures x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 45/57] spp_vf: improve command_decoder program code x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 46/57] spp_vf: fix a bug in status command x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 47/57] spp_vf: add spp_vf.py instead of spp.py x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 48/57] spp_vf: refactor for commnets in spp_vf.c x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 49/57] spp_vf: refactor comments in classifier_mac.c x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 50/57] spp_vf: refactor comments in spp_forward.c x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 51/57] spp_vf: refactor for commnets in spp_config.c x-fn-spp
2017-12-28 4:55 ` [spp] [PATCH 52/57] spp_vf: refactor no self-explanatory comments x-fn-spp
2017-12-28 4:56 ` [spp] [PATCH 53/57] spp_vf: correct typo of function name x-fn-spp
2017-12-28 4:56 ` [spp] [PATCH 54/57] spp_vf: support new command x-fn-spp
2017-12-28 4:56 ` [spp] [PATCH 55/57] spp_vf: add display of status command x-fn-spp
2017-12-28 4:56 ` [spp] [PATCH 56/57] spp_vf: fix " x-fn-spp
2017-12-28 4:56 ` [spp] [PATCH 57/57] spp_vf: fix l2 multicast packet forwarding x-fn-spp
2018-01-15 11:04 ` [spp] Proposal - spp_vf(SR-IOV like feature) addition to SPP Ferruh Yigit
2018-01-16 5:16 ` [spp] [PATCH 01/30] doc: add setup guide x-fn-spp
2018-01-19 0:52 ` Yasufumi Ogawa
2018-01-22 14:37 ` Ferruh Yigit
2018-01-23 0:25 ` Yasufumi Ogawa
2018-01-16 5:16 ` [spp] [PATCH 02/30] doc: add how_to_use.md x-fn-spp
2018-01-16 5:16 ` x-fn-spp [this message]
2018-01-16 5:16 ` [spp] [PATCH 04/30] doc: add spp_vf.md x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 05/30] doc: revise spp_vf.md x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 06/30] doc: add config section x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 07/30] doc: update jp setup manual x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 08/30] doc: modify figure in spp_vf_overview x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 09/30] doc: fix " x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 10/30] doc: fix figure in overview x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 11/30] doc: add sample usage x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 12/30] doc: revice path descs x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 13/30] doc: add network configuration diagram x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 14/30] doc: update user account x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 15/30] doc: update descriptions for todo x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 16/30] doc: add description for explanation section x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 17/30] doc: add spp_sample_usage_svg in docs/spp_vf/ x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 18/30] doc: add explanation for terminating spp app x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 19/30] doc: add explanations on options of spp x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 20/30] doc: update description for the latest spp version x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 21/30] doc: update description on dpdk version x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 22/30] doc: fix vm setup procedure for network config x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 23/30] doc: update jansson installation procedure x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 24/30] doc: fix required network configuration x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 25/30] doc: add how to use vhost-user support x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 26/30] doc: add references to hugepages and isolcpus x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 27/30] doc: remove description on classifier_table x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 28/30] doc: fix typos and erros in texts x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 29/30] doc: update sample config section x-fn-spp
2018-01-16 5:16 ` [spp] [PATCH 30/30] doc: align figure title position x-fn-spp
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201801160516.w0G5GfsP009098@imss03.silk.ntt-tx.co.jp \
--to=x-fn-spp@sl.ntt-tx.co.jp \
--cc=spp@dpdk.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).