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 0C491A0A05; Tue, 19 Jan 2021 18:54:07 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id C942A140F42; Tue, 19 Jan 2021 18:54:06 +0100 (CET) Received: from EUR05-DB8-obe.outbound.protection.outlook.com (mail-db8eur05on2075.outbound.protection.outlook.com [40.107.20.75]) by mails.dpdk.org (Postfix) with ESMTP id 9CD46140F32 for ; Tue, 19 Jan 2021 18:54:03 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=QMk0D2PUalOb7PwduujeUqTEkDsnrJo1LlZD68K8w4u9PqnMEOWwu2ec0lZwSSLi8FrcEkorgjUAa+adesH6XPJ+uHhL/RKHa2/BQBj5cFgV+lIrrul/ICozMdloh0cZUPhzKU1QRsFc5FIqaIkUsFR5V7TGkix7yqGK60mnbzND5eIKIFEtkaSuCvpylTOnVML+KQW41+a/reh0ftXyNXCUGQ6T5GGQufcSrfyaIgBfK7ZjW0E9i47POuhUXrHwTR7aAz68A+k+9tI6Nk1rFwXN9CkUsGPXbAMyo9lxcPYl+fSd0GIMJC8pAbIE7Copxrw+nYCkyAaTdObeER3kZg== 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=sVEaq2jWHI7TnaZhJjaDaODldR+/CW1ppreMEuF4Op4=; b=Vjeg9OPN+FATUHOBut8AeO+5+tFxwd43bFli33icp8Jvv2miRos+hvatfBlFRCimCddtuqiMBYtqEPMk0LG05O5WwPw8wIpiIu7TMP+z8sMWgk133Cc5sIdGoRRfh5LW8CCTVwS5yoG6mJgQA41qarZqX0pINEV8+cJr7h3CHQSOf0wPep+r9gkG655Cwt/pZCT7yPj03qEsn9YYyDzRZZihvqSJLFDjcCIEZd1AFzLcbzp3LYE4RE4+H2Y8eR/7D1epqPsxD/m3W85ljXBH48jtfbciKzPtGVPII2noLgwk8sufixPaGZwyk5Qigm8lAnrpGM1VMtWKDxTv7tndBw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=sVEaq2jWHI7TnaZhJjaDaODldR+/CW1ppreMEuF4Op4=; b=SlGVirHqS2CLh84kQVjshURQOWLWOAoSnlL0LTArCI8WmQ5F7obBcgpEquQMNQG4UCLQrM7hEn0IVH83EUyW+MkQXRbbv55hUCCTEyn4wqz2dg6fbDjtDp4CcDLLas9EGkZF5TU4EhXvp376aaRKewB5ea9nDG/Y/MqFA+VMd9o= Received: from VI1SPR01MB0363.eurprd04.prod.outlook.com (2603:10a6:803:c9::10) by VI1PR04MB3054.eurprd04.prod.outlook.com (2603:10a6:802:3::25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3763.11; Tue, 19 Jan 2021 17:54:02 +0000 Received: from VI1SPR01MB0363.eurprd04.prod.outlook.com ([fe80::b8c3:8fe4:846b:3bd1]) by VI1SPR01MB0363.eurprd04.prod.outlook.com ([fe80::b8c3:8fe4:846b:3bd1%5]) with mapi id 15.20.3784.011; Tue, 19 Jan 2021 17:54:02 +0000 From: Akhil Goyal To: Matan Azrad , "dev@dpdk.org" CC: Thomas Monjalon , Ashish Gupta , Fiona Trahe Thread-Topic: [PATCH v2 10/10] compress/mlx5: add the supported capabilities Thread-Index: AQHW6cfDMTIxTjBGdk6zJah2/8kWx6ovQsIg Date: Tue, 19 Jan 2021 17:54:02 +0000 Message-ID: References: <1610373560-253158-1-git-send-email-matan@nvidia.com> <1610554690-411627-1-git-send-email-matan@nvidia.com> <1610554690-411627-11-git-send-email-matan@nvidia.com> In-Reply-To: <1610554690-411627-11-git-send-email-matan@nvidia.com> Accept-Language: en-IN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: nvidia.com; dkim=none (message not signed) header.d=none;nvidia.com; dmarc=none action=none header.from=nxp.com; x-originating-ip: [122.162.45.104] x-ms-publictraffictype: Email x-ms-office365-filtering-ht: Tenant x-ms-office365-filtering-correlation-id: 1e819f32-4591-4292-17d9-08d8bca334b3 x-ms-traffictypediagnostic: VI1PR04MB3054: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:8882; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: 1SOqP7Zivcowb39YT2+9XPvftDjrdME8Nr/aOL1Tttl0IzeCzd3oEHAwmLrgBsPYDM/FBJbDNyGV4J442rZePFV/Oph9ccuer3PR38VZ/U9SNiW4B/4tY+P8Am7EOQDbdjJDo5zQWQacXOMvv6xpS/X6YCIoFma3x2ERKDz3kbToDzyA1jMMv7mTnfTs+q0BSV6s4f0N3BuwAjIM4yyal6aKYbLSGlg0ChdP+2ieJGHECup1tw3OIE7tSNAKm5jAtgLJvo/LvxQyw/lIuzou9++Jzvb6yW51MgpDOIhLBHPaHQXB7+Rm8oyhr2PspSADll49uhGnIfhuZod9uFwt1NdGM9b2Ik3uvg9+eRDSlf37OfP5pOD7/g6DlEvGk7tedV/Hcf0N8JjxJbQFMgsJzDkWCDgq+1uiazmyL3ZkA6/vS5QEZMZ9h10qHaIYS84REUdo0PAuJwtCXQZj6C57fZT6fXe1qBNhoOUnCEeWnBdrqp0O7aKreqAUabbvU3mQE45GoMyt2IkZhla/2Y0mrXjGHXHL8RS6yOp4HX7PBSahDkzIu5WrQ8W3mRtSI7vi7AYcchBusuRkOcxVYysSDuMWtHGigCrH6gFRs/SZl94= x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:VI1SPR01MB0363.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(346002)(396003)(376002)(136003)(366004)(39860400002)(66946007)(64756008)(76116006)(66476007)(66556008)(66446008)(52536014)(5660300002)(9686003)(55016002)(478600001)(83380400001)(2906002)(6506007)(186003)(966005)(8676002)(71200400001)(26005)(4326008)(316002)(44832011)(54906003)(110136005)(86362001)(7696005)(33656002)(8936002); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata: =?us-ascii?Q?r5ZEwq3MV8GtUgU+Y3FhwejXxNRAiN5gLzyQ1w9ta2yBoQ1w4TC+8fkrcDOR?= =?us-ascii?Q?iK+HZb7PIGxNITUoUBS6LysGbSRlCPeLdllcUAEf7J+/IEFvbXFlBWPb4GSf?= =?us-ascii?Q?IsbJPh9tqb6RnTBX/suPpKMvInP+nl1KEBf+qyvGBleEOyuMrV+awHE6ImFJ?= =?us-ascii?Q?Ri7QMmDZ69enQI/kwI5LKKwBzx9Pf5+xbz/Wp8wVsDPRlyQC0Ik6rx2yrRgB?= =?us-ascii?Q?oRqOwUM+07OYsTMXT7KrUaMf+JjAvxLrASn3j0T7ui+I4pl7HJxzbKMhe9Pa?= =?us-ascii?Q?NYqdzamQEf13rn3e6Ns024GwxVFsoTzu/zQEE9KX7tAEeGKixRCPCQkfqjLj?= =?us-ascii?Q?Bh3/NhHHmH/Za7Ka1tgoZvAQMJoG3sFIx2cUYyDBvAxnf2Y9ysn2OSnIhirI?= =?us-ascii?Q?MbM69C/V9wyKW4mQagRlJ3x6AqwPGjqBo94wagzlD7tpuy/XciAEneBWHp5l?= =?us-ascii?Q?0KQH0SaJIGFcuhQPUQcCQ+Um1mojwBvRrdEGmUVvO8T//BZYZ6jD1Ry/FCOF?= =?us-ascii?Q?85+Zs9rXQQ9v3/wkHhq1MmkhvGaDyzBlhMlC2AYtYhDs561F0lTXtYDwGGTK?= =?us-ascii?Q?DoC80tcGU7mN4Tz0NoV4M1EszmdfsWw3SlCa077B5vrwN4IfMvNMm9zwpyKe?= =?us-ascii?Q?EepM6O33T+Z41PP69ZFv9Nl39JyMJZBS3WO3BuxZSQjOVcX0GZApXVbXISRa?= =?us-ascii?Q?6wVcGHXvii2thd52k1B3/XJKTCkOXYz08tT1xX0NEgfgJrK/STrf7yg1/51t?= =?us-ascii?Q?6cVRfzPcj074tcHNvtg5KZr+kjTZlN2mj1+8Ase7gcA54sZK8oWN43rZa4Ym?= =?us-ascii?Q?MNlyoX6IFSWbAVzhtUV+uMQ73k/b8JLw84F5f94UsFUqK9eSCZiVU87HMXcv?= =?us-ascii?Q?8OuB29mjsx871qFa3Ml3l4bEqLeORu0md7kg60+aTu9oDAzdp+mS8pmq5Jlq?= =?us-ascii?Q?39yIe10LovGy1MV6HdgQjT/xKDtVSIkC94iVTqCV88s=3D?= x-ms-exchange-transport-forked: True Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: VI1SPR01MB0363.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 1e819f32-4591-4292-17d9-08d8bca334b3 X-MS-Exchange-CrossTenant-originalarrivaltime: 19 Jan 2021 17:54:02.2378 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: U12fV6AGCiASdIkTaRBEHYUHS0Q/xIHKQ308bSFqETsfNu4bRhACdFwMaMhlaSvHLopnFTvYy38mX7PIN3PFiw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR04MB3054 Subject: Re: [dpdk-dev] [PATCH v2 10/10] compress/mlx5: add the supported capabilities 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" > Subject: [PATCH v2 10/10] compress/mlx5: add the supported capabilities >=20 > Add all the capabilities supported by the device. >=20 > Add the driver documentations. >=20 > Signed-off-by: Matan Azrad > --- > doc/guides/compressdevs/features/mlx5.ini | 13 +++++ > doc/guides/compressdevs/index.rst | 1 + > doc/guides/compressdevs/mlx5.rst | 84 > +++++++++++++++++++++++++++++++ > doc/guides/rel_notes/release_21_02.rst | 6 +++ > drivers/compress/mlx5/mlx5_compress.c | 24 ++++++++- > 5 files changed, 126 insertions(+), 2 deletions(-) > create mode 100644 doc/guides/compressdevs/features/mlx5.ini > create mode 100644 doc/guides/compressdevs/mlx5.rst >=20 > diff --git a/doc/guides/compressdevs/features/mlx5.ini > b/doc/guides/compressdevs/features/mlx5.ini > new file mode 100644 > index 0000000..891ce47 > --- /dev/null > +++ b/doc/guides/compressdevs/features/mlx5.ini > @@ -0,0 +1,13 @@ > +; > +; Refer to default.ini for the full list of available PMD features. > +; > +; Supported features of 'MLX5' compression driver. > +; > +[Features] > +HW Accelerated =3D Y > +Deflate =3D Y > +Adler32 =3D Y > +Crc32 =3D Y > +Adler32&Crc32 =3D Y > +Fixed =3D Y > +Dynamic =3D Y > diff --git a/doc/guides/compressdevs/index.rst > b/doc/guides/compressdevs/index.rst > index 1f37e26..8f9f3a5 100644 > --- a/doc/guides/compressdevs/index.rst > +++ b/doc/guides/compressdevs/index.rst > @@ -14,3 +14,4 @@ Compression Device Drivers > octeontx > qat_comp > zlib > + mlx5 Maintain alphabetical order. Also fix compilation issues reported by CI http://mails.dpdk.org/archives/test-report/2021-January/173975.html There is no information about the installation and how to test this PMD in = the documentation. > diff --git a/doc/guides/compressdevs/mlx5.rst > b/doc/guides/compressdevs/mlx5.rst > new file mode 100644 > index 0000000..4ee26b0 > --- /dev/null > +++ b/doc/guides/compressdevs/mlx5.rst > @@ -0,0 +1,84 @@ > +.. SPDX-License-Identifier: BSD-3-Clause > + Copyright 2021 Mellanox Technologies, Ltd > + > +.. include:: > + > +MLX5 compress driver > +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > + > +The MLX5 compress driver library > +(**librte_compress_mlx5**) provides support for **Mellanox BlueField 2** > +families of 25/50/100/200 Gb/s adapters. > + > +Design > +------ > + > +This PMD is configuring the compress, decompress amd DMA engines. > + > +For security reasons and robustness, this driver only deals with virtual > +memory addresses. The way resources allocations are handled by the kerne= l, > +combined with hardware specifications that allow to handle virtual memor= y > +addresses directly, ensure that DPDK applications cannot access random > +physical memory (or memory that does not belong to the current process). > + > +The PMD uses libibverbs and libmlx5 to access the device firmware > +or directly the hardware components. > +There are different levels of objects and bypassing abilities > +to get the best performances: > + > +- Verbs is a complete high-level generic API. > +- Direct Verbs is a device-specific API. > +- DevX allows to access firmware objects. > + > +Enabling librte_compress_mlx5 causes DPDK applications to be linked agai= nst > +libibverbs. > + > +Mellanox mlx5 pci device can be probed by number of different pci device= s, > +for example net / vDPA / compress. To select the compress PMD > ``class=3Dcompress`` > +should be specified as device parameter. The compress device can be prob= ed > and > +used with other Mellanox classes, by adding more options in the class. > +For example: ``class=3Dnet:compress`` will probe both the net PMD and th= e > compress > +PMD. > + > +Features > +-------- > + > +Compress mlx5 PMD has support for: > + > +Compression/Decompression algorithm: > + > +* DEFLATE. > + > +NULL algorithm for DMA operations. > + > +Huffman code type: > + > +* FIXED. > +* DYNAMIC. > + > +Window size support: > + > +1KB, 2KB, 4KB, 8KB, 16KB and 32KB. > + > +Sharable transformation. > + > +Checksum generation: > + > +* CRC32, Adler32 and combined checksum. > + > +Limitations > +----------- > + > +* Scatter-Gather, SHA and Stateful are not supported. > +* Non-compressed block is not supported in compress (supported in > decompress). > + > +Supported NICs > +-------------- > + > +* Mellanox\ |reg| BlueField 2 SmartNIC > + > +Prerequisites > +------------- > + > +- Mellanox OFED version: **5.2** > + see :doc:`../../nics/mlx5` guide for more Mellanox OFED details. > \ No newline at end of file > diff --git a/doc/guides/rel_notes/release_21_02.rst > b/doc/guides/rel_notes/release_21_02.rst > index 706cbf8..f672d7f 100644 > --- a/doc/guides/rel_notes/release_21_02.rst > +++ b/doc/guides/rel_notes/release_21_02.rst > @@ -51,6 +51,12 @@ New Features > * Other libs > * Apps, Examples, Tools (if significant) >=20 > +* **Added mlx5 compress PMD.** > + > + Added a new compress PMD driver for Bluefield 2 adapters. > + > + See the :doc:`../compressdevs/mlx5` for more details. > + > This section is a comment. Do not overwrite or remove it. > Also, make sure to start the actual text at the margin. > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D > diff --git a/drivers/compress/mlx5/mlx5_compress.c > b/drivers/compress/mlx5/mlx5_compress.c > index d768453..7384351 100644 > --- a/drivers/compress/mlx5/mlx5_compress.c > +++ b/drivers/compress/mlx5/mlx5_compress.c > @@ -74,8 +74,28 @@ struct mlx5_compress_qp { >=20 > int mlx5_compress_logtype; >=20 > -const struct rte_compressdev_capabilities > mlx5_caps[RTE_COMP_ALGO_LIST_END]; > - > +static const struct rte_compressdev_capabilities mlx5_caps[] =3D { > + { > + .algo =3D RTE_COMP_ALGO_NULL, > + .comp_feature_flags =3D RTE_COMP_FF_ADLER32_CHECKSUM | > + RTE_COMP_FF_CRC32_CHECKSUM | > + > RTE_COMP_FF_CRC32_ADLER32_CHECKSUM | > + RTE_COMP_FF_SHAREABLE_PRIV_XFORM, > + }, > + { > + .algo =3D RTE_COMP_ALGO_DEFLATE, > + .comp_feature_flags =3D RTE_COMP_FF_ADLER32_CHECKSUM | > + RTE_COMP_FF_CRC32_CHECKSUM | > + > RTE_COMP_FF_CRC32_ADLER32_CHECKSUM | > + RTE_COMP_FF_SHAREABLE_PRIV_XFORM | > + RTE_COMP_FF_HUFFMAN_FIXED | > + RTE_COMP_FF_HUFFMAN_DYNAMIC, > + .window_size =3D {.min =3D 10, .max =3D 15, .increment =3D 1}, > + }, > + { > + .algo =3D RTE_COMP_ALGO_LIST_END, > + } > +}; >=20 > static void > mlx5_compress_dev_info_get(struct rte_compressdev *dev, > -- > 1.8.3.1