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 7666FA0032; Wed, 14 Sep 2022 09:43:44 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 64ED140151; Wed, 14 Sep 2022 09:43:44 +0200 (CEST) Received: from office2.cesnet.cz (office2.cesnet.cz [195.113.144.244]) by mails.dpdk.org (Postfix) with ESMTP id 77B9A40141 for ; Wed, 14 Sep 2022 09:43:43 +0200 (CEST) Received: from [IPV6:2001:67c:1220:80e:f5:8725:1d51:d744] (unknown [IPv6:2001:67c:1220:80e:f5:8725:1d51:d744]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by office2.cesnet.cz (Postfix) with ESMTPSA id 374DE400070; Wed, 14 Sep 2022 09:43:43 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cesnet.cz; s=office2-2020; t=1663141423; bh=yNUxAd1jp/jyqSFVtNDihkDD6e9OIX9dg8yfYd1w/0w=; h=Date:Subject:To:Cc:References:From:In-Reply-To; b=TsxccWAzSaK+7y1H6Xk0/3aLr50UUyIp/q6FWinrH5Fa0hEpvnBz4M0j5X1+0xgpc Q6e9Uv5uSIv9DPQkPip1Xn1fpW0rbSibxL2/xPtGw+KKMFuBIJvB9EyPq51YVhu4uk EmpKTvjVsOvRkhYHd2+O3hc6qAfc0ixdChk3EJ+3/AKHMls/BzUb2+vlSnSEnUAFlq KvD6jCSuiaY3Ht9n8KsFrSnrwrqj3KSaXiX2DCmokPn6QMJu9PQECiJvmWblma6cRK ejWDtqIyxc7Ynv8OqiEG/hiHQmh4dTan6EQ+nvxx3NxpVgPIrPJCpbkCpo1GuNKXXs LgGg7zE89U8Ww== Message-ID: <1e6c9633-e73b-567a-2e28-d9db3dca8d96@cesnet.cz> Date: Wed, 14 Sep 2022 09:43:42 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.2.1 Subject: Re: Egress RTE flow rule rule with mark in matching pattern on mlx5 Content-Language: en-US To: Asaf Penso , Matan Azrad , Slava Ovsiienko Cc: "dev@dpdk.org" References: <26597fb0-d78d-af23-178d-05a87510cdec@cesnet.cz> From: David Vodak In-Reply-To: Content-Type: multipart/signed; protocol="application/pkcs7-signature"; micalg=sha-256; boundary="------------ms070806020906090305020301" 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 This is a cryptographically signed message in MIME format. --------------ms070806020906090305020301 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Hello Asaf, we want to mark packets both ways - in the software (by editing mbufs) or in the hardware (by ingress rules). Then we want to use that mark to match packets in egress where we want to change dst mac address or vlan vid. Is there any way to do it? Thank you, David On 13/09/2022 21:39, Asaf Penso wrote: > Hello David, > > Can we first understand what you would like to achieve? > Accordingly, we can suggest a way to do so. > > Regards, > Asaf Penso > >> -----Original Message----- >> From: David Vodak >> Sent: Tuesday, September 13, 2022 5:29 PM >> To: Matan Azrad ; Slava Ovsiienko >> >> Cc: dev@dpdk.org >> Subject: Egress RTE flow rule rule with mark in matching pattern on mlx5 >> >> Hello, >> >> I am trying to offload egress flow rule with mark in the matching >> pattern to nvidia NICs ConnectX-5 and ConnectX-6, but I keep getting the >> same results. I am using DPDK 21.11.1. >> >> If I try to offload this rule to mlx5 NIC, without any device arguments, >> it says that I need to enable extended metadata feature: >> >> >> # dpdk-testpmd -a 65:00.0 -- -i >> EAL: Detected CPU lcores: 40 >> EAL: Detected NUMA nodes: 1 >> EAL: Detected shared linkage of DPDK >> EAL: Multi-process socket /var/run/dpdk/rte/mp_socket >> EAL: Selected IOVA mode 'PA' >> EAL: No free 1048576 kB hugepages reported on node 0 >> EAL: No available 1048576 kB hugepages reported >> EAL: Probe PCI driver: mlx5_pci (15b3:1017) device: 0000:65:00.0 (socket 0) >> TELEMETRY: No legacy callbacks, legacy socket not created >> Interactive-mode selected >> testpmd: create a new mbuf pool : n=459456, size=2176, >> socket=0 >> testpmd: preferred mempool ops selected: ring_mp_mc >> >> Warning! port-topology=paired and odd forward ports number, the last >> port will pair with itself. >> >> Configuring Port 0 (socket 0) >> Port 0: 1C:34:DA:41:66:1C >> Checking link statuses... >> Done >> testpmd> flow create 0 egress group 0 pattern eth / mark id spec 4 id >> mask 4 / end actions set_mac_dst mac_addr FE:FE:CA:FE:FE:FE / end >> port_flow_complain(): Caught PMD error type 13 (specific pattern item): >> cause: 0x7ffc030aa198, extended metadata feature isn't enabled: >> Operation not supported >> >> >> If I try to run testpmd with dv_xmeta_en set to 1 or 2, I can only >> create that rule in group that does not equal 0. But I cannot offload a >> rule which contains JUMP action, so I cannot jump to group, where the >> rule with mark in the matching pattern can be offloaded. >> >> >> # dpdk-testpmd -a 65:00.0,dv_xmeta_en=1 -- -i >> EAL: Detected CPU lcores: 40 >> EAL: Detected NUMA nodes: 1 >> EAL: Detected shared linkage of DPDK >> EAL: Multi-process socket /var/run/dpdk/rte/mp_socket >> EAL: Selected IOVA mode 'PA' >> EAL: No free 1048576 kB hugepages reported on node 0 >> EAL: No available 1048576 kB hugepages reported >> EAL: Probe PCI driver: mlx5_pci (15b3:1017) device: 0000:65:00.0 (socket 0) >> TELEMETRY: No legacy callbacks, legacy socket not created >> Interactive-mode selected >> testpmd: create a new mbuf pool : n=459456, size=2176, >> socket=0 >> testpmd: preferred mempool ops selected: ring_mp_mc >> >> Warning! port-topology=paired and odd forward ports number, the last >> port will pair with itself. >> >> Configuring Port 0 (socket 0) >> Port 0: 1C:34:DA:41:66:1C >> Checking link statuses... >> Done >> testpmd> flow create 0 egress group 0 pattern eth / mark id spec 4 id >> mask 4 / end actions set_mac_dst mac_addr FE:FE:CA:FE:FE:FE / end >> port_flow_complain(): Caught PMD error type 1 (cause unspecified): >> cannot create modification action: Cannot allocate memory >> testpmd> flow create 0 egress group 1 pattern eth / mark id spec 4 id >> mask 4 / end actions set_mac_dst mac_addr FE:FE:CA:FE:FE:FE / end >> Flow rule #0 created >> testpmd> flow create 0 egress pattern eth / end actions jump group 1 / end >> port_flow_complain(): Caught PMD error type 1 (cause unspecified): >> cannot create modification action: Cannot allocate memory >> >> >> Is there any way how can I work this out or do I need to start using >> similar pattern items such as meta? >> >> Thank you, >> >> David --------------ms070806020906090305020301 Content-Type: application/pkcs7-signature; name="smime.p7s" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="smime.p7s" Content-Description: S/MIME Cryptographic Signature MIAGCSqGSIb3DQEHAqCAMIACAQExDzANBglghkgBZQMEAgEFADCABgkqhkiG9w0BBwEAAKCC DTwwggZOMIIENqADAgECAhEAk38ls9gogFgZNzs0cAAi5zANBgkqhkiG9w0BAQwFADBGMQsw CQYDVQQGEwJOTDEZMBcGA1UEChMQR0VBTlQgVmVyZW5pZ2luZzEcMBoGA1UEAxMTR0VBTlQg UGVyc29uYWwgQ0EgNDAeFw0yMjA3MTUwMDAwMDBaFw0yNTA3MTQyMzU5NTlaMIHHMQ8wDQYD VQQREwYxNjAgMDAxODA2BgNVBAoML0NFU05FVCwgesOham1vdsOpIHNkcnXFvmVuw60gcHLD oXZuaWNrw71jaCBvc29iMRYwFAYDVQQJEw1aaWtvdmEgMTkwMy80MR4wHAYDVQQIDBVQcmFo YSwgSGxhdm7DrSBtxJtzdG8xCzAJBgNVBAYTAkNaMRUwEwYDVQQDDAxEYXZpZCBWb2TDoWsx HjAcBgkqhkiG9w0BCQEWD3ZvZGFrQGNlc25ldC5jejCCASIwDQYJKoZIhvcNAQEBBQADggEP ADCCAQoCggEBAJDImivR4mj9pzwZk59TqoKsgvwWMxgBgKgUtY2SrnqVKY1x/eZ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