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 49B8CA0524; Tue, 13 Apr 2021 09:51:33 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id C17A1160BF2; Tue, 13 Apr 2021 09:51:32 +0200 (CEST) Received: from mail-pj1-f41.google.com (mail-pj1-f41.google.com [209.85.216.41]) by mails.dpdk.org (Postfix) with ESMTP id E386F160BF1 for ; Tue, 13 Apr 2021 09:51:30 +0200 (CEST) Received: by mail-pj1-f41.google.com with SMTP id il9-20020a17090b1649b0290114bcb0d6c2so10293877pjb.0 for ; Tue, 13 Apr 2021 00:51:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=Qwcg64yZ2YepjBnWK/Lc0U93CWdQOp+G17BQ1iJlF4w=; b=fc8kWLLiB/6iAbGCKCvUVy5OXtGroyyK6Ot31rHGZkhy7DIxOQKOJYgvpg2dN12H1v UvsfFWiUDBhXzq5hTRgpZCHVnwpYDwRvQ0xUg3moF1ETrTvOARCst7ylbvae3S03NLPD HdnUCMKDHaOU6Dq8v5hML/g/oYS94iGmiFMXkkrJxEyiolUjXNXk3SfdpHuK70qYjTN1 lzsgsja9OEG/+B46XJ5EezYnWvEHxHzrVAitdjfpxyw+cSWHv2At+PSHwlzxYeF+zI3R jb4uIrSdzkFIFKScHoHYlFLemLhlxdXFkp2okMwNCxw7WJ0yPIkHY9Ho6rJnfzo/1w7M dX1w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=Qwcg64yZ2YepjBnWK/Lc0U93CWdQOp+G17BQ1iJlF4w=; b=LkWxybnyFuxK9FsGRg4xU885HIDp4DtSH/Ozk2lfSEgSR7FLC0y5Xh34hMoq1XAG8x Oo2VfLAP8EfkaUgQF1hjHyjit4f7vIyk2UIpV3YGKDH9rO85zNQVipQo7o/kKVq8Bniv sPADEt8Xy0DMc4rLU+qR0DmMAfZ2AVBFz7AUicaAmttWqwOKnOKwm7E+tSRFnr4+OecZ u62zjYBkTOz2de1yAZwgp8AEKfPrr6Qi1b5BldFEeS0a936r2uX8Ki4EItx1GnVyCfAz udyfNQq4py/sUmzGUDVegxkp+bc6+fMGO727irhtjUxhhL+yEaKh39+pTGT6I0w/Hwrt fyVg== X-Gm-Message-State: AOAM532C23kGGrYqRDsKhQMnAh3O7xhbuv3tj4wdNJ/JGVWEYqYKJJy/ O1K53YBahI+USV/I9vNs4Uw= X-Google-Smtp-Source: ABdhPJzNvi40+lYt+WzgSHmR+jf7GQv1F3zFi585EKMCGk487EaI3uc7nOT2JFmrNWmp9u5/k+33EQ== X-Received: by 2002:a17:90a:414e:: with SMTP id m14mr3469733pjg.9.1618300290078; Tue, 13 Apr 2021 00:51:30 -0700 (PDT) Received: from BG-LT7405.marvell.com (117.205.98.34.bc.googleusercontent.com. [34.98.205.117]) by smtp.gmail.com with ESMTPSA id a65sm11750257pfb.116.2021.04.13.00.51.27 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 13 Apr 2021 00:51:29 -0700 (PDT) Date: Tue, 13 Apr 2021 13:21:24 +0530 From: Shijith Thotton To: "Gujjar, Abhinandan S" Cc: Shijith Thotton , "dev@dpdk.org" , Jerin Jacob , Akhil Goyal , Anoob Joseph Message-ID: <20210413075124.GA21@BG-LT7405.marvell.com> References: <20210409070809.456444-1-sthotton@marvell.com> <8d73cf4b565f5f66badaca26ec3a9f26cedf2304.1618217424.git.sthotton@marvell.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) Subject: Re: [dpdk-dev] [PATCH v2] eventdev: fix case to initiate crypto adapter service 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 Sender: "dev" On Tue, Apr 13, 2021 at 04:08:40AM +0000, Gujjar, Abhinandan S wrote: > > > > -----Original Message----- > > From: Shijith Thotton > > Sent: Monday, April 12, 2021 2:24 PM > > To: dev@dpdk.org > > Cc: Shijith Thotton ; Gujjar, Abhinandan S > > ; Jerin Jacob ; Akhil > > Goyal ; Anoob Joseph > > Subject: [PATCH v2] eventdev: fix case to initiate crypto adapter service > > > > Initiate software crypto adapter service, only if hardware capabilities are not > > reported. In OP_FORWARD mode, software service is not required to > > enqueue events if OP_FORWARD capability is supported by the PMD. > > > > Fixes: 7901eac3409a ("eventdev: add crypto adapter implementation") > > > > Signed-off-by: Shijith Thotton > > --- > > v2: > > - Reworded commit message. > > > > lib/librte_eventdev/rte_event_crypto_adapter.c | 1 + > > 1 file changed, 1 insertion(+) > > > > diff --git a/lib/librte_eventdev/rte_event_crypto_adapter.c > > b/lib/librte_eventdev/rte_event_crypto_adapter.c > > index d903cdd48..e1d38d383 100644 > > --- a/lib/librte_eventdev/rte_event_crypto_adapter.c > > +++ b/lib/librte_eventdev/rte_event_crypto_adapter.c > > @@ -861,6 +861,7 @@ rte_event_crypto_adapter_queue_pair_add(uint8_t > > id, > > * b. OP_NEW mode -> SW Dequeue > > */ > > if ((cap & > > RTE_EVENT_CRYPTO_ADAPTER_CAP_INTERNAL_PORT_OP_NEW && > > + !(cap & > > RTE_EVENT_CRYPTO_ADAPTER_CAP_INTERNAL_PORT_OP_FWD) && > The same check is below ORed with above condition. > This is confusing. Could you recheck & do the necessary changes? > As per comments above, below checks are used to initiate SW service if: 1. PMDs supports OP_NEW, but not OP_FWD, in FWD mode. 2. Does not support OP_NEW and OP_FWD. I have fixed the first point where only support for OP_NEW is checked in forward mode, by adding a check for no OP_FWD capability. > > adapter->mode == > > RTE_EVENT_CRYPTO_ADAPTER_OP_FORWARD) || > > (!(cap & > > RTE_EVENT_CRYPTO_ADAPTER_CAP_INTERNAL_PORT_OP_NEW) && > > !(cap & > > RTE_EVENT_CRYPTO_ADAPTER_CAP_INTERNAL_PORT_OP_FWD) && > > -- > > 2.25.1 >