DPDK usage discussions
 help / color / mirror / Atom feed
From: "Yan, Xiaoping (NSB - CN/Hangzhou)" <xiaoping.yan@nokia-sbell.com>
To: "users@dpdk.org" <users@dpdk.org>,
	"jingjing.wu@intel.com" <jingjing.wu@intel.com>,
	"beilei.xing@intel.com" <beilei.xing@intel.com>
Subject: rx packet vlan_tci is not set in iavf driver
Date: Tue, 27 Sep 2022 14:29:19 +0000	[thread overview]
Message-ID: <96e4df2f97e4480596092d275c2bdde1@nokia-sbell.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 2643 bytes --]

Hi,

I have a dpdk application sending broadcast packet in vlan 0x248. and I started dpdk-testpmd on rx only mode.

The dpdk-testpmd received the packet with vlan header (as expected) as below from gdb output:
(gdb) x/100xb (pkts_burst[4]->buf_addr+pkts_burst[4]->data_off)
0x17787c8c0:    0xff    0xff    0xff    0xff    0xff    0xff    0xfe    0x1a
0x17787c8c8:    0xcc    0x2e    0x6e    0x78    0x81    0x00    0x02    0x48
0x17787c8d0:    0x89    0x51    0x40    0x00    0x00    0x00    0x00    0x00
...

Then I enable vlan strip via below command
testpmd> vlan set strip on 0
Now the vlan is stripped (as expected) as below:
(gdb) x/100xb (pkts_burst[0]->buf_addr+pkts_burst[0]->data_off)
0x1775b8a80:    0xff    0xff    0xff    0xff    0xff    0xff    0xfe    0x1a
0x1775b8a88:    0xcc    0x2e    0x6e    0x78    0x89    0x51    0x40    0x00
0x1775b8a90:    0x00    0x00    0x00    0x00    0x00    0x00    0x03    0x00
...
But (what is not expected) the mbuf vlan_tci is not filled, as below:
gdb) p *pkts_burst[4]
$8 = {cacheline0 = 0x17787c740, buf_addr = 0x17787c7c0, buf_iova = 6300354496,
  rearm_data = 0x17787c750, data_off = 256, refcnt = 1, nb_segs = 1, port = 0,
  ol_flags = 384, rx_descriptor_fields1 = 0x17787c760, {packet_type = 1, {
      l2_type = 1 '\001', l3_type = 0 '\000', l4_type = 0 '\000',
      tun_type = 0 '\000', {inner_esp_next_proto = 0 '\000', {
          inner_l2_type = 0 '\000', inner_l3_type = 0 '\000'}},
      inner_l4_type = 0 '\000'}}, pkt_len = 60, data_len = 60, vlan_tci = 0, {
    hash = {rss = 0, fdir = {{{hash = 0, id = 0}, lo = 0}, hi = 0}, sched = {
        queue_id = 0, traffic_class = 0 '\000', color = 0 '\000', reserved = 0},
      txadapter = {reserved1 = 0, reserved2 = 0, txq = 0}, usr = 0}},
  vlan_tci_outer = 0, buf_len = 2304, pool = 0x23b1e98c0, cacheline1 = 0x17787c780,
  next = 0x0, {tx_offload = 0, {l2_len = 0, l3_len = 0, l4_len = 0, tso_segsz = 0,
      outer_l3_len = 0, outer_l2_len = 0}}, shinfo = 0x0, priv_size = 0,
  timesync = 0, dynfield1 = {0, 0, 0, 0, 0, 0, 0, 0, 0}}

Is there something wrong in the iavf pmd driver?

dpdk version: 21.11-0 (iavf pmd driver, and rx burst function is iavf_recv_pkts_vec_avx2)
hw: intel E810 SRIOV VF
PF driver and firmware in use:
[cranuser2@hzdc-ecp-10-110-8-222 ~]$ ethtool -i ens43f2
driver: ice
version: 4.18.0-372.26.1.el8_6.x86_64
firmware-version: 3.10 0x8000ad3d 1.3106.0
expansion-rom-version:
bus-info: 0000:8a:00.2
supports-statistics: yes
supports-test: yes
supports-eeprom-access: yes
supports-register-dump: yes
supports-priv-flags: yes


Thank you.




[-- Attachment #2: Type: text/html, Size: 8880 bytes --]

             reply	other threads:[~2022-09-27 14:29 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-27 14:29 Yan, Xiaoping (NSB - CN/Hangzhou) [this message]
2022-09-29 14:07 ` Yan, Xiaoping (NSB - CN/Hangzhou)

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=96e4df2f97e4480596092d275c2bdde1@nokia-sbell.com \
    --to=xiaoping.yan@nokia-sbell.com \
    --cc=beilei.xing@intel.com \
    --cc=jingjing.wu@intel.com \
    --cc=users@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).