* INTC Contribution to the O-RAN F Release for O-DU Low
[o-du/phy.git] / fhi_lib / lib / api / xran_fh_o_ru.h
1 /******************************************************************************
2 *
3 *   Copyright (c) 2020 Intel.
4 *
5 *   Licensed under the Apache License, Version 2.0 (the "License");
6 *   you may not use this file except in compliance with the License.
7 *   You may obtain a copy of the License at
8 *
9 *       http://www.apache.org/licenses/LICENSE-2.0
10 *
11 *   Unless required by applicable law or agreed to in writing, software
12 *   distributed under the License is distributed on an "AS IS" BASIS,
13 *   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 *   See the License for the specific language governing permissions and
15 *   limitations under the License.
16 *
17 *******************************************************************************/
18
19 /**
20  * @brief This file provides public interface to xRAN Front Haul layer implementation as defined in the
21  *      ORAN-WG4.CUS.0-v01.00 spec. Implementation specific to
22  *      (O-DU): a logical node that includes the eNB/gNB functions as
23  *      listed in section 2.1 split option 7-2x.
24  *  
25  *
26  * @file xran_fh_o_ru.h
27  * @ingroup group_lte_source_xran
28  * @author Intel Corporation
29  *
30  **/
31
32 #ifdef __cplusplus
33 extern "C" {
34 #endif
35
36 #include <stdio.h>
37 #include <stdlib.h>
38 #include <string.h>
39 #include <stdint.h>
40 #include <inttypes.h>
41 #include <sys/types.h>
42 #include <sys/queue.h>
43 #include <netinet/in.h>
44 #include <setjmp.h>
45 #include <stdarg.h>
46 #include <ctype.h>
47 #include <errno.h>
48 #include <getopt.h>
49 #include <unistd.h>
50 #include "xran_fh_o_du.h"
51
52 /**
53  * @ingroup
54  *
55  *   Function configures TX and RX output buffers
56  *
57  * @param pHandle
58  *   Pointer to XRAN layer handle for given CC
59  * @param pSrcRxCpBuffer
60  *   list of memory buffers to use to deliver BFWs from XRAN layer to the application for Validation
61  * @param pSrcTxCpBuffer
62  *   list of memory buffers to use to deliver BFWs from XRAN layer to the application for Validation
63  * @param xran_transport_callback_fn pCallback
64  *   Callback function to call with arrival of C-Plane packets for given CC
65  * @param pCallbackTag
66  *   Parameters of Callback function
67  * 
68  * @return
69  *   0  - on success
70  *   -1 - on error
71  */
72
73 int32_t xran_5g_bfw_config(void * pHandle, struct xran_buffer_list *pSrcRxCpBuffer[XRAN_MAX_ANTENNA_NR][XRAN_N_FE_BUF_LEN],
74                     struct xran_buffer_list *pSrcTxCpBuffer[XRAN_MAX_ANTENNA_NR][XRAN_N_FE_BUF_LEN],
75                     xran_transport_callback_fn pCallback,
76                     void *pCallbackTag);
77
78
79 #ifdef __cplusplus
80 }
81 #endif