From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 4ED42A04D8; Mon, 21 Sep 2020 17:41:51 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 820791C1E5; Mon, 21 Sep 2020 17:41:50 +0200 (CEST) Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by dpdk.org (Postfix) with ESMTP id 164861C199 for ; Mon, 21 Sep 2020 17:41:48 +0200 (CEST) IronPort-SDR: +/jaHIffeWJm1uhulqk4d9oIwy04oxhqcV/tCd1Wo4yszCnConYfwMDy4eLlSwfWviav5+DTQs vNMV8SYz8pWA== X-IronPort-AV: E=McAfee;i="6000,8403,9751"; a="148063588" X-IronPort-AV: E=Sophos;i="5.77,286,1596524400"; d="scan'208";a="148063588" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 21 Sep 2020 08:41:48 -0700 IronPort-SDR: kMDQEn9fJ577fAq9xCTg6gZGqtZx+eICEjYItj0+woHGBv1wXCg8+5XGq88ahllxcr9QIPr4aO Hf6KEoUBZfsg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.77,287,1596524400"; d="scan'208";a="381979648" Received: from fmsmsx604.amr.corp.intel.com ([10.18.126.84]) by orsmga001.jf.intel.com with ESMTP; 21 Sep 2020 08:41:47 -0700 Received: from fmsmsx603.amr.corp.intel.com (10.18.126.83) by fmsmsx604.amr.corp.intel.com (10.18.126.84) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1713.5; Mon, 21 Sep 2020 08:41:47 -0700 Received: from fmsedg601.ED.cps.intel.com (10.1.192.135) by fmsmsx603.amr.corp.intel.com (10.18.126.83) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1713.5 via Frontend Transport; Mon, 21 Sep 2020 08:41:47 -0700 Received: from NAM11-CO1-obe.outbound.protection.outlook.com (104.47.56.168) by edgegateway.intel.com (192.55.55.70) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.1713.5; Mon, 21 Sep 2020 08:41:43 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Wn+JwzvQKMruQ5gyJqKLaqZaKL3/WCUDyKrn9XW2VbXVjIW9KPO49YVETT7VrtTQp+gdauuDJti2xEYbxx3ngM1c8JOeSbeXXL09RrMgB5cvyIIQLz5vi8np13tENadPaN9KBaQ5iSosWgA4yyQxN3ntO+sHJJbIUJNtSXSktUQN7Qtgda/109T/vuQC5U4XYxXLN7mNq1fKcK0UymgzIdTqkHcHBTVyFhJt1ItjCzIOZPYbAZ6FFu7kud4v3Hs293tW4wO2Fko5QCbGY72r/NLOWmLIiAoVBGN/ha1u6VCa1U8IOcC7YXmoufwTO0ad1jhH5K5dKeT5k2P9AaSMmA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=DJjsl9+hrKjqF5HuRH2g1Ei6K8nyXkoba1ACBnpb/vE=; b=oRJolW8UP4vK9IouUwrePjmSDhFZ7XhFwgsZPhGrni+zISy3Agb5EEx2QZ1LuKVN9OEXXtD9dR+KZCBCuPdDpMH5Vh5IDmxXJdHEXBZZUsBKQkYbV75/x0jXDGCzGU6TR4LVfuECNabtrYKVCN/rHX1v4sGbHOyqlC7t4DkQwGxHtFvCOXgf9xTFFR05N0L6NE0nPjOBvx/VfW+U88UORAe+SvidCxmljisX2EHjLTEZZrJqXE3w6uQbAYN0ywceMDpy7ob66HS+873PiqWcmkVrNNwlG6Q1SsxB2JwRyyttRQzER7MHFPlybnz2UL/yoxbhM4UWgsUTeE0RbbSgyA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel.onmicrosoft.com; s=selector2-intel-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=DJjsl9+hrKjqF5HuRH2g1Ei6K8nyXkoba1ACBnpb/vE=; b=qcOZq+hqY+WicE4cMoqVJ2GZxratnQofB8N1wBYj3k0oktx535wn3PHuNySKifs9ai62ex9gBup07KyhdCcDyMI6HH/SKzKQibV1cI9Sff5nGe7puwXYW+kwVA3n/MaHcdRmK3/osvg2L7hE8n6/BdZ9vMfvn1Jd4qWfWG3eboA= Received: from BL0PR11MB3043.namprd11.prod.outlook.com (2603:10b6:208:33::19) by MN2PR11MB4078.namprd11.prod.outlook.com (2603:10b6:208:150::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3348.15; Mon, 21 Sep 2020 15:41:42 +0000 Received: from BL0PR11MB3043.namprd11.prod.outlook.com ([fe80::11fa:a7fe:329d:9239]) by BL0PR11MB3043.namprd11.prod.outlook.com ([fe80::11fa:a7fe:329d:9239%5]) with mapi id 15.20.3391.024; Mon, 21 Sep 2020 15:41:42 +0000 From: "Zhang, Roy Fan" To: Akhil Goyal , "dev@dpdk.org" , "Ananyev, Konstantin" , Thomas Monjalon CC: "Trahe, Fiona" , "Kusztal, ArkadiuszX" , "Dybkowski, AdamX" , "Bronowski, PiotrX" , Anoob Joseph Thread-Topic: [dpdk-dev v9 1/4] cryptodev: add crypto data-path service APIs Thread-Index: AQHWhbwaRQXVNw2ngE+5SqoPhUuyBqlu/9oAgAP1tgCAABxYAIAAPMew Date: Mon, 21 Sep 2020 15:41:42 +0000 Message-ID: References: <20200904152539.20608-1-roy.fan.zhang@intel.com> <20200908084253.81022-1-roy.fan.zhang@intel.com> <20200908084253.81022-2-roy.fan.zhang@intel.com> In-Reply-To: Accept-Language: zh-Hans-HK, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-version: 11.5.1.3 dlp-reaction: no-action dlp-product: dlpe-windows authentication-results: nxp.com; dkim=none (message not signed) header.d=none;nxp.com; dmarc=none action=none header.from=intel.com; x-originating-ip: [95.44.220.85] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 7acba371-0e6d-4bb0-b7b4-08d85e44d6eb x-ms-traffictypediagnostic: MN2PR11MB4078: x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:8273; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: +KqH/IERJaGaw8oNqLCDhVCiVT0uxASdoq3BgTzF34Mai0MQ7AyWcRfHWB0DKOWeg+DQ0mjVjxn2iKx4OPCghwTshLNzzDVMX1HSDKUfsriJrop9KzJ0X4eKfAOmC1M5nrR+H676UN4I0m0Dp16x17oZhhRvh79Xs3+N2buDxiOgZzuIfkuRT+hfNwPI2j0nGPJ2i+/nJy4DswSWSvHcN/3fvZ0Lm5kOPvyokEveq8kPmJzxjK47/mf8cDZ7tSMIf5ST/tYc/VnvNXgbwTU0qLvxkKOrdwidOg5LUEeaG3L5l+YECdvMt3sai24N9bmUnu0n0KukKQZOD+t9T5DPtg== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:BL0PR11MB3043.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(39860400002)(366004)(136003)(346002)(396003)(376002)(55016002)(33656002)(7696005)(86362001)(53546011)(5660300002)(52536014)(2906002)(6506007)(8936002)(4326008)(316002)(71200400001)(26005)(8676002)(83380400001)(186003)(66476007)(9686003)(110136005)(64756008)(478600001)(66556008)(66946007)(66446008)(76116006)(54906003); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata: fs+87Ht+Fg2OO45PTRBiEahNaLvFMgFqFg2oV3IeGDRNcleGRrY44mzS9L0J2n+Zy4rg1xM4AcLhI48O1pv6xeouuWJ7gHSTi0wpscpJXj6kVlIq6QQPjKwqaJK6EKLvKc8AmMcjjGHCh7XUDCbdzCwbh4+Kk/1f8tzeznGpZ3UPwMdvrw0qtWY+zKEQ8AgeUdswVo6UPILm3IcgqxAVshapK+XgztYdzkhCoX34Q4N3JMPIR6bSxpc+pjnRJt9fmOiQkU0VSYHzbGCMdMxOEm7V3tRAKSx1M2gny/+4CDoQfpiDcUdWO2JNODzCw98ZYDwmnAd+6XnWOobk1Te41iB8You/nIOEN9lkomOGB8Nv5ji5IZ5TuEyh6he8f9IbgAzqLAcBJtM+YCcPA6rmT4nnk7QFsSCJSqgV6U2pFZAMbGLPrHEAedNTkNC82A9xH9hPl8EhRk2s0YElnFcNcDvQrJQLdhlU/xFbMoBKZHSflQg1L+3N659B86gNN/QytnLTtGSombgej2JeNcavfLFVfoURsA3oVf1qr67iFPDzpRbfXTxFfqHZ31ZSkxM6ebcejV8d1JY5ye5N+vLC2RRY4bTEYrUrcKcOhbkQJlW1L3w1IZn/zfo1iyofaol6l1EsuhKsC7k+mWlis7Dz+w== Content-Type: text/plain; charset="Windows-1252" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: BL0PR11MB3043.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 7acba371-0e6d-4bb0-b7b4-08d85e44d6eb X-MS-Exchange-CrossTenant-originalarrivaltime: 21 Sep 2020 15:41:42.4197 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: 4o0xgb5lFiJVboEY0byhNvEjglKPuEgGo+4K0DqiF29BW2KJLZV+sNuo0DsBBY4Cql0k3lhRwZ7fmYoRxW2H+g== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR11MB4078 X-OriginatorOrg: intel.com Subject: Re: [dpdk-dev] [dpdk-dev v9 1/4] cryptodev: add crypto data-path service APIs X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 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" Hi AKhil > -----Original Message----- > From: Akhil Goyal > Sent: Monday, September 21, 2020 1:00 PM > To: Zhang, Roy Fan ; dev@dpdk.org; Ananyev, > Konstantin ; Thomas Monjalon > > Cc: Trahe, Fiona ; Kusztal, ArkadiuszX > ; Dybkowski, AdamX > ; Bronowski, PiotrX > ; Anoob Joseph > Subject: RE: [dpdk-dev v9 1/4] cryptodev: add crypto data-path service AP= Is >=20 ... > IMO, the following union can clarify all doubts. > @Ananyev, Konstantin: Any suggestions from your side? >=20 > /** IV and aad information for various use cases. */ > union { > /** Supposed to be used with CPU crypto API call. */ > struct { > /** array of pointers to IV */ > void **iv; > /** array of pointers to AAD */ > void **aad; > /** array of pointers to digest */ > void **digest; > } cpu_crypto; < or any other useful name> > /* Supposed to be used with HW raw crypto API call. */ > struct { > void *cipher_iv_ptr; > rte_iova_t cipher_iv_iova; > void *auth_iv_ptr; > rte_iova_t auth_iv_iova; > void *digest_ptr; > rte_iova_t digest_iova; > } hw_chain; > /* Supposed to be used with HW raw crypto API call. */ > struct { > void *iv_ptr; > rte_iova_t iv_iova; > void *digest_ptr; > rte_iova_t digest_iova; > void *aad_ptr; > rte_iova_t aad_iova; > } hw_aead; > }; >=20 >=20 The above structure cannot support the array of multiple jobs but a single = job. So we have to use something like struct { void **cipher_iv_ptr; rtei_iova_t *cipher_iv_iova; ... } hw_chain; struct { void **iv_ptr; rte_iova_t *iv_iova; ... } hw_aead; Is it ok? Regards, Fan