From patchwork Wed May 9 14:14:29 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kamil Chalupnik X-Patchwork-Id: 39602 X-Patchwork-Delegate: pablo.de.lara.guarch@intel.com Return-Path: X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 198141B681; Wed, 9 May 2018 16:14:39 +0200 (CEST) Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by dpdk.org (Postfix) with ESMTP id 13B711B67E for ; Wed, 9 May 2018 16:14:37 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by orsmga105.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 09 May 2018 07:14:36 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.49,381,1520924400"; d="scan'208";a="53724991" Received: from kchalupx-mobl.ger.corp.intel.com ([10.103.104.151]) by fmsmga001.fm.intel.com with ESMTP; 09 May 2018 07:14:35 -0700 From: Kamil Chalupnik To: dev@dpdk.org Cc: amr.mokhtar@intel.com, KamilX Chalupnik Date: Wed, 9 May 2018 16:14:29 +0200 Message-Id: <20180509141430.24072-1-kamilx.chalupnik@intel.com> X-Mailer: git-send-email 2.9.0.windows.1 In-Reply-To: <20180426133008.12388-1-kamilx.chalupnik@intel.com> References: <20180426133008.12388-1-kamilx.chalupnik@intel.com> Subject: [dpdk-dev] [PATCH v2 01/14] baseband/turbo_sw: update DPDK to work with FlexRAN 1.4.0 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" From: KamilX Chalupnik Adjusting BaseBand drivers code to changes in FlexRAN 1.4.0: - update usage of crc functions after API changes Update the documentation describing Wireless Baseband Device: - FlexRAN releases mapping table added - download and build instructions for BBDEV turbo_sw driver in compliance with FlexRAN 1.4.0 release added Signed-off-by: Kamil Chalupnik Acked-by: Amr Mokhtar --- doc/guides/bbdevs/turbo_sw.rst | 50 ++++++++++++------------ drivers/baseband/turbo_sw/bbdev_turbo_software.c | 21 +++++----- 2 files changed, 35 insertions(+), 36 deletions(-) diff --git a/doc/guides/bbdevs/turbo_sw.rst b/doc/guides/bbdevs/turbo_sw.rst index b3fed16..996b2a2 100644 --- a/doc/guides/bbdevs/turbo_sw.rst +++ b/doc/guides/bbdevs/turbo_sw.rst @@ -40,24 +40,37 @@ FlexRAN SDK Download ~~~~~~~~~~~~~~~~~~~~ To build DPDK with the *turbo_sw* PMD the user is required to download -the export controlled ``FlexRAN SDK`` Libraries. An account at Intel Resource -Design Center needs to be registered from -``_. +the export controlled ``FlexRAN SDK`` Libraries. An account at `Intel Resource +Design Center `_ +needs to be registered. Once registered, the user needs to log in, and look for -*Intel SWA_SW_FlexRAN_Release_Package R1_3_0* and click for download. Or use -this direct download link ``_. +*Intel FlexRAN Software Release Package 1_4_0* to download or directly through +this `link `_. After download is complete, the user needs to unpack and compile on their system before building DPDK. +The following table maps DPDK versions with past FlexRAN SDK releases: + +.. _table_flexran_releases: + +.. table:: DPDK and FlexRAN SDK releases compliance + + ===================== ============================ + DPDK version FlexRAN SDK release + ===================== ============================ + 18.02 1.3.0 + 18.05 1.4.0 + ===================== ============================ + FlexRAN SDK Installation ~~~~~~~~~~~~~~~~~~~~~~~~ The following are pre-requisites for building FlexRAN SDK Libraries: (a) An AVX2 supporting machine (b) Windriver TS 2 or CentOS 7 operating systems - (c) Intel ICC compiler installed + (c) Intel ICC 17.0.3 compiler installed The following instructions should be followed in this exact order: @@ -68,30 +81,19 @@ The following instructions should be followed in this exact order: source /linux/bin/compilervars.sh intel64 -platform linux -#. Extract the ``FlexRAN-1.3.0.tar.gz.zip`` package, then run the SDK extractor - script and accept the license: +#. Extract the ``576288-576288-intel-swa-sw-flexran-release-package-r1-4-0.zip`` + package, then run the SDK extractor script and accept the license: .. code-block:: console - cd /FlexRAN-1.3.0/ - ./SDK-R1.3.0.sh - -#. To allow ``FlexRAN SDK R1.3.0`` to work with bbdev properly, the following - hotfix is required. Change the return of function ``rate_matching_turbo_lte_avx2()`` - located in file - ``/FlexRAN-1.3.0/SDK-R1.3.0/sdk/source/phy/lib_rate_matching/phy_rate_match_avx2.cpp`` - to return 0 instead of 1. - - .. code-block:: c - - - return 1; - + return 0; + cd /FlexRAN-1.4.0/ + ./SDK-R1.4.0.sh #. Generate makefiles based on system configuration: .. code-block:: console - cd /FlexRAN-1.3.0/SDK-R1.3.0/sdk/ + cd /FlexRAN-1.4.0/SDK-R1.4.0/sdk/ ./create-makefiles-linux.sh #. A build folder is generated in this form ``build--``, enter that @@ -118,8 +120,8 @@ Example: .. code-block:: console - export FLEXRAN_SDK=/FlexRAN-1.3.0/SDK-R1.3.0/sdk/build-avx2-icc/install - export DIR_WIRELESS_SDK=/FlexRAN-1.3.0/SDK-R1.3.0/sdk/ + export FLEXRAN_SDK=/FlexRAN-1.4.0/SDK-R1.4.0/sdk/build-avx2-icc/install + export DIR_WIRELESS_SDK=/FlexRAN-1.4.0/SDK-R1.4.0/sdk/ * Set ``CONFIG_RTE_LIBRTE_PMD_BBDEV_TURBO_SW=y`` in DPDK common configuration diff --git a/drivers/baseband/turbo_sw/bbdev_turbo_software.c b/drivers/baseband/turbo_sw/bbdev_turbo_software.c index 302abf5..26b8560 100644 --- a/drivers/baseband/turbo_sw/bbdev_turbo_software.c +++ b/drivers/baseband/turbo_sw/bbdev_turbo_software.c @@ -462,6 +462,7 @@ process_enc_cb(struct turbo_sw_queue *q, struct rte_bbdev_enc_op *op, uint8_t *in, *out0, *out1, *out2, *tmp_out, *rm_out; struct rte_bbdev_op_turbo_enc *enc = &op->turbo_enc; struct bblib_crc_request crc_req; + struct bblib_crc_response crc_resp; struct bblib_turbo_encoder_request turbo_req; struct bblib_turbo_encoder_response turbo_resp; struct bblib_rate_match_dl_request rm_req; @@ -482,13 +483,11 @@ process_enc_cb(struct turbo_sw_queue *q, struct rte_bbdev_enc_op *op, * it by 3 CRC bytes */ rte_memcpy(q->enc_in, in, (k - 24) >> 3); - crc_req.data = q->enc_in; + crc_req.data = in; crc_req.len = (k - 24) >> 3; - if (bblib_lte_crc24a_gen(&crc_req) == -1) { - op->status |= 1 << RTE_BBDEV_CRC_ERROR; - rte_bbdev_log(ERR, "CRC24a generation failed"); - return; - } + crc_resp.data = q->enc_in; + bblib_lte_crc24a_gen(&crc_req, &crc_resp); + in = q->enc_in; } else if (enc->op_flags & RTE_BBDEV_TURBO_CRC_24B_ATTACH) { /* CRC24B */ @@ -501,13 +500,11 @@ process_enc_cb(struct turbo_sw_queue *q, struct rte_bbdev_enc_op *op, * it by 3 CRC bytes */ rte_memcpy(q->enc_in, in, (k - 24) >> 3); - crc_req.data = q->enc_in; + crc_req.data = in; crc_req.len = (k - 24) >> 3; - if (bblib_lte_crc24b_gen(&crc_req) == -1) { - op->status |= 1 << RTE_BBDEV_CRC_ERROR; - rte_bbdev_log(ERR, "CRC24b generation failed"); - return; - } + crc_resp.data = q->enc_in; + bblib_lte_crc24b_gen(&crc_req, &crc_resp); + in = q->enc_in; } else { ret = is_enc_input_valid(k, k_idx, total_left);