Hi, Brian,

Thanks indeed for the quick response.
Network adaptor is X552 which integrated in XEON, 
https://www.intel.com/content/dam/www/public/us/en/documents/datasheets/ethernet-x550-datasheet.pdf

The MTU in PF is “mtu 9194”
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 9194 qdisc mq state UP mode 
DEFAULT group default qlen 1000
In current test, I sent the packet size is 1kB, maybe small packets.

OK, thanks, I’ll also try set dpdk mtu, to avoid big packets drop in HW 
filtering. Is it like this? rte_eth_dev_set_mtu(port_id, 9194 - 8).

Best Regards,
Dave(Jianyue)

From: Johnson, Brian <[email protected]>
Sent: 2020年7月14日 10:53
To: Wu, Jianyue (NSB - CN/Hangzhou) <[email protected]>; Li, Xiaoyun 
<[email protected]>; [email protected]
Cc: Harouat, Karim (Nokia - FR/Lannion) <[email protected]>; Meunier, 
Julien (Nokia - FR/Paris-Saclay) <[email protected]>; Cheng, Fei 2. (NSB 
- CN/Hangzhou) <[email protected]>; Lu, Malak (NSB - CN/Hangzhou) 
<[email protected]>; Li, Jiu (NSB - CN/Hangzhou) 
<[email protected]>; Pan, Jianyong (NSB - CN/Hangzhou) 
<[email protected]>; Hong, Christian (NSB - CN/Hangzhou) 
<[email protected]>; Fei, Xiang (NSB - CN/Hangzhou) 
<[email protected]>; Ning, Gang (NSB - CN/Hangzhou) 
<[email protected]>; Ren, Longlong (NSB - CN/Hangzhou) 
<[email protected]>; Ye, Hua (NSB - CN/Hangzhou) 
<[email protected]>
Subject: Re: [dpdk-users] [dpdk-18.05] Issue while configuring VLAN ID and 
priority in VF

What network adapter are you using?

In some cases if there is a port vlan set, since the VF driver does not know to 
add an additional 4B to the max Rx packet length, the packets get dropped by 
the hardware filters if the packet is at full MTU size.

Try setting the MTU in DPDK and this should add the 4B or 8B needed.

________________________________
From: users <[email protected]<mailto:[email protected]>> on behalf 
of Wu, Jianyue (NSB - CN/Hangzhou) 
<[email protected]<mailto:[email protected]>>
Sent: Monday, July 13, 2020 7:43:38 PM
To: Li, Xiaoyun <[email protected]<mailto:[email protected]>>; 
[email protected]<mailto:[email protected]> <[email protected]<mailto:[email protected]>>
Cc: Harouat, Karim (Nokia - FR/Lannion) 
<[email protected]<mailto:[email protected]>>; Meunier, Julien 
(Nokia - FR/Paris-Saclay) 
<[email protected]<mailto:[email protected]>>; Cheng, Fei 2. (NSB 
- CN/Hangzhou) 
<[email protected]<mailto:[email protected]>>; Lu, Malak 
(NSB - CN/Hangzhou) 
<[email protected]<mailto:[email protected]>>; Li, Jiu (NSB - 
CN/Hangzhou) <[email protected]<mailto:[email protected]>>; Pan, 
Jianyong (NSB - CN/Hangzhou) 
<[email protected]<mailto:[email protected]>>; Hong, 
Christian (NSB - CN/Hangzhou) 
<[email protected]<mailto:[email protected]>>; Fei, 
Xiang (NSB - CN/Hangzhou) 
<[email protected]<mailto:[email protected]>>; Ning, Gang (NSB 
- CN/Hangzhou) <[email protected]<mailto:[email protected]>>; 
Ren, Longlong (NSB - CN/Hangzhou) 
<[email protected]<mailto:[email protected]>>; Ye, Hua 
(NSB - CN/Hangzhou) <[email protected]<mailto:[email protected]>>
Subject: [dpdk-users] [dpdk-18.05] Issue while configuring VLAN ID and priority 
in VF

Hi, xiaoyun,

Could you help give a hand about this issue? Thanks indeed:)

Background:
Simplified traffic flow is like this: Sender XEON X552 eth1 vf 0 -> Receiver 
XEON X552 eth1 vf 0.
Our requirement is to configure DPDK to support one VLAN ID, and with multiple 
priorities 0~7.

Current configuration is:
PVID:
    rte_eth_dev_set_vlan_pvid(port_id, 201, 1);
VLAN offload:
  vlan_offload = rte_eth_dev_get_vlan_offload(port_id);
  vlan_offload &= ~ETH_VLAN_STRIP_OFFLOAD;
  vlan_offload &= ~ETH_VLAN_FILTER_OFFLOAD;
  vlan_offload &= ~ETH_VLAN_EXTEND_OFFLOAD;
  if (0 != rte_eth_dev_set_vlan_offload(port_id, vlan_offload))
Spoof off, trust on:
     vf 0 MAC 02:40:43:80:01:39, spoof checking off, link-state auto, trust on, 
query_rss off

Test scenarios:
====================================================
First scenario: set vlan in vf 0 -- priority always 0
====================================================
ip link show eth1
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 9194 qdisc mq state UP mode 
DEFAULT group default qlen 1000
    link/ether 02:40:43:80:01:38 brd ff:ff:ff:ff:ff:ff
vf 0 MAC 02:40:43:80:01:39, vlan 201, spoof checking off, link-state auto, 
trust on, query_rss off

If we configure vlan in vf 0, then we can only send out packets with priority 0.
Even we already enabled mbuf->ol_flags |= PKT_TX_VLAN_PKT; and set correct 
mbuf->vlan_tci.

======================================================
Second scenario: not set vlan in vf 0 -- can't recv
======================================================
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 9194 qdisc mq state UP mode 
DEFAULT group default qlen 1000
    link/ether 02:40:43:80:01:38 brd ff:ff:ff:ff:ff:ff
vf 0 MAC 02:40:43:80:01:39, spoof checking off, link-state auto, trust on, 
query_rss off

If we don't set vlan in vf 0, then we can send out in sender XEON X552 eth1 vf 
0 with correct VLAN ID and priority,
From tcpdump in mirrored traffic of receiver XEON, we can see the packet has 
correct VLAN ID and priority,
but the problem is packet silently dropped. From DPDK counters, we can't see 
the packet received in
receiver XEON X552 eth1 vf0. When we enable promiscuous mode, we can see the 
packets arrive in
receiver XEON, and VLAN ID, priority is correct. but can't arrive at DPDK.

From my simple assumption, maybe we need second scenario, to support multiple 
priorities.
But how to configure to let the packet pass vf 0?
Did I miss something in my configuration?

Thanks indeed in advance!

Best Regards,
Dave(Jianyue)

Reply via email to