Re: [dpdk-users] RSS Hash not working for XL710/X710 NICs for some RX mbuf sizes
From: Xing, Beilei <hidden>
Date: 2016-07-20 01:59:44
Possibly related (same subject, not in this thread)
- 2016-07-26 · Re: [dpdk-users] RSS Hash not working for XL710/X710 NICs for some RX mbuf sizes · Ananyev, Konstantin <hidden>
Hi Ceara,
-----Original Message----- From: Take Ceara [mailto:dumitru.ceara@gmail.com] Sent: Tuesday, July 19, 2016 10:59 PM To: Xing, Beilei <redacted> Cc: Zhang, Helin <redacted>; Wu, Jingjing [off-list ref]; dev@dpdk.org Subject: Re: [dpdk-dev] [dpdk-users] RSS Hash not working for XL710/X710 NICs for some RX mbuf sizes Hi Beilei, I changed the way I run testmpd to: testpmd -c 0x331 -w 0000:82:00.0 -w 0000:83:00.0 -- --mbuf-size 1152 --rss-ip - -rxq=2 --txpkts 1024 -i As far as I understand this will allocate mbufs with the same size I was using in my test (--mbuf-size seems to include the mbuf headroom therefore 1152 = 1024 + 128 headroom). testpmd> start tx_first io packet forwarding - CRC stripping disabled - packets/burst=32 nb forwarding cores=1 - nb forwarding ports=2 RX queues=2 - RX desc=128 - RX free threshold=32 RX threshold registers: pthresh=8 hthresh=8 wthresh=0 TX queues=1 - TX desc=512 - TX free threshold=32 TX threshold registers: pthresh=32 hthresh=0 wthresh=0 TX RS bit threshold=32 - TXQ flags=0xf01 testpmd> show port stats all ######################## NIC statistics for port 0 ######################## RX-packets: 18817613 RX-missed: 5 RX-bytes: 19269115888 RX-errors: 0 RX-nombuf: 0 TX-packets: 18818064 TX-errors: 0 TX-bytes: 19269567464 ########################################################## ################## ######################## NIC statistics for port 1 ######################## RX-packets: 18818392 RX-missed: 5 RX-bytes: 19269903360 RX-errors: 0 RX-nombuf: 0 TX-packets: 18817979 TX-errors: 0 TX-bytes: 19269479424 ########################################################## ################## Ttraffic is sent/received. However, I couldn't find any way to verify that the incoming mbufs actually have the mbuf->hash.rss field set except for starting test-pmd with gdb and setting a breakpoint in the io fwd engine. After doing that I noticed that none of the incoming packets has the PKT_RX_RSS_HASH flag set in ol_flags... I guess for some reason test-pmd doesn't actually configure RSS in this case but I fail to see where.
Actually there's a way to check mbuf->hash.rss, you need set forward mode to "rxonly", and set verbose to 1. I run testpmd with the configuration you used, and found i40e RSS works well. With the following steps, you can see RSS hash value and receive queue, and PKT_RX_RSS_HASH is set too. I think you can use the same way to check what you want. ./testpmd -c fffff -n 4 -- -i --coremask=0xffffe --rxq=16 --txq=16 --mbuf-size 1152 --rss-ip --txpkts 1024 testpmd> set verbose 1 testpmd> set fwd rxonly testpmd> start testpmd> port 0/queue 1: received 1 packets src=00:00:01:00:0F:00 - dst=68:05:CA:32:03:4C - type=0x0800 - length=1020 - nb - Receive queue=0x1 PKT_RX_RSS_HASH port 0/queue 0: received 1 packets src=00:00:01:00:0F:00 - dst=68:05:CA:32:03:4C - type=0x0800 - length=1020 - nb_segs=1 - RSS hash=0x4e949f23 - RSS queue=0x0Unknown packet type - Receive queue=0x0 PKT_RX_RSS_HASH port 0/queue 8: received 1 packets src=00:00:01:00:0F:00 - dst=68:05:CA:32:03:4C - type=0x0800 - length=1020 - nb_segs=1 - RSS hash=0xa3c78b2b - RSS queue=0x8Unknown packet type - Receive queue=0x8 PKT_RX_RSS_HASH port 0/queue 5: received 1 packets src=00:00:01:00:0F:00 - dst=68:05:CA:32:03:4C - type=0x0800 - length=1020 - nb_segs=1 - RSS hash=0xe29b3d36 - RSS queue=0x5Unknown packet type - Receive queue=0x5 PKT_RX_RSS_HASH /Beilei
Thanks, Dumitru