X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=doc%2Fguides%2Fnics%2Fmemif.rst;h=8e80105a46095c34c8460373b68678a440e8824b;hb=53a73b7b9db0e62394d94330f7f83c38748490b5;hp=4d7f0086a90efd598162d3e02b3abd093ebba5ae;hpb=43b815d881885a63d8d4691f07f7a93e1a01f6d4;p=dpdk.git diff --git a/doc/guides/nics/memif.rst b/doc/guides/nics/memif.rst index 4d7f0086a9..8e80105a46 100644 --- a/doc/guides/nics/memif.rst +++ b/doc/guides/nics/memif.rst @@ -43,6 +43,7 @@ client. "bsize=1024", "Size of single packet buffer", "2048", "uint16_t" "rsize=11", "Log2 of ring size. If rsize is 10, actual ring size is 1024", "10", "1-14" "socket=/tmp/memif.sock", "Socket filename", "/tmp/memif.sock", "string len 108" + "socket-abstract=no", "Set usage of abstract socket address", "yes", "yes|no" "mac=01:23:45:ab:cd:ef", "Mac address", "01:ab:23:cd:45:ef", "" "secret=abc123", "Secret is an optional security option, which if specified, must be matched by peer", "", "string len 24" "zero-copy=yes", "Enable/disable zero-copy slave mode. Only relevant to slave, requires '--single-file-segments' eal argument", "no", "yes|no" @@ -272,3 +273,20 @@ Send ping from VPP:: 64 bytes from 192.168.1.2: icmp_seq=3 ttl=254 time=23.3927 ms 64 bytes from 192.168.1.2: icmp_seq=4 ttl=254 time=24.2975 ms 64 bytes from 192.168.1.2: icmp_seq=5 ttl=254 time=17.7049 ms + +Example: testpmd memif loopback +------------------------------- +In this example we will create 2 memif ports connected into loopback. +The situation is analogous to cross connecting 2 ports of the NIC by cable. + +To set the loopback, just use the same socket and id with different roles:: + + #./testpmd --vdev=net_memif0,role=master,id=0 --vdev=net_memif1,role=slave,id=0 -- -i + +Then start the communication:: + + testpmd> start tx_first + +Finally we can check port stats to see the traffic:: + + testpmd> show port stats all