From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-db5eur01on0059.outbound.protection.outlook.com [104.47.2.59]) by dpdk.org (Postfix) with ESMTP id C948B2BA8 for ; Mon, 17 Sep 2018 12:46:05 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=hGzTOZKu3L8/C2r+J/5QisWFnad3e28HwMKvDOpS9QA=; b=gjaIcvGC1EUW1A7m//gUxaxblODW2IqrxNw87NpEOt33W6muug1mF/F0xjK7H7BOfVqpGRtclvx7yyE+HtZj3P0jn4wBWhpkDsPqN+NK3MBVWqlweiz9+IVKNwz1Mz8TS6qLGFF3x+AoQFzE1QD/qUeiklMYOUsoDdldlt91Y6Q= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=akhil.goyal@nxp.com; Received: from [10.232.134.144] (14.143.30.134) by AM6PR04MB4888.eurprd04.prod.outlook.com (2603:10a6:20b:6::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1143.15; Mon, 17 Sep 2018 10:46:00 +0000 To: Anoob Joseph , Pablo de Lara , Thomas Monjalon Cc: Anoob Joseph , Jerin Jacob , Narayana Prasad , dev@dpdk.org, Ankur Dwivedi , Murthy NSSR , Nithin Dabilpuram , Ragothaman Jayaraman , Srisivasubramanian S , Tejasree Kondoj References: <1528476325-15585-1-git-send-email-anoob.joseph@caviumnetworks.com> <1536033560-21541-1-git-send-email-ajoseph@caviumnetworks.com> <1536033560-21541-6-git-send-email-ajoseph@caviumnetworks.com> From: Akhil Goyal Message-ID: Date: Mon, 17 Sep 2018 16:15:45 +0530 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <1536033560-21541-6-git-send-email-ajoseph@caviumnetworks.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US X-Originating-IP: [14.143.30.134] X-ClientProxiedBy: PN1PR01CA0090.INDPRD01.PROD.OUTLOOK.COM (2603:1096:c00:1::30) To AM6PR04MB4888.eurprd04.prod.outlook.com (2603:10a6:20b:6::23) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: e27d79d6-67df-4563-0d1b-08d61c8ac458 X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: BCL:0; PCL:0; RULEID:(7020095)(4652040)(8989137)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(5600074)(711020)(4618075)(2017052603328)(7153060)(7193020); SRVR:AM6PR04MB4888; X-Microsoft-Exchange-Diagnostics: 1; AM6PR04MB4888; 3:GKyTXSY/ss/GQEuZTe1ebZiXsikYmwmCIabzC8R4esPMVIx9Q8mJK5QsSYzNF9DnllyMDAtWyz8Ns1XU14TKQL1WXFGGSeBC+DLJHd5ATxX+ErCipJt+nFipcmwPXd9YjFip4CBZb/8d+bbtdWjJp6RzxDcsOESLPjaKRYRR+mPOW+knTMqiJ5eIn6BAFCtbgxQAncSMppilvkRPglFOLIlbtkh9UbFvWSlOzq/1DFp/uwS96seqBCjaMuU6T+l4; 25:1Wzd163g/VbuieHRGaDhLGEUqanZldFAb5bkg0Vs7uB5TWx0OPho9ardOtZhq/NFp0BIXbcxbdCHOKk2GjA/ju/pCPMLkKI73D1dya1sVA07TT/ghYmnKPNVu196Sd1g5NCY5peMN36FPPfsGFyz6bboiC2lIxpP8X+uYOGvwMeW64+nUUKl215flMvNgZpGt36XpMfWU4Tsepotl/JSscFaIaKTITw/CqlwpwoWbXAg8idACMFdauxtr5PtfCmfuv2gJrCqGiPkRRBejOssOoTcbc24TXtlgLT2V4WaVnr+NFYAJiFfF8tQ8WGFTGRiV1Q2ow2+HYd5gh0wv6bMsw==; 31:vfYyDUNNj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X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(3231355)(944501410)(52105095)(3002001)(10201501046)(93006095)(93001095)(6055026)(149027)(150027)(6041310)(20161123564045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(20161123562045)(20161123558120)(201708071742011)(7699050); SRVR:AM6PR04MB4888; BCL:0; PCL:0; RULEID:; SRVR:AM6PR04MB4888; X-Forefront-PRVS: 0798146F16 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(6049001)(366004)(39860400002)(136003)(346002)(396003)(376002)(199004)(189003)(6486002)(478600001)(47776003)(66066001)(65806001)(65956001)(64126003)(7416002)(14444005)(229853002)(36756003)(5660300001)(50466002)(5009440100003)(86362001)(2906002)(65826007)(31696002)(53936002)(6666003)(8936002)(68736007)(4326008)(8676002)(67846002)(446003)(11346002)(956004)(2616005)(77096007)(25786009)(3260700006)(186003)(52116002)(105586002)(16576012)(58126008)(110136005)(31686004)(2486003)(52146003)(23676004)(106356001)(316002)(54906003)(476003)(6246003)(76176011)(44832011)(386003)(53546011)(97736004)(230700001)(305945005)(486006)(7736002)(26005)(3846002)(6116002)(81156014)(16526019)(81166006)(110426005); DIR:OUT; SFP:1101; SCL:1; SRVR:AM6PR04MB4888; H:[10.232.134.144]; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; Received-SPF: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtBTTZQUjA0TUI0ODg4OzIzOkFqTjJPQ1NJTmZ6cFdhVVEvTWprLzA2d1hY?= =?utf-8?B?L0FhZnlrYlY2NjQvcXhWNXAySGgyaFR6YXY3YktrVVpHcVM4V0FIT1Z3RlNn?= =?utf-8?B?QjB2MTRCTFlrY0d2bnQ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ALXBmpapt0ZCdBHI2mUWxrY+Vau5zFbBg9zDbtrNy0a1/fXlebBl0cDQ10LU+xDCZXT+9BGRItI+Ay+z0UDEOH22U2l2qcw==; 5:4e6kj2eUwTM2OrQexdPPZe1l7s45hU6zjcD4ddA3398cNI1cyKw1JgB0KE9aRrhziEtiJYkO45kKYLDZaRcIoXD0l49jjLV4KgQdvtak7TpMsfZG4W7aehhKADP2ZhWiUInQCY2uu9V58SGT5zue+iQk5MXjB9JA0X9sIov6/Vs=; 7:gYwozaMXSigyLMEuN4jzL0S82qu6e/qrqpt9LWPmrx/IMLpcwk+eFNnXjLBjggSS6t7V0wC92bsEvSBaNkmDZdo1zyzfa1j7VRGgHaL94BHuRHRPfJcaFkzAYNBDNB7K1049nzBYWHZ687sUvckl8WEUjfSaXfEhAQ8jHr7VCGa8GEhPlJY33sHktlQ0L6is0xzb0HfrJxw8sYmnG7B5cBR3CFZEW0csHULUUAhEIELTXBXrHjrAmPEcywd5/wvl SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 17 Sep 2018 10:46:00.1892 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: e27d79d6-67df-4563-0d1b-08d61c8ac458 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM6PR04MB4888 Subject: Re: [dpdk-dev] [PATCH v2 05/33] common/cpt: add common code for init routine 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: , X-List-Received-Date: Mon, 17 Sep 2018 10:46:06 -0000 On 9/4/2018 9:28 AM, Anoob Joseph wrote: > From: Anoob Joseph > > Adding code identified common for OcteonTX family crypto devices. This > patch is adding the code required by the structures and code path of > init routine. > > Signed-off-by: Ankur Dwivedi > Signed-off-by: Anoob Joseph > Signed-off-by: Murthy NSSR > Signed-off-by: Nithin Dabilpuram > Signed-off-by: Ragothaman Jayaraman > Signed-off-by: Srisivasubramanian S > Signed-off-by: Tejasree Kondoj > --- > drivers/common/cpt/cpt_common.h | 54 +++++++++++++++++++++++++++++++++++++++++ > 1 file changed, 54 insertions(+) > create mode 100644 drivers/common/cpt/cpt_common.h > > diff --git a/drivers/common/cpt/cpt_common.h b/drivers/common/cpt/cpt_common.h > new file mode 100644 > index 0000000..feca5fe > --- /dev/null > +++ b/drivers/common/cpt/cpt_common.h > @@ -0,0 +1,54 @@ > +/* SPDX-License-Identifier: BSD-3-Clause > + * Copyright(c) 2018 Cavium, Inc > + */ > + > +#ifndef _CPT_COMMON_H_ > +#define _CPT_COMMON_H_ > + > +/* > + * This file defines common macros and structs > + */ > + > +/* > + * Macros to determine CPT model. Driver makefile will define CPT_MODEL > + * accordingly > + */ > +#define CRYPTO_OCTEONTX 0x1 > + > +#define AE_TYPE 1 > +#define SE_TYPE 2 > + > +/* cpt instance */ > +struct cpt_instance { > + uint32_t queue_id; > + uintptr_t rsvd; > +}; > + > +struct cptvf_meta_info { > + void *cptvf_meta_pool; > + int cptvf_op_mlen; > + int cptvf_op_sb_mlen; > +}; > + > +struct rid { > + uintptr_t rid; > + /**< Request id of a crypto operation */ no need for extra tab for comments. > +}; > + > +/* > + * Pending queue structure > + * > + */ > +struct pending_queue { > + uint16_t enq_tail; > + uint16_t deq_head; > + uint16_t soft_qlen; > + /**< Software expected queue length */ > + uint16_t p_doorbell; > + struct rid *rid_queue; > + /**< Array of pending requests */ > + uint64_t pending_count; > + /**< Pending requests count */ > +}; better to add comment for each element of structure. Also remove extra tab for comments(here and any other place if any.) > + > +#endif /* _CPT_COMMON_H_ */