bb/turbo_sw: add software turbo driver
- bbdev 'turbo_sw' is the software accelerated version of 3GPP L1 Turbo coding operation using the optimized Intel FlexRAN SDK libraries. - 'turbo_sw' pmd is disabled by default Signed-off-by: Amr Mokhtar <amr.mokhtar@intel.com> Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
This commit is contained in:
parent
7dc2b15894
commit
b8cfe2c9ae
@ -457,6 +457,11 @@ CONFIG_RTE_BBDEV_MAX_DEVS=128
|
||||
#
|
||||
CONFIG_RTE_LIBRTE_PMD_BBDEV_NULL=y
|
||||
|
||||
#
|
||||
# Compile PMD for turbo software bbdev device
|
||||
#
|
||||
CONFIG_RTE_LIBRTE_PMD_BBDEV_TURBO_SW=n
|
||||
|
||||
#
|
||||
# Compile generic crypto device library
|
||||
#
|
||||
|
@ -47,6 +47,7 @@ default_path=$PATH
|
||||
# - DPDK_DEP_ZLIB (y/[n])
|
||||
# - DPDK_MAKE_JOBS (int)
|
||||
# - DPDK_NOTIFY (notify-send)
|
||||
# - FLEXRAN_SDK
|
||||
# - LIBMUSDK_PATH
|
||||
# - LIBSSO_SNOW3G_PATH
|
||||
# - LIBSSO_KASUMI_PATH
|
||||
@ -130,6 +131,7 @@ reset_env ()
|
||||
unset DPDK_DEP_ZLIB
|
||||
unset AESNI_MULTI_BUFFER_LIB_PATH
|
||||
unset ARMV8_CRYPTO_LIB_PATH
|
||||
unset FLEXRAN_SDK
|
||||
unset LIBMUSDK_PATH
|
||||
unset LIBSSO_SNOW3G_PATH
|
||||
unset LIBSSO_KASUMI_PATH
|
||||
@ -194,6 +196,8 @@ config () # <directory> <target> <options>
|
||||
sed -ri 's,(PMD_OPENSSL=)n,\1y,' $1/.config
|
||||
test "$DPDK_DEP_SSL" != y || \
|
||||
sed -ri 's,(PMD_QAT=)n,\1y,' $1/.config
|
||||
test -z "$FLEXRAN_SDK" || \
|
||||
sed -ri 's,(BBDEV_TURBO_SW=)n,\1y,' $1/.config
|
||||
sed -ri 's,(SCHED_.*=)n,\1y,' $1/.config
|
||||
test -z "$LIBMUSDK_PATH" || \
|
||||
sed -ri 's,(PMD_MRVL_CRYPTO=)n,\1y,' $1/.config
|
||||
|
@ -9,3 +9,4 @@ Baseband Device Drivers
|
||||
:numbered:
|
||||
|
||||
null
|
||||
turbo_sw
|
||||
|
147
doc/guides/bbdevs/turbo_sw.rst
Normal file
147
doc/guides/bbdevs/turbo_sw.rst
Normal file
@ -0,0 +1,147 @@
|
||||
.. SPDX-License-Identifier: BSD-3-Clause
|
||||
Copyright(c) 2017 Intel Corporation
|
||||
|
||||
SW Turbo Poll Mode Driver
|
||||
=========================
|
||||
|
||||
The SW Turbo PMD (**turbo_sw**) provides a poll mode bbdev driver that utilizes
|
||||
Intel optimized libraries for LTE Layer 1 workloads acceleration. This PMD
|
||||
supports the functions: Turbo FEC, Rate Matching and CRC functions.
|
||||
|
||||
Features
|
||||
--------
|
||||
|
||||
SW Turbo PMD has support for the following capabilities:
|
||||
|
||||
For the encode operation:
|
||||
|
||||
* ``RTE_BBDEV_TURBO_CRC_24A_ATTACH``
|
||||
* ``RTE_BBDEV_TURBO_CRC_24B_ATTACH``
|
||||
* ``RTE_BBDEV_TURBO_RATE_MATCH``
|
||||
* ``RTE_BBDEV_TURBO_RV_INDEX_BYPASS``
|
||||
|
||||
For the decode operation:
|
||||
|
||||
* ``RTE_BBDEV_TURBO_SUBBLOCK_DEINTERLEAVE``
|
||||
* ``RTE_BBDEV_TURBO_CRC_TYPE_24B``
|
||||
* ``RTE_BBDEV_TURBO_POS_LLR_1_BIT_IN``
|
||||
* ``RTE_BBDEV_TURBO_NEG_LLR_1_BIT_IN``
|
||||
|
||||
|
||||
Limitations
|
||||
-----------
|
||||
|
||||
* In-place operations for Turbo encode and decode are not supported
|
||||
|
||||
Installation
|
||||
------------
|
||||
|
||||
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
|
||||
`<https://www.intel.com/content/www/us/en/design/resource-design-center.html>`_.
|
||||
|
||||
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 `<https://cdrd.intel.com/v1/dl/getContent/575367>`_.
|
||||
|
||||
After download is complete, the user needs to unpack and compile on their
|
||||
system before building DPDK.
|
||||
|
||||
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
|
||||
|
||||
The following instructions should be followed in this exact order:
|
||||
|
||||
#. Set the environment variables:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
source <path-to-icc-compiler-install-folder>/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:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
cd <path-to-workspace>/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
|
||||
``<path-to-workspace>/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;
|
||||
|
||||
#. Generate makefiles based on system configuration:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
cd <path-to-workspace>/FlexRAN-1.3.0/SDK-R1.3.0/sdk/
|
||||
./create-makefiles-linux.sh
|
||||
|
||||
#. A build folder is generated in this form ``build-<ISA>-<CC>``, enter that
|
||||
folder and install:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
cd build-avx2-icc/
|
||||
make install
|
||||
|
||||
|
||||
Initialization
|
||||
--------------
|
||||
|
||||
In order to enable this virtual bbdev PMD, the user must:
|
||||
|
||||
* Build the ``FLEXRAN SDK`` libraries (explained in Installation section).
|
||||
|
||||
* Export the environmental variables ``FLEXRAN_SDK`` to the path where the
|
||||
FlexRAN SDK libraries were installed. And ``DIR_WIRELESS_SDK`` to the path
|
||||
where the libraries were extracted.
|
||||
|
||||
Example:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
export FLEXRAN_SDK=<path-to-workspace>/FlexRAN-1.3.0/SDK-R1.3.0/sdk/build-avx2-icc/install
|
||||
export DIR_WIRELESS_SDK=<path-to-workspace>/FlexRAN-1.3.0/SDK-R1.3.0/sdk/
|
||||
|
||||
|
||||
* Set ``CONFIG_RTE_LIBRTE_PMD_BBDEV_TURBO_SW=y`` in DPDK common configuration
|
||||
file ``config/common_base``.
|
||||
|
||||
To use the PMD in an application, user must:
|
||||
|
||||
- Call ``rte_vdev_init("turbo_sw")`` within the application.
|
||||
|
||||
- Use ``--vdev="turbo_sw"`` in the EAL options, which will call ``rte_vdev_init()`` internally.
|
||||
|
||||
The following parameters (all optional) can be provided in the previous two calls:
|
||||
|
||||
* ``socket_id``: Specify the socket where the memory for the device is going to be allocated
|
||||
(by default, *socket_id* will be the socket where the core that is creating the PMD is running on).
|
||||
|
||||
* ``max_nb_queues``: Specify the maximum number of queues in the device (default is ``RTE_MAX_LCORE``).
|
||||
|
||||
Example:
|
||||
~~~~~~~~
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
./test-bbdev.py -e="--vdev=turbo_sw,socket_id=0,max_nb_queues=8" \
|
||||
-c validation -v ./test_vectors/bbdev_vector_t?_default.data
|
@ -8,5 +8,7 @@ core-libs += librte_bbdev librte_kvargs librte_cfgfile
|
||||
|
||||
DIRS-$(CONFIG_RTE_LIBRTE_PMD_BBDEV_NULL) += null
|
||||
DEPDIRS-null = $(core-libs)
|
||||
DIRS-$(CONFIG_RTE_LIBRTE_PMD_BBDEV_TURBO_SW) += turbo_sw
|
||||
DEPDIRS-turbo_sw = $(core-libs)
|
||||
|
||||
include $(RTE_SDK)/mk/rte.subdir.mk
|
||||
|
41
drivers/bbdev/turbo_sw/Makefile
Normal file
41
drivers/bbdev/turbo_sw/Makefile
Normal file
@ -0,0 +1,41 @@
|
||||
# SPDX-License-Identifier: BSD-3-Clause
|
||||
# Copyright(c) 2017 Intel Corporation
|
||||
|
||||
include $(RTE_SDK)/mk/rte.vars.mk
|
||||
|
||||
ifeq ($(FLEXRAN_SDK),)
|
||||
$(error "Please define FLEXRAN_SDK environment variable")
|
||||
endif
|
||||
|
||||
# library name
|
||||
LIB = librte_pmd_bbdev_turbo_sw.a
|
||||
|
||||
# build flags
|
||||
CFLAGS += -O3
|
||||
CFLAGS += $(WERROR_FLAGS)
|
||||
LDLIBS += -lrte_eal -lrte_mbuf -lrte_mempool -lrte_ring -lrte_kvargs
|
||||
LDLIBS += -lrte_bbdev
|
||||
LDLIBS += -lrte_bus_vdev
|
||||
|
||||
# versioning export map
|
||||
EXPORT_MAP := rte_pmd_bbdev_turbo_sw_version.map
|
||||
|
||||
# external library dependencies
|
||||
CFLAGS += -I$(FLEXRAN_SDK)/lib_common
|
||||
CFLAGS += -I$(FLEXRAN_SDK)/lib_turbo
|
||||
CFLAGS += -I$(FLEXRAN_SDK)/lib_crc
|
||||
CFLAGS += -I$(FLEXRAN_SDK)/lib_rate_matching
|
||||
|
||||
LDLIBS += -L$(FLEXRAN_SDK)/lib_crc -lcrc
|
||||
LDLIBS += -L$(FLEXRAN_SDK)/lib_turbo -lturbo
|
||||
LDLIBS += -L$(FLEXRAN_SDK)/lib_rate_matching -lrate_matching
|
||||
LDLIBS += -L$(FLEXRAN_SDK)/lib_common -lcommon
|
||||
LDLIBS += -lstdc++ -lirc -limf -lipps
|
||||
|
||||
# library version
|
||||
LIBABIVER := 1
|
||||
|
||||
# library source files
|
||||
SRCS-$(CONFIG_RTE_LIBRTE_PMD_BBDEV_TURBO_SW) += bbdev_turbo_software.c
|
||||
|
||||
include $(RTE_SDK)/mk/rte.lib.mk
|
1206
drivers/bbdev/turbo_sw/bbdev_turbo_software.c
Normal file
1206
drivers/bbdev/turbo_sw/bbdev_turbo_software.c
Normal file
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,3 @@
|
||||
DPDK_18.02 {
|
||||
local: *;
|
||||
};
|
@ -166,6 +166,14 @@ _LDLIBS-$(CONFIG_RTE_LIBRTE_VMXNET3_PMD) += -lrte_pmd_vmxnet3_uio
|
||||
|
||||
ifeq ($(CONFIG_RTE_LIBRTE_BBDEV),y)
|
||||
_LDLIBS-$(CONFIG_RTE_LIBRTE_PMD_BBDEV_NULL) += -lrte_pmd_bbdev_null
|
||||
|
||||
# TURBO SOFTWARE PMD is dependent on the FLEXRAN library
|
||||
_LDLIBS-$(CONFIG_RTE_LIBRTE_PMD_BBDEV_TURBO_SW) += -lrte_pmd_bbdev_turbo_sw
|
||||
_LDLIBS-$(CONFIG_RTE_LIBRTE_PMD_BBDEV_TURBO_SW) += -L$(FLEXRAN_SDK)/lib_crc -lcrc
|
||||
_LDLIBS-$(CONFIG_RTE_LIBRTE_PMD_BBDEV_TURBO_SW) += -L$(FLEXRAN_SDK)/lib_turbo -lturbo
|
||||
_LDLIBS-$(CONFIG_RTE_LIBRTE_PMD_BBDEV_TURBO_SW) += -L$(FLEXRAN_SDK)/lib_rate_matching -lrate_matching
|
||||
_LDLIBS-$(CONFIG_RTE_LIBRTE_PMD_BBDEV_TURBO_SW) += -L$(FLEXRAN_SDK)/lib_common -lcommon
|
||||
_LDLIBS-$(CONFIG_RTE_LIBRTE_PMD_BBDEV_TURBO_SW) += -lirc -limf -lstdc++ -lipps
|
||||
endif # CONFIG_RTE_LIBRTE_BBDEV
|
||||
|
||||
ifeq ($(CONFIG_RTE_LIBRTE_CRYPTODEV),y)
|
||||
|
Loading…
Reference in New Issue
Block a user