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 D5C2CA0517; Tue, 9 Jun 2020 15:23:14 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 12E702BF1; Tue, 9 Jun 2020 15:23:14 +0200 (CEST) Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by dpdk.org (Postfix) with ESMTP id 023722BE9 for ; Tue, 9 Jun 2020 15:23:11 +0200 (CEST) IronPort-SDR: 7QJ+40v2AlIBjPLzu1eX43+UUeyTpQB3QrXLLCMTAVVsttXRg9vghNShqGDFf2oxMzb0oiJ3lg aBYaUwM6ej5g== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Jun 2020 06:23:10 -0700 IronPort-SDR: 6gjHRyKRRDEOdpxYUnJiq0rUSuRR+SCPTdzqOs4BedW7gEVU8mPmDj+WInHvGovs3X4vb9+NJW 26uPQEHjzAxg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.73,492,1583222400"; d="scan'208";a="288830024" Received: from fmsmsx108.amr.corp.intel.com ([10.18.124.206]) by orsmga002.jf.intel.com with ESMTP; 09 Jun 2020 06:23:10 -0700 Received: from FMSEDG002.ED.cps.intel.com (10.1.192.134) by FMSMSX108.amr.corp.intel.com (10.18.124.206) with Microsoft SMTP Server (TLS) id 14.3.439.0; Tue, 9 Jun 2020 06:23:09 -0700 Received: from NAM12-DM6-obe.outbound.protection.outlook.com (104.47.59.173) by edgegateway.intel.com (192.55.55.69) with Microsoft SMTP Server (TLS) id 14.3.439.0; Tue, 9 Jun 2020 06:23:09 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=V9OGUBpluD35XhYcdbNYzUl1PdTBdv6foz2esL8m71ZaTp5xR7MwgLclG/AbAgelh27disoIRhpt3PJPIPr5Yh19cqL9dTEOTXov4zW7qqYGhEqJj8ThFqrfxl+gCTGl1nmNHujgkNaf/5eLsHsFOv3bviNK9dcksfaNMB5No/YhiRkZVWrnt1rUhlwmcYrLWFNZiPjhW8juhsbRrQ93tA3u6PGCTMZXFB9bTn6rdxXwU1jaTd/AKdkyU3Qm9g8WkIDIz7gdSm2nqwBuKNTGjWYaAiJiIt4Rd14XwMQM70nbBosUpb/EdswiraJwrulgRiqG9vfn4cILgsKRaUZtjw== 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=7UGHceJoLYXbkNnqgbTxu/Kw8qsDnGLB8Vl48mKeZ1c=; b=T9/a/pF8n0PN2214J2TehDH6ysq1YgJmElfhgYHc+/k4UXmvE4HTEsi7XJy1+PlZ5i6urtj51pp6//dy4/sOm3Ii7nRhqtnw5v2VpRzin1xOEg9FEIG3VmOtmrgF9oLHH0SDrIXg+VoQOkM25auyihFyHryQkAZmzV5RVky9E9PIZZ5n3NTWwwC9a/3uyrqe3pad7mSbqD368Mj6b2wRFzQt0LlKCSjNZlDejnqjSYFiOUwVc5v3Kul4SGBXGmXHAFZAowT9nLI4R4eYtcY9vE+7C9jbZ626TYy88d3QFfnmKsnPnFo5hrtAqsNRWRIhgSlJeVkvikIlm7WDS6Jg7A== 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=7UGHceJoLYXbkNnqgbTxu/Kw8qsDnGLB8Vl48mKeZ1c=; b=H19ZSuFOQngafMMJS4e7bL8O+4r22iRV4XQ+5kPbKJbGraUWNyqGRr5zYb5dH+lS78+leJbVW7jQ6AtuEPto8467i/XAVNQ297hpCZusa0BIiz+vPMTuC4ifftQm2GrCFT2FsqhFALgPQPAzidCXInuC6yuEcxe7e2ZDqRJlS6Y= Received: from BYAPR11MB3301.namprd11.prod.outlook.com (2603:10b6:a03:7f::26) by BYAPR11MB3638.namprd11.prod.outlook.com (2603:10b6:a03:f8::24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3066.18; Tue, 9 Jun 2020 13:23:07 +0000 Received: from BYAPR11MB3301.namprd11.prod.outlook.com ([fe80::f160:29ab:b8f9:4189]) by BYAPR11MB3301.namprd11.prod.outlook.com ([fe80::f160:29ab:b8f9:4189%6]) with mapi id 15.20.3066.023; Tue, 9 Jun 2020 13:23:07 +0000 From: "Ananyev, Konstantin" To: "Coyle, David" , "akhil.goyal@nxp.com" , "Doherty, Declan" , "De Lara Guarch, Pablo" , "Trahe, Fiona" , "Zhang, Roy Fan" CC: "dev@dpdk.org" , "thomas@monjalon.net" , "Yigit, Ferruh" , "Ryan, Brendan" , "hemant.agrawal@nxp.com" , "anoobj@marvell.com" , "ruifeng.wang@arm.com" , "lironh@marvell.com" , "rnagadheeraj@marvell.com" , "jsrikanth@marvell.com" , "G.Singh@nxp.com" , "jianjay.zhou@huawei.com" , "ravi1.kumar@amd.com" , "Richardson, Bruce" , "olivier.matz@6wind.com" , "honnappa.nagarahalli@arm.com" , "stephen@networkplumber.org" , "alexr@mellanox.com" , "jerinj@marvell.com" , "Coyle, David" , "O'loingsigh, Mairtin" Thread-Topic: [dpdk-dev] [PATCH 2/3] cryptodev: add security operation to crypto operation Thread-Index: AQHWOoWN4GXDndi6U0mcdOcaf+c++ajQS72g Date: Tue, 9 Jun 2020 13:23:07 +0000 Message-ID: References: <20200410142757.31508-1-david.coyle@intel.com> <20200604151324.50704-1-david.coyle@intel.com> <20200604151324.50704-3-david.coyle@intel.com> In-Reply-To: <20200604151324.50704-3-david.coyle@intel.com> Accept-Language: en-GB, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-reaction: no-action dlp-version: 11.2.0.6 authentication-results: intel.com; dkim=none (message not signed) header.d=none;intel.com; dmarc=none action=none header.from=intel.com; x-originating-ip: [192.198.151.166] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: ee71e29e-265b-4581-d670-08d80c783fb9 x-ms-traffictypediagnostic: BYAPR11MB3638: x-ld-processed: 46c98d88-e344-4ed4-8496-4ed7712e255d,ExtAddr x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:6790; x-forefront-prvs: 042957ACD7 x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: qqU2gbrQklt+NsY7lvbyJ5vn121do8PZ+x44eMTC2pOwbDYvyaMhTzpT8gRn6KbZyXrSlx0DeZdy9Z2JoxW5Z8pYzwBWPVd8SZXijJm8kB6Ac9dgYtfhuwQb5WAfaBHyyjz98+Fmp3Net+OEvaZXeQSDEL2oq+wGaZiqZvvIWCDmoO5+87D8MO/pYQmc+Hn3Pe4XgwOP6pppslgbdCnqxE7qpQFb1+GYdBbXDxaxuYZ38GHYOwPZgd0j8uKo4rCe6wRegIvpd0brCeui84PniBkAAPdVBo+jzM57s7s3M80aUhgbDztxe1hMW3mXc/ZGUru2Ag5wZOXrfdWuEsL8tTO9b5GAP6UJaYHJ3EVXhIee5J3KlADZJnOqngy5YsL3 x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:BYAPR11MB3301.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFTY:; SFS:(376002)(396003)(346002)(366004)(136003)(39860400002)(33656002)(2906002)(15650500001)(52536014)(5660300002)(8936002)(86362001)(76116006)(71200400001)(316002)(107886003)(66946007)(7696005)(6506007)(478600001)(55016002)(9686003)(6636002)(66476007)(66446008)(186003)(26005)(83380400001)(7416002)(64756008)(66556008)(4326008)(54906003)(110136005)(921003); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata: +bzv9/BziGKu8XppGEjrzi9MrW6DZVKyCBeC1iVAGWhA+7TmJK4J61Zx7ytIiC8RWzJFZ6bLZTxTs0kR2NGM2Wp37N2zqg8hy85TLLZ4QwlyuYO6K+IlkqTUMpJymhD+frwOwYhdxWqNz/nZXWknF/2vkQ07+l5Cl5J3xphpobnEL86qHNR7AH5i9t7HfIhp7eWjzTT9huPccXFRbc2ltIPGGVGUKCARH8oYANjRZMAggc/05bFszTrF1pYljLldCg/Sxw8A+O+qZKxWUR5XSGzsb/uhM0S4S2Xk4gAN7qNqDLsseANY+nmwZwY3vgbStt3tDvcmqZynXt1sJWQc4LGJYROHKZFzildwqV3k71MoCRO6jgYS8Bpa9mWGR5IQdtwOIVHl3h0DZ2SId8Mc51pikaxpFO6Z1k6iBQm0Wiwr/UNuL3nHCsIptENJdTLAdKRuzjFhoASuy8go9Wt6JMQkoHaErb1tfTPJmlokU1XgA5IFBuEmsaf97zAFC72m Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: ee71e29e-265b-4581-d670-08d80c783fb9 X-MS-Exchange-CrossTenant-originalarrivaltime: 09 Jun 2020 13:23:07.5798 (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: MXQ7bVn3qgZFRLjcdeUrKkNxFgwvpWLwWhroZyQaq8D3sKx23Dxrzn/zczxgZOdDZOOSyT0zT/MO6Wz2EZW+nSksxphfdbmpG87tBl7JyMs= X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR11MB3638 X-OriginatorOrg: intel.com Subject: Re: [dpdk-dev] [PATCH 2/3] cryptodev: add security operation to crypto operation 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" >=20 > Add a new security operation structure to the crypto operation to allow > protocol specific parameters defined in rte_security be defined for a > crypto operation. >=20 > Please note this is API changes only. Implementation will follow in > next version. >=20 > Signed-off-by: David Coyle > Signed-off-by: Mairtin o Loingsigh > --- > lib/librte_cryptodev/rte_crypto.h | 11 ++++++++++- > 1 file changed, 10 insertions(+), 1 deletion(-) >=20 > diff --git a/lib/librte_cryptodev/rte_crypto.h b/lib/librte_cryptodev/rte= _crypto.h > index fd5ef3a87..fbc1df791 100644 > --- a/lib/librte_cryptodev/rte_crypto.h > +++ b/lib/librte_cryptodev/rte_crypto.h > @@ -31,8 +31,10 @@ enum rte_crypto_op_type { > /**< Undefined operation type */ > RTE_CRYPTO_OP_TYPE_SYMMETRIC, > /**< Symmetric operation */ > - RTE_CRYPTO_OP_TYPE_ASYMMETRIC > + RTE_CRYPTO_OP_TYPE_ASYMMETRIC, > /**< Asymmetric operation */ > + RTE_CRYPTO_OP_TYPE_SECURITY > + /**< Security operation */ > }; >=20 > /** Status of crypto operation */ > @@ -121,6 +123,13 @@ struct rte_crypto_op { > struct rte_crypto_asym_op asym[0]; > /**< Asymmetric operation parameters */ >=20 > +#ifdef RTE_LIBRTE_SECURITY > + uint8_t security[0]; > + /**< Security operation parameters > + * - Must be accessed through a rte_security_op pointer > + */ > +#endif > + > }; /**< operation specific parameters */ > }; Is there any point to have this extra level of indirection? Might be simply: enum rte_crypto_op_type { .... + RTE_CRYPTO_OP_TYPE_SEC_DOCSIS, }; ... struct rte_crypto_op { .... __extension__ union { struct rte_crypto_sym_op sym[0]; /**< Symmetric operation parameters */ struct rte_crypto_asym_op asym[0]; /**< Asymmetric operation parameters */ + struct rte_security_docsis_op docsis[0]; }; /**< operation specific parameters */ =20 ?