From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6EC23C433F5 for ; Tue, 4 Oct 2022 07:48:39 +0000 (UTC) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 3FEDE40DDC; Tue, 4 Oct 2022 09:48:38 +0200 (CEST) Received: from shelob.oktetlabs.ru (shelob.oktetlabs.ru [91.220.146.113]) by mails.dpdk.org (Postfix) with ESMTP id E904C40A87 for ; Tue, 4 Oct 2022 09:48:36 +0200 (CEST) Received: from [192.168.38.17] (aros.oktetlabs.ru [192.168.38.17]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by shelob.oktetlabs.ru (Postfix) with ESMTPSA id 1EB415D; Tue, 4 Oct 2022 10:48:36 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 shelob.oktetlabs.ru 1EB415D DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=oktetlabs.ru; s=default; t=1664869716; bh=VLQ1oIQrPLwbTACu9ni5W0JHBRnTeMBH53jbnmoc824=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=LQJuMw85ikekenPT3Eb1Fn/u54Rf/SwgzpuLJSRVWGV6V2CUbferor1dR5mvs2GxL fYKx544Cay4rhHgodtPqXVMdwJMb9+MvpTMeA3lQo4PKKzraqG1vbt4XQtX+oVjnPN R2/LSV8gP+mDZchXKC9ibTv5aDTKY9xyqBiLONeI= Message-ID: <54848f28-6ddf-05d2-d6ba-85cd69c78cca@oktetlabs.ru> Date: Tue, 4 Oct 2022 10:48:35 +0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.3.0 Subject: Re: [PATCH v5] ethdev: add send to kernel action Content-Language: en-US To: Michael Savisko , dev@dpdk.org Cc: orika@nvidia.com, viacheslavo@nvidia.com, asafp@nvidia.com, Aman Singh , Yuying Zhang , Thomas Monjalon , Ferruh Yigit References: <20220929145445.181369-1-michaelsav@nvidia.com> <20221003163449.279791-1-michaelsav@nvidia.com> From: Andrew Rybchenko Organization: OKTET Labs In-Reply-To: <20221003163449.279791-1-michaelsav@nvidia.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit 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 On 10/3/22 19:34, Michael Savisko wrote: > In some cases application may receive a packet that should have been > received by the kernel. In this case application uses KNI or other means > to transfer the packet to the kernel. > > With bifurcated driver we can have a rule to route packets matching > a pattern (example: IPv4 packets) to the DPDK application and the rest > of the traffic will be received by the kernel. > But if we want to receive most of the traffic in DPDK except specific > pattern (example: ICMP packets) that should be processed by the kernel, > then it's easier to re-route these packets with a single rule. > > This commit introduces new rte_flow action which allows application to > re-route packets directly to the kernel without software involvement. > > Add new testpmd rte_flow action 'send_to_kernel'. The application > may use this action to route the packet to the kernel while still > in the HW. > > Example with testpmd command: > > flow create 0 ingress priority 0 group 1 pattern eth type spec 0x0800 > type mask 0xffff / end actions send_to_kernel / end > > Signed-off-by: Michael Savisko > Acked-by: Ori Kam Acked-by: Andrew Rybchenko Applied to dpdk-next-net/main, thanks.