From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id B6F9FA0032; Wed, 16 Mar 2022 14:53:43 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id A3F4F410EC; Wed, 16 Mar 2022 14:53:43 +0100 (CET) Received: from inbox.dpdk.org (inbox.dpdk.org [95.142.172.178]) by mails.dpdk.org (Postfix) with ESMTP id BC21540395 for ; Wed, 16 Mar 2022 14:53:42 +0100 (CET) Received: by inbox.dpdk.org (Postfix, from userid 33) id AE8ACA0093; Wed, 16 Mar 2022 14:53:42 +0100 (CET) From: bugzilla@dpdk.org To: dev@dpdk.org Subject: [Bug 961] PCAP PMD receives packets larger then MTU Date: Wed, 16 Mar 2022 13:53:42 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: DPDK X-Bugzilla-Component: ethdev X-Bugzilla-Version: 21.11 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: ido@cgstowernetworks.com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: Normal X-Bugzilla-Assigned-To: dev@dpdk.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter target_milestone Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://bugs.dpdk.org/ Auto-Submitted: auto-generated X-Auto-Response-Suppress: All MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org https://bugs.dpdk.org/show_bug.cgi?id=3D961 Bug ID: 961 Summary: PCAP PMD receives packets larger then MTU Product: DPDK Version: 21.11 Hardware: All OS: All Status: UNCONFIRMED Severity: normal Priority: Normal Component: ethdev Assignee: dev@dpdk.org Reporter: ido@cgstowernetworks.com Target Milestone: --- Here is example of MTU (max-pkt-len) set to ~300B but driver receives packe= t of ~9000B (the jumbo pcap is attached) root@u18c_9td3:/home/cgs/workspace/master/jumbo# ./dpdk-testpmd --no-huge -m1024 -l 0-3 -n 4 --vdev 'net_pcap0,rx_pcap=3Djumbo_9000.pcap,tx_pcap=3Dfile_tx.pcap' -- --no-flush-= rx --total-num-mbufs=3D2048 --max-pkt-len=3D300 -i EAL: Detected CPU lcores: 6 EAL: Detected NUMA nodes: 1 EAL: Detected static linkage of DPDK EAL: Multi-process socket /var/run/dpdk/rte/mp_socket EAL: Selected IOVA mode 'VA' EAL: VFIO support initialized TELEMETRY: No legacy callbacks, legacy socket not created Interactive-mode selected Warning: NUMA should be configured manually by using --port-numa-config and --ring-numa-config parameters along with --numa. testpmd: create a new mbuf pool : n=3D2048, size=3D2176, socket= =3D0 testpmd: preferred mempool ops selected: ring_mp_mc Warning! port-topology=3Dpaired and odd forward ports number, the last port= will pair with itself. Configuring Port 0 (socket 0) Port 0: 02:70:63:61:70:00 Checking link statuses... Done testpmd> show port info 0 ********************* Infos for port 0 ********************* MAC address: 02:70:63:61:70:00 Device name: net_pcap0 Driver name: net_pcap Firmware-version: not available Devargs: rx_pcap=3Djumbo_9000.pcap,tx_pcap=3Dfile_tx.pcap Connect to socket: 0 memory allocation on the socket: 0 Link status: up Link speed: 10 Gbps Link duplex: full-duplex Autoneg status: Off MTU: 282 Promiscuous mode: enabled Allmulticast mode: enabled Maximum number of MAC addresses: 1 Maximum number of MAC addresses of hash filtering: 0 VLAN offload:=20 strip off, filter off, extend off, qinq strip off No RSS offload flow type is supported. Minimum size of RX buffer: 0 Maximum configurable length of RX packet: 4294967295 Maximum configurable size of LRO aggregated packet: 0 Current number of RX queues: 1 Max possible RX queues: 1 Max possible number of RXDs per queue: 65535 Min possible number of RXDs per queue: 0 RXDs number alignment: 1 Current number of TX queues: 1 Max possible TX queues: 1 Max possible number of TXDs per queue: 65535 Min possible number of TXDs per queue: 0 TXDs number alignment: 1 Max segment number per packet: 65535 Max segment number per MTU/TSO: 65535 Device capabilities: 0x0( ) testpmd> set verbose 3 Change verbose level from 0 to 3 testpmd> start io packet forwarding - ports=3D1 - cores=3D1 - streams=3D1 - NUMA support e= nabled, MP allocation mode: native Logical Core 1 (socket 0) forwards packets on 1 streams: RX P=3D0/Q=3D0 (socket 0) -> TX P=3D0/Q=3D0 (socket 0) peer=3D02:00:00:00= :00:00 io packet forwarding packets/burst=3D32 nb forwarding cores=3D1 - nb forwarding ports=3D1 port 0: RX queue number: 1 Tx queue number: 1 Rx offloads=3D0x0 Tx offloads=3D0x0 RX queue: 0 RX desc=3D0 - RX free threshold=3D0 RX threshold registers: pthresh=3D0 hthresh=3D0 wthresh=3D0 RX Offloads=3D0x0 TX queue: 0 TX desc=3D0 - TX free threshold=3D0 TX threshold registers: pthresh=3D0 hthresh=3D0 wthresh=3D0 TX offloads=3D0x0 - TX RS bit threshold=3D0 testpmd> port 0/queue 0: received 1 packets src=3D04:F4:BC:3E:E4:25 - dst=3D00:00:00:00:00:00 - type=3D0x0800 - lengt= h=3D8996 - nb_segs=3D5 - timestamp 1266577613728443 - sw ptype: L2_ETHER L3_IPV4 - l2_len=3D14 - l3_len=3D20 - Receive queue=3D0x0 ol_flags: RTE_MBUF_F_RX_L4_CKSUM_UNKNOWN RTE_MBUF_F_RX_IP_CKSUM_UNKNOWN RTE_MBUF_F_RX_OUTER_L4_CKSUM_UNKNOWN=20 port 0/queue 0: sent 1 packets src=3D04:F4:BC:3E:E4:25 - dst=3D00:00:00:00:00:00 - type=3D0x0800 - lengt= h=3D8996 - nb_segs=3D5 - timestamp 1266577613728443 - sw ptype: L2_ETHER L3_IPV4 - l2_len=3D14 - l3_len=3D20 - Send queue=3D0x0 ol_flags: RTE_MBUF_F_TX_L4_NO_CKSUM=20 testpmd> stop Telling cores to stop... Waiting for lcores to finish... ---------------------- Forward statistics for port 0 -------------------= --- RX-packets: 1 RX-dropped: 0 RX-total: 1 TX-packets: 1 TX-dropped: 0 TX-total: 1 -------------------------------------------------------------------------= --- +++++++++++++++ Accumulated forward statistics for all ports+++++++++++++= ++ RX-packets: 1 RX-dropped: 0 RX-total: 1 TX-packets: 1 TX-dropped: 0 TX-total: 1 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++= +++ Done. testpmd> show port stats 0 ######################## NIC statistics for port 0 #####################= ### RX-packets: 1 RX-missed: 0 RX-bytes: 8996 RX-errors: 0 RX-nombuf: 0=20=20=20=20=20=20=20=20=20 TX-packets: 1 TX-errors: 0 TX-bytes: 8996 Throughput (since last show) Rx-pps: 0 Rx-bps: 0 Tx-pps: 0 Tx-bps: 0 #########################################################################= ### testpmd> quit Stopping port 0... Stopping ports... Done Shutting down port 0... Closing ports... Port 0 is closed Done Bye... There's further issues for apps (non test-pmd) that use pcap driver as they= may unexpectedly get segmented mbufs w/o setting RTE_ETH_RX_OFFLOAD_SCATTER --=20 You are receiving this mail because: You are the assignee for the bug.=