Skip to content

Commit

Permalink
Try testing different MAC addrs with VMDq
Browse files Browse the repository at this point in the history
  • Loading branch information
takikawa committed Aug 16, 2017
1 parent 19edfb1 commit 70bd72d
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 3 deletions.
Binary file added src/apps/intel_mp/source2.pcap
Binary file not shown.
2 changes: 1 addition & 1 deletion src/apps/intel_mp/test_10g_1q_blast_vmdq.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
SNABB_SEND_BLAST=true ./testsend.snabb $SNABB_PCI_INTEL1 0 source.pcap &
BLAST=$!

SNABB_RECV_SPINUP=2 SNABB_RECV_DURATION=5 ./testvmdqrecv.snabb $SNABB_PCI_INTEL0 0 0 > results.0
SNABB_RECV_SPINUP=2 SNABB_RECV_DURATION=5 ./testvmdqrecv.snabb $SNABB_PCI_INTEL0 "90:72:82:78:c9:7a" 0 0 > results.0

kill -9 $BLAST
test `cat results.0 | grep "^RXDGPC" | awk '{print $2}'` -gt 10000
Expand Down
10 changes: 10 additions & 0 deletions src/apps/intel_mp/test_10g_2q_blast_vmdq.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/usr/bin/env bash
SNABB_SEND_BLAST=true ./testsend.snabb $SNABB_PCI_INTEL1 0 source2.pcap &
BLAST=$!

SNABB_RECV_SPINUP=2 SNABB_RECV_DURATION=5 ./testvmdqrecv.snabb $SNABB_PCI_INTEL0 "90:72:82:78:c9:7a" 0 0 > results.0 &
SNABB_RECV_SPINUP=2 SNABB_RECV_DURATION=5 ./testvmdqrecv.snabb $SNABB_PCI_INTEL0 "12:34:56:78:9a:bc" 1 4 > results.1

kill -9 $BLAST
test `cat results.0 | grep "^RXDGPC" | awk '{print $2}'` -gt 10000
exit $?
5 changes: 3 additions & 2 deletions src/apps/intel_mp/testvmdqrecv.snabb
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
#!../../snabb snsh
local args = main.parameters
assert(#args == 3, "testvmdqrecv.snabb pciaddr poolno qno")
assert(#args == 4, "testvmdqrecv.snabb pciaddr macaddr poolno qno")
local pciaddr = table.remove(args, 1)
local macaddr = table.remove(args, 1)
local poolno = tonumber(table.remove(args,1))
local qno = tonumber(table.remove(args,1))

Expand All @@ -11,7 +12,7 @@ local ffi = require("ffi")
local C = ffi.C

local c = config.new()
config.app(c, "nic", intel.Intel, { pciaddr=pciaddr, macaddr="90:72:82:78:c9:7a", vmdq=true, poolnum=poolno, rxq = qno, ndescriptors = 2048, wait_for_link=true })
config.app(c, "nic", intel.Intel, { pciaddr=pciaddr, macaddr=macaddr, vmdq=true, poolnum=poolno, rxq = qno, ndescriptors = 2048, wait_for_link=true })
config.app(c, "sink", basic.Sink)
if os.getenv("SNABB_RECV_EXPENSIVE") then
local filter = require("apps.packet_filter.pcap_filter")
Expand Down

0 comments on commit 70bd72d

Please sign in to comment.