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 CDAD2A04B5; Tue, 27 Oct 2020 04:52:56 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 3F3B02B9D; Tue, 27 Oct 2020 04:52:55 +0100 (CET) Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by dpdk.org (Postfix) with ESMTP id 382091D9E for ; Tue, 27 Oct 2020 04:52:53 +0100 (CET) IronPort-SDR: XL9NAlifPQg70FIliKE0c6pP/51BxYoodcYqWTPytGLx6aLq6a/weNRWkWC2jGUbm637GKici/ iIAkMHk8TSUg== X-IronPort-AV: E=McAfee;i="6000,8403,9786"; a="185758093" X-IronPort-AV: E=Sophos;i="5.77,422,1596524400"; d="scan'208";a="185758093" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 26 Oct 2020 20:52:50 -0700 IronPort-SDR: h5OoFDeKJAlOkk9elRcmyRP6wn0BXJGTQr9Q53Ev+ygWKU3xnMgWxtBx6VAe6twW9bLxF9He7A 92GfpsmZkykA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.77,422,1596524400"; d="scan'208";a="355406648" Received: from orsmsx602.amr.corp.intel.com ([10.22.229.15]) by fmsmga002.fm.intel.com with ESMTP; 26 Oct 2020 20:52:50 -0700 Received: from orsmsx601.amr.corp.intel.com (10.22.229.14) by ORSMSX602.amr.corp.intel.com (10.22.229.15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1713.5; Mon, 26 Oct 2020 20:52:49 -0700 Received: from ORSEDG602.ED.cps.intel.com (10.7.248.7) by orsmsx601.amr.corp.intel.com (10.22.229.14) 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, 26 Oct 2020 20:52:49 -0700 Received: from NAM02-BL2-obe.outbound.protection.outlook.com (104.47.38.54) by edgegateway.intel.com (134.134.137.103) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.1713.5; Mon, 26 Oct 2020 20:52:49 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=RXBi+7ZvLJ81w+WlRnUO1/FrH78ONlSTFedH+X8ogfJF5ZdIKYwHvWspmTFgnYbQtGAbf6f4cZTpceTMWjlplTpO+G6p3Tc1CPX4P03/KA5xM1daMhZ/dxNGdxslztQl0VIIQVI+KX2BEd6nQX4n+d62yL1IjS7ItuyFFOJ12lUksRoaN5zuOlV/DFUPUhklti7TwLD61YOhItwtjIbolr9LKiIz44K2nANDKlfIv7pxkREY+APgbajMZOfwOUfnA76FF226NnqmMDKccz7J3yMKNhhxMNgWMnCCz3Pl3AIbwa8DRt6reS87L6CQAD7ZUvbnm6lqpBRaBE7JAIs7Vw== 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=dfxzyEInPbOoJ+RqINCeMtdkrmkQOsi4xZrD9ZKBQq0=; b=Z+akyVkiRhQindexp+H7EO4JLw+SuDt4nQ5fC43gazeK+kqGpZiXBB5JO2ZoJIHcppK0XtH2HB/ostCRNoUPS+95kQSNwudmJhcCJb/4xGoYqe6d12qLgwtU9gsxjwm5bx1pkJ7yKi3MxGoJWJIcrGOTKNnAqo8JvqfcWUFQ0nQjwukgJSSx966CEEikJ35Bt+mtPghtjhuru1EJLro7jiQgF8xxVuxpZOx28zyH+GbRZqgDtkxzzysfWTkwg27JSJ8U61JwAffV/8SB8bcNJ1StqT8kssF7leCyp0n45LftoW7aipdwjGRAdTbJsVhRtWstZZsHKuuQRNIK8mdpTA== 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=dfxzyEInPbOoJ+RqINCeMtdkrmkQOsi4xZrD9ZKBQq0=; b=X7UnOhN/oPMLjXnDs88YKiWOYxqSqeqauYcpbvGQjImCviAI/5yLyqwJBpI/TWB1xQts9ZtiOpIBIqy/Ih2lGn7XM7CexxSnfR1FybfZ38rRB1eDv2rDPz3tjDTW87nLopPnpWS8+X7t/BlUMCYnhRpowlB5OthIJl+6CdPV+1s= Received: from MWHPR11MB1838.namprd11.prod.outlook.com (2603:10b6:300:10c::11) by MWHPR11MB1773.namprd11.prod.outlook.com (2603:10b6:300:10f::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21; Tue, 27 Oct 2020 03:52:46 +0000 Received: from MWHPR11MB1838.namprd11.prod.outlook.com ([fe80::20fb:cc03:ce89:f0ea]) by MWHPR11MB1838.namprd11.prod.outlook.com ([fe80::20fb:cc03:ce89:f0ea%7]) with mapi id 15.20.3499.018; Tue, 27 Oct 2020 03:52:46 +0000 From: "Gujjar, Abhinandan S" To: Akhil Goyal , "dev@dpdk.org" , "Doherty, Declan" , "Honnappa.Nagarahalli@arm.com" , "Ananyev, Konstantin" CC: "Vangati, Narender" , "jerinj@marvell.com" Thread-Topic: [v4 3/3] doc: add enqueue callback APIs Thread-Index: AQHWq8kq6RL4BwL1xU+gtVhivPQLeKmqP0QAgACPoIA= Date: Tue, 27 Oct 2020 03:52:46 +0000 Message-ID: References: <1603619090-118652-1-git-send-email-abhinandan.gujjar@intel.com> <1603619090-118652-4-git-send-email-abhinandan.gujjar@intel.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: 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: [103.5.135.70] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: d8c4a757-206d-491c-3145-08d87a2bc456 x-ms-traffictypediagnostic: MWHPR11MB1773: 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:8273; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: efcURN5MgrQuaE4fe5pUCXgHRxyQInTB2vD140eEMYqfAI+XFRJnSbjjoENP3oo/eZ8LYUDhu9xIoDn536ZTChURAtSdX9YuD4F0VfMYKzkFEQMCchZ6GksJCQczOUAtFv2hbaLSoYKpDRkfOlghYO8PEJVoQnNHAxAUHLUvBN94I03PL3Md0tfywJMaeWuohZ7NemNaCQW3pG0ngcAVFatTd55r271zdfnCFrGbjGYvq7Ze531ckWVSAFuWiVaNYC/aDC0T232PRMdf9XrkXx3AQ9GTeKP0br/+KA8nUXqJVLHheo5euLWaE1GxxP5rROjwW55w0fvGDNcTwYnriw== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:MWHPR11MB1838.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(376002)(396003)(346002)(39860400002)(136003)(366004)(6506007)(316002)(66556008)(64756008)(66946007)(66476007)(66446008)(52536014)(5660300002)(9686003)(478600001)(83380400001)(6636002)(2906002)(186003)(7696005)(76116006)(33656002)(71200400001)(55016002)(86362001)(4326008)(8676002)(110136005)(54906003)(53546011)(26005)(55236004)(8936002); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata: F998apssxSE1Jtcq8JpfCAudnTQFx1V34dnprKoOT03Iu3LmWvZD732awL91ltMe4vJxXsUN37JISb5UvJcJ57rFImiOksVVbd0s4dFYG1JxA6f5K6XoS9tq5GZ2mQeT39FN5rs3BVE9Sr+WPmkxQalEGlVZmLgBg2Ucy9XeuHraIHDU+pk9XkD8+DRPMj/ZEPUbYHa+Ygavml9mNHKHF2MLxBZ6NfkeGr9xbLhgKrt2lY66lABrPX1uV9ERkZieNsGQTts7sFhZ31O8r4ipG35T9lYNxjlVXPi1MNtxPGQ+Uat9Bf++TBsPZIuXwELFQrHdLmvw+/kC4QEPo0+6UJknKrZRc71ESNXTMMDT0KgkY+qKVO6eZ8YPfIut6tak1ceP0GBwDHdO41bmHOEaEhWn2tweblx96lQIuJLnLlJ04GjCDSVjhy6+dPhfKJwlRS1qWeBcJ8awfLQuKDcNug2B+yxjXF2sWmjPQIguNeA41zUj2K8V1lHIa8H489Y1AmRZK6PkPS2qpQjiYNxubdWbyvgR8VD5xfoOhHpg1E6+wVx+XZU4+zPDXZia6kBiGD7sKpVGEDdzdoSTJzWl54IqFgTz7arik0GqTt85XmhmRKYKrJFlP26w2oistJwi86IZEwz4g25U617FWHfOjQ== Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: MWHPR11MB1838.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: d8c4a757-206d-491c-3145-08d87a2bc456 X-MS-Exchange-CrossTenant-originalarrivaltime: 27 Oct 2020 03:52:46.6751 (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: L4uXzBSgBRkMPN53YtrydF72mpw4eF/xJMRJT51xYJb8kVV9q2rI4Q6x7WJteXFCkLp0mTQ/jbh2tXvmgo/Q3kFTZVQ1eRPTNQdUTz6qcCI= X-MS-Exchange-Transport-CrossTenantHeadersStamped: MWHPR11MB1773 X-OriginatorOrg: intel.com Subject: Re: [dpdk-dev] [v4 3/3] doc: add enqueue callback 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, Please find few comments inline. Thanks Abhinandan > -----Original Message----- > From: Akhil Goyal > Sent: Tuesday, October 27, 2020 12:39 AM > To: Gujjar, Abhinandan S ; dev@dpdk.org; > Doherty, Declan ; > Honnappa.Nagarahalli@arm.com; Ananyev, Konstantin > > Cc: Vangati, Narender ; jerinj@marvell.com > Subject: RE: [v4 3/3] doc: add enqueue callback APIs >=20 > > Subject: [v4 3/3] doc: add enqueue callback APIs > > > > Add enqueue callback support for cryptodev library > > > No need for separate documentation patch. It should be part of patch whic= h is > adding The functionality. Ok >=20 > > Signed-off-by: Abhinandan Gujjar > > --- > > doc/guides/prog_guide/cryptodev_lib.rst | 22 ++++++++++++++++++++++ > > doc/guides/rel_notes/release_20_11.rst | 5 +++++ > > 2 files changed, 27 insertions(+) > > > > diff --git a/doc/guides/prog_guide/cryptodev_lib.rst > > b/doc/guides/prog_guide/cryptodev_lib.rst > > index 72129e4..bb3de61 100644 > > --- a/doc/guides/prog_guide/cryptodev_lib.rst > > +++ b/doc/guides/prog_guide/cryptodev_lib.rst > > @@ -366,6 +366,28 @@ can never be larger than ``nb_ops``. > > uint16_t rte_cryptodev_dequeue_burst(uint8_t dev_id, uint16_t qp_id= , > > struct rte_crypto_op **ops, > > uint16_t nb_ops) > > > > +User callback APIs > > +~~~~~~~~~~~~~~~~~~ > > +The add API configures a callback function to be called for each > > +burst of crypto ops received on a given crypto device queue pair. The > > +return value is a pointer that can be used later to remove the > > +callback using > > rte_cryptodev_remove_enq_callback(). >=20 > Does that mean callback cannot be called for each packet and it will be c= alled > for Each burst only? Yes. This is similar to ethdev's rxtx callback which is called for a burst = of packet, where each packet can be processed one after the other. >=20 > The usage of these APIs is not clear with this documentation. Probably yo= u can > add More text/ pseudo code about the sequence of APIs to be used. One of motivation for the callback is mentioned in the cover letter. Since = the usage from eventdev world & the callbacks are generic, I didn't not mention. Plea= se let me know, if you think of any text which adds more clarity to the usage. >=20 > > +Multiple callback functions can be added for a given queue pair. >=20 > Can we add callbacks at runtime or is it before the first enqueue only? Yes. I will add some text for this.=20 >=20 > > + > > +.. code-block:: c > > + > > + struct rte_cryptodev_cb * > > + rte_cryptodev_add_enq_callback(uint8_t dev_id, > > + uint16_t qp_id, > > + rte_cryptodev_callback_fn cb_fn, > > + void *cb_arg); > > + > > +The remove API removes a callback function added by > > rte_cryptodev_add_enq_callback(). > > + > > +.. code-block:: c > > + > > + int rte_cryptodev_remove_enq_callback(uint8_t dev_id, > > + uint16_t qp_id, > > + struct rte_cryptodev_cb *cb); > > > > Operation Representation > > ~~~~~~~~~~~~~~~~~~~~~~~~ > > diff --git a/doc/guides/rel_notes/release_20_11.rst > > b/doc/guides/rel_notes/release_20_11.rst > > index 48717ee..7e2fd30 100644 > > --- a/doc/guides/rel_notes/release_20_11.rst > > +++ b/doc/guides/rel_notes/release_20_11.rst > > @@ -285,6 +285,11 @@ New Features > > * Added scatter gather support. > > * Added NIST GCMVS complaint GMAC test method support. > > > > +* **Added enqueue callback APIs for cryptodev library.** > > + > > + Cryptodev is added with enqueue callback APIs to enable > > + applications to add/remove user callbacks which gets called for > > + every enqueue operations. >=20 > Please follow the sequence mentioned. It should be after the other new > features Of cryptodev. Ok > > > > Removed Items > > ------------- > > -- > > 1.9.1