Commit 5d07fdaf authored by Jaroslava Fiedlerova's avatar Jaroslava Fiedlerova Committed by Laurent THOMAS

Enable T1 interoprability

parent bf68a6cf
...@@ -487,19 +487,27 @@ target_link_libraries(shlib_loader PRIVATE CONFIG_LIB) ...@@ -487,19 +487,27 @@ target_link_libraries(shlib_loader PRIVATE CONFIG_LIB)
########################################################## ##########################################################
add_boolean_option(ENABLE_LDPC_OFFLOAD OFF "Build support for LDPC Offload to T1 library" OFF) add_boolean_option(ENABLE_LDPC_OFFLOAD OFF "Build support for LDPC Offload to T1 library" OFF)
set(ENV{PKG_CONFIG_PATH} "$ENV{PKG_CONFIG_PATH}:/home/eurecom/dpdk2011/libs/pkgconfig")
if (ENABLE_LDPC_OFFLOAD) if (ENABLE_LDPC_OFFLOAD)
pkg_check_modules(LIBDPDK_OFFLOAD REQUIRED libdpdk=20.11.3) pkg_check_modules(LIBDPDK_OFFLOAD REQUIRED libdpdk=20.05.0)
find_library(PMD NAMES rte_baseband_accl_ldpc HINTS "/home/eurecom/dpdk2011/libs") find_library(T1 NAMES rte_pmd_hpac_sdfec_pmd REQUIRED)
add_library(ldpc_offload MODULE ${OPENAIR1_DIR}/PHY/CODING/nrLDPC_decoder/nrLDPC_decoder_offload.c) add_library(ldpc_offload MODULE ${OPENAIR1_DIR}/PHY/CODING/nrLDPC_decoder/nrLDPC_decoder_offload.c)
set_target_properties(ldpc_offload PROPERTIES COMPILE_FLAGS "-DALLOW_EXPERIMENTAL_API") set_target_properties(ldpc_offload PROPERTIES COMPILE_FLAGS "-DALLOW_EXPERIMENTAL_API")
target_link_libraries(ldpc_offload ${LIBDPDK_OFFLOAD_LDFLAGS} ${OFFLOAD}) target_link_libraries(ldpc_offload ${LIBDPDK_OFFLOAD_LDFLAGS} ${T1})
#target_link_libraries(ldpc_offload /home/eurecom/jaroslava/T2_new/dpdk-stable/build/lib/librte_eal.so /home/eurecom/jaroslava/T2_new/dpdk-stable/build/lib/librte_mempool.so /home/eurecom/jaroslava/T2_new/dpdk-stable/build/lib/librte_bbdev.so /home/eurecom/jaroslava/T2_new/dpdk-stable/build/lib/librte_pdump.so)
#target_compile_options(ldpc_offload PRIVATE ${LIBDPDK_OFFLOAD_CFLAGS})
#target_link_libraries(ldpc_offload ${LIBDPDK_OFFLOAD_LDFLAGS} ${OFFLOAD})
endif() endif()
#add_boolean_option(ENABLE_LDPC_OFFLOAD OFF "Build support for LDPC Offload to T2 library" OFF)
#set(ENV{PKG_CONFIG_PATH} "$ENV{PKG_CONFIG_PATH}:/home/eurecom/dpdk2011/libs/pkgconfig")
#if (ENABLE_LDPC_OFFLOAD)
# pkg_check_modules(LIBDPDK_OFFLOAD REQUIRED libdpdk=20.11.3)
# find_library(PMD NAMES rte_baseband_accl_ldpc HINTS "/home/eurecom/dpdk2011/libs")
# add_library(ldpc_offload MODULE ${OPENAIR1_DIR}/PHY/CODING/nrLDPC_decoder/nrLDPC_decoder_offload.c)
# set_target_properties(ldpc_offload PROPERTIES COMPILE_FLAGS "-DALLOW_EXPERIMENTAL_API")
# target_link_libraries(ldpc_offload ${LIBDPDK_OFFLOAD_LDFLAGS} ${OFFLOAD})
# #target_link_libraries(ldpc_offload /home/eurecom/jaroslava/T2_new/dpdk-stable/build/lib/librte_eal.so /home/eurecom/jaroslava/T2_new/dpdk-stable/build/lib/librte_mempool.so /home/eurecom/jaroslava/T2_new/dpdk-stable/build/lib/librte_bbdev.so /home/eurecom/jaroslava/T2_new/dpdk-stable/build/lib/librte_pdump.so)
# #target_compile_options(ldpc_offload PRIVATE ${LIBDPDK_OFFLOAD_CFLAGS})
# #target_link_libraries(ldpc_offload ${LIBDPDK_OFFLOAD_LDFLAGS} ${OFFLOAD})
#endif()
########################################################## ##########################################################
include_directories ("${OPENAIR_DIR}/radio/COMMON") include_directories ("${OPENAIR_DIR}/radio/COMMON")
......
...@@ -393,7 +393,7 @@ static int add_dev(uint8_t dev_id, struct rte_bbdev_info *info) ...@@ -393,7 +393,7 @@ static int add_dev(uint8_t dev_id, struct rte_bbdev_info *info)
if (ret == 0) { if (ret == 0) {
printf("Found LDCP decoding queue (id=%u) at prio%u on dev%u\n", queue_id, qconf.priority, dev_id); printf("Found LDCP decoding queue (id=%u) at prio%u on dev%u\n", queue_id, qconf.priority, dev_id);
qconf.priority++; qconf.priority++;
ret = rte_bbdev_queue_configure(ad->dev_id, queue_id, &qconf); //ret = rte_bbdev_queue_configure(ad->dev_id, queue_id, &qconf);
ad->enc_queue = queue_id; ad->enc_queue = queue_id;
ad->queue_ids[queue_id] = queue_id; ad->queue_ids[queue_id] = queue_id;
break; break;
...@@ -408,7 +408,7 @@ static int add_dev(uint8_t dev_id, struct rte_bbdev_info *info) ...@@ -408,7 +408,7 @@ static int add_dev(uint8_t dev_id, struct rte_bbdev_info *info)
if (ret == 0) { if (ret == 0) {
printf("Found LDCP encoding queue (id=%u) at prio%u on dev%u\n", queue_id, qconf.priority, dev_id); printf("Found LDCP encoding queue (id=%u) at prio%u on dev%u\n", queue_id, qconf.priority, dev_id);
qconf.priority++; qconf.priority++;
ret = rte_bbdev_queue_configure(ad->dev_id, queue_id, &qconf); //ret = rte_bbdev_queue_configure(ad->dev_id, queue_id, &qconf);
ad->dec_queue = queue_id; ad->dec_queue = queue_id;
ad->queue_ids[queue_id] = queue_id; ad->queue_ids[queue_id] = queue_id;
break; break;
...@@ -1120,7 +1120,7 @@ int start_pmd_dec(struct active_device *ad, ...@@ -1120,7 +1120,7 @@ int start_pmd_dec(struct active_device *ad,
t_params[0].ulsch_id = ulsch_id; t_params[0].ulsch_id = ulsch_id;
// For now, we never enter here, we don't use the DPDK thread pool // For now, we never enter here, we don't use the DPDK thread pool
RTE_LCORE_FOREACH_WORKER(lcore_id) RTE_LCORE_FOREACH_SLAVE(lcore_id)
{ {
if (used_cores >= num_lcores) if (used_cores >= num_lcores)
break; break;
...@@ -1217,7 +1217,7 @@ int32_t start_pmd_enc(struct active_device *ad, ...@@ -1217,7 +1217,7 @@ int32_t start_pmd_enc(struct active_device *ad,
t_params[0].p_offloadParams = p_offloadParams; t_params[0].p_offloadParams = p_offloadParams;
// For now, we never enter here, we don't use the DPDK thread pool // For now, we never enter here, we don't use the DPDK thread pool
RTE_LCORE_FOREACH_WORKER(lcore_id) RTE_LCORE_FOREACH_SLAVE(lcore_id)
{ {
if (used_cores >= num_lcores) if (used_cores >= num_lcores)
break; break;
......
...@@ -89,6 +89,7 @@ typedef struct nrLDPC_dec_params { ...@@ -89,6 +89,7 @@ typedef struct nrLDPC_dec_params {
uint8_t Qm; /**< Modulation */ uint8_t Qm; /**< Modulation */
uint8_t rv; uint8_t rv;
uint8_t numMaxIter; /**< Maximum number of iterations */ uint8_t numMaxIter; /**< Maximum number of iterations */
int block_length;
int E; int E;
e_nrLDPC_outMode outMode; /**< Output format */ e_nrLDPC_outMode outMode; /**< Output format */
int crc_type; int crc_type;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment