Commit Graph
100 Commits
Author SHA1 Message Date
Robert Schmidt 896ea4a72a Fix: Check for node type in L2_interface only when not UE 2019-03-26 13:37:14 +01:00
Robert Schmidt 024007716a Check type of node using NODE_IS_CU/DU/MONOLITHIC macros 2019-03-26 13:15:02 +01:00
Robert Schmidt f0fced85f2 Execute pdcp_run from rrc_data_req only when in CU mode 2019-03-26 10:50:11 +01:00
Robert Schmidt dc9a68ff30 Correct condition to read MIB/SIB1 params only when not CU 2019-03-26 10:49:47 +01:00
Robert Schmidt cdc2d921c1 FlexRAN: fix total_size_ul_mac_sdus parameter 2019-03-24 16:45:32 +01:00
Robert Schmidt c1f142cc44 Fix warnings: space between literal and identifier in macro
This resolves the following warning:
"error: invalid suffix on literal; C++11 requires a space between literal and
identifier"
Since this file might be included from a C++11 file. It only adds spaces.
2019-03-23 17:32:28 +01:00
Robert Schmidt 4f6b1e46a5 Remove warnings for DU_send_INITIAL_UL_RRC_MESSAGE_TRANSFER() include 2019-03-23 17:10:43 +01:00
Robert Schmidt 10a5e5fd75 Use OAI NUM_ENB/UE defines for F1U (removes warnings) 2019-03-23 16:57:26 +01:00
Robert Schmidt 9611a22a65 Remove warnings in RRC 2019-03-23 16:40:47 +01:00
Robert Schmidt 7519b8e061 Free UE in RRC/S1/GTP if not DU 2019-03-23 16:20:43 +01:00
Robert Schmidt 9fd0f9f8bf Re-comment Assert for unconfigured RLC as in current develop 2019-03-19 15:48:00 +01:00
Robert Schmidt 1f590efe2b Merge branch 'develop' into feature-127-protocol-split 2019-03-19 14:49:07 +01:00
Robert Schmidt 13857c67e8 fix segfault RRU: check for nb_inst >0 before node_type 2019-03-14 14:24:16 +01:00
Robert Schmidt 62d9b8cf36 Merge branch 'develop' into feature-127-protocol-split 2019-03-14 13:10:21 +01:00
Robert Schmidt 7edf4387f9 Fix bug in eNB: correctly set brOption for RRC R14 2019-03-08 16:58:45 +01:00
Robert Schmidt 20c35748ca Fix lte-uesoftmodem: segfaults & logic errors
* prevent segfault: guard access to RC.rrc with UETARGET
* in rlc_data_ind(): correct logic to test for all cases eNB, CU, DU, UE
2019-03-08 16:52:34 +01:00
Robert Schmidt 05ebea4a24 Reduce PHY layer logging (as in current develop) 2019-03-08 16:51:57 +01:00
Robert Schmidt 02d99edf23 Fix cppcheck errors: RRC, F1AP 2019-03-07 14:16:16 +01:00
Robert Schmidt ede37e56b8 Use correct RNTI for RRC data req 2019-03-07 12:46:34 +01:00
Robert Schmidt bbedd315e7 Correctly link lte-uesoftmodem(-nos1) (hack)
Although not used in the UE, we currently need to link the F1 library into it.
This is because we do not define ASN_DISABLE_OER_SUPPORT (otherwise, F1 has
compilation problems). In this case, some functions are apparently not
correctly defined, giving linker errors in the UE. Linking F1 in solves the
problem.

This is a hack. It would be better to be able to define ASN_DISABLE_OER_SUPPORT
and have no compilation errors or compile everything with
ASN_DISABLE_OER_SUPPORT except F1. I did not do this because I did not find
another way than add target_compile_definitions() to every target except F1
which adds many lines just so that one target (F1 ASN.1) compiles correctly (in
other words, F1 needs to be fixed).
2019-03-06 19:28:12 +01:00
Robert Schmidt 275b559fbf Fix linker error: link F1-U protobuf for eNB noS1 case 2019-03-06 14:18:54 +01:00
Robert Schmidt 7a7c2afa11 Handle cppcheck errors in ASYNC_IF 2019-03-06 13:59:39 +01:00
Robert Schmidt 66d4c4e92d Fix cppcheck issues in PROTO_AGENT 2019-03-06 13:43:09 +01:00
Robert Schmidt 56af9c60e4 Fix compilation/linking errors in lte-uesoftmodem 2019-03-05 18:47:29 +01:00
Robert Schmidt e3bb3ab7d3 Change integer based conf parameter from string 2019-03-05 18:27:54 +01:00
Robert Schmidt f9c4c501e3 Merge branch 'develop' into feature-127-protocol-split 2019-03-05 14:17:38 +01:00
Robert Schmidt 1e3d0c9a16 Update F1 CU/DU configuration (tested, formatted) 2019-02-27 15:31:52 +01:00
Robert Schmidt 544d80c40d Merge branch 'develop' into feature-127-protocol-split 2019-02-25 18:06:35 +01:00
Robert Schmidt 97126eb57e Fix carrierFreq MeasObj calculation to handle F1 case 2019-02-25 16:33:02 +01:00
Robert Schmidt cc2a507d59 Unify and comment RRC container print of F1 2019-02-25 16:23:42 +01:00
Robert Schmidt 80b6245213 Remove comments left after merge 2019-02-22 18:38:34 +01:00
Robert Schmidt eab78405cc Log received F1 messages correctly 2019-02-22 18:33:12 +01:00
Robert Schmidt 549e72d001 Trigger UL RRC Message through ITTI Message 2019-02-22 16:36:26 +01:00
Robert Schmidt c75fd52e3a Remove many warnings 2019-02-22 15:22:13 +01:00
Robert Schmidt bd36a9ef0c Gracefully handle different numbers of UE in MAC and RRC 2019-02-22 15:22:09 +01:00
Robert Schmidt a4d909bca8 Initialize variables to prevent illegal free() 2019-02-22 10:51:40 +01:00
Robert Schmidt 1a07a1e067 Replace redundant CU_F1AP/DU_F1AP with F1AP 2019-02-22 10:26:41 +01:00
Robert Schmidt 030e11ba9a Merge branch 'develop' into feature-127-protocol-split 2019-02-21 20:18:35 +01:00
Robert Schmidt 2f23047900 Restructure F1AP UE list
* Restructure the code handling the UEs F1AP knows
* This fixes a bug that only two phones can be connected
2019-02-08 19:42:25 +01:00
Robert Schmidt 032fc48ac0 Remove unused, commented F1AP code 2019-02-08 18:01:56 +01:00
Robert Schmidt 36f192e873 Fix test of socket_link.c after interface change
link_send_packet() has been extended to use for multiple protocols (added UDP,
SCTP after TCP). The test was not update, though, which is fixed in this
commit.
2019-02-07 18:03:18 +01:00
Robert Schmidt 9fd4b45226 Remove F1-related flags from build_oai script 2019-02-07 18:03:17 +01:00
Robert Schmidt 822f9849a2 Stop CU's PROTO_AGENT when DU disconnects
This adds an exit flag as well as the proto_agent_async_msg_recv_unlock()
function to unlock and release the proto_agent worker thread correctly.
2019-02-07 18:00:20 +01:00
Robert Schmidt beec74b01a Correctly stop link_manager sender and receiver threads
This changes the destroy_link_manager() function to:
* call a new function message_get_unlock() to unlock the sending thread from
  its blocking message_get()
* calls pthread_cancel() on the receiving thread, because this unlocks any
  blocking read from a file descriptor

The same message_get_unlock() function has been added ringbuffer_queue to keep
the interfaces the same (it does nothing, because ringbuffer_queue is
non-blocking).
2019-02-07 17:56:56 +01:00
Robert Schmidt 0643d6b561 Make queue_recv() functions return size, not as out-param 2019-01-29 16:55:15 +01:00
Robert Schmidt 63c4a90eb7 Remove unused PROTO_AGENT code 2019-01-29 16:55:15 +01:00
Robert Schmidt 8c0ebfadda Add FlexRAN PLMN ID list and remove defunct cell_id 2019-01-28 08:36:32 +01:00
Robert Schmidt d9d6ce374f Perform S1 UE Context Release Complete after corresponding F1 message
This commits isolates the S1 UE Ctxt Rel Complete and GTP Tunnel Delete
Requests in functions and calls these function in the original place
(rrc_rx_tx()). The same functions are then used in the F1 UE Ctxt Rel
Complete handler to perform the same functionality, i.e. forward the UE
Ctxt Rel Complete message to the MME and free outstanding resources (RRC
context, GTP tunnels, S1 context).
2019-01-25 16:37:57 +01:00
Robert Schmidt 2cdcb6466b Move PDCP stats recording out from non-applying packet_forwarded FALSE case 2019-01-22 16:11:37 +01:00
Robert Schmidt 03b52216a0 FlexRAN: Access PDCP stats through RNTI 2019-01-19 18:22:43 +01:00
Robert Schmidt 767eaf5ba2 Initialize PDCP stats when UE is added 2019-01-19 18:22:40 +01:00
Robert Schmidt 6f9f2d8992 Correct PDCP stats defining constant to MAX_eNB from CC 2019-01-19 16:59:33 +01:00
Robert Schmidt ad9778be76 FlexRAN fix: correct array index var in loop 2019-01-19 16:13:38 +01:00
Robert Schmidt ca2f91072a F1AP: on UEContextRelCmd, DU distinguishes whether UE is out of sync 2019-01-18 16:44:00 +01:00
Robert Schmidt 7df8257526 F1AP: when UL_sync failure, send UEContextRelReq
When a phone loses connection, it should not simply be removed but first
CU should be informed which will send a ContextRelCmd. Correspondingly,
when the RRC releases the UE, it does not send a UE Context Release Req
2019-01-18 16:44:01 +01:00
Robert Schmidt 0699e539fe Put RRC S1AP UEContextReleaseReq message inside corresponding if 2019-01-17 18:21:47 +01:00
Robert Schmidt a26fad9e47 F1AP: Correct UEContextReleaseReq path, send corresp. S1AP message 2019-01-16 14:45:06 +01:00
Robert Schmidt 05e08d5094 Remove DU's UE RRC, MAC, RLC contexts correctly on UE RELEASE COMMAND 2019-01-10 16:51:04 +01:00
Robert Schmidt be17b9b655 Correctly handle UE RELEASE COMPLETE in CU
* remove PDCP/RRC contexts
* inform the FlexRAN controller
2019-01-10 16:50:17 +01:00
Robert Schmidt 29f23e161e Fix socket type to IPv4 in case of no-multi usage
sctp_create_new_listener() takes a parameter server_type which is NOT
the IP version but whether it is an SCTP multihoming server. There was a
bug that when multihoming is not wanted, it created an IPv6 socket
instead of IPv4. This commit fixes this.

IPv6 is not supported yet.
2019-01-10 14:28:25 +01:00
Robert Schmidt e389b79818 F1 handlers: Improve error message if RNTI obtained through CU/DU ID differ 2018-12-07 16:32:42 +01:00
Robert Schmidt 58850e3c86 Send F1 UE CONTEXT RELEASE REQ when RRC detects radio failure 2018-12-07 16:31:36 +01:00
Robert Schmidt 6f19bc4b8f Add F1AP_UE_CONTEXT_RELEASE_COMPLETE, tx in DU, correctly rx in CU 2018-12-07 15:49:04 +01:00
Robert Schmidt ae3ef27059 Move F1 UE ctxt release req to function mac_eNB_rrc_ul_failure() 2018-12-07 15:37:32 +01:00
Robert Schmidt 412caafd31 F1AP_UE_CONTEXT_RELEASE_COMMAND: Implement in DU, don't send COMPLETE 2018-12-07 14:17:33 +01:00
Robert Schmidt 956fafb51c F1AP_UE_CONTEXT_RELEASE_REQUEST/COMPLETE: Implement in CU 2018-12-07 14:16:42 +01:00
Robert Schmidt 707048c551 F1AP_UE_CONTEXT_RELEASE_REQUEST: Handle in CU, don't send CMD 2018-12-07 14:16:18 +01:00
Robert Schmidt f3f2bc584f F1AP_UE_CONTEXT_RELEASE_REQ: implement in DU
* MAC differentiates between DU/eNB
* sends ITTI message to DU task for F1AP_UE_CONTEXT_RELEASE_REQ
* message is dispatched to correctly in DU_TASK
* sender correctly fills IDs and cause and sends
2018-12-07 14:16:12 +01:00
Robert Schmidt d9bf26b9e8 Sort FlexRAN statistics by user before sending 2018-12-05 11:46:54 +01:00
Robert Schmidt 62b89f828a FlexRAN: Circumvent different RRC/MAC layer user ID sorting
* RRC and MAC might sort users differently
* therefore, we have to "reverse lookup" the MAC ID from the RNTI when filling
  user info
* For this purpose, add RAN API function flexran_get_mac_ue_id_rnti()
2018-12-05 11:46:26 +01:00
Robert Schmidt 8d862dace4 F1 test: fixes after merge 2018-11-07 16:13:04 +01:00
Robert Schmidt f3a5720dd9 FlexRAN: Apply slicing configuration if MAC CM present 2018-11-07 16:13:03 +01:00
Robert Schmidt f0c5f57159 Do not free mem_block in PDCP, it is freed in F1 or RLC 2018-11-07 16:13:03 +01:00
Robert Schmidt c32094685e Deliver SCTP ITTI messages with instance I 2018-11-07 16:13:03 +01:00
Robert Schmidt a477043a24 Add some useful LOG statements 2018-11-07 16:13:03 +01:00
Robert Schmidt 6c33f79095 Fix bugs after merge
* F1AP has to read MCC/MNC from list
* Do not stop if MACRLC list is not present in conf, it might be a CU
2018-11-07 16:13:03 +01:00
Robert Schmidt 04126f7bdc Do not compile with mem_block.c 2018-11-07 16:13:03 +01:00
Robert Schmidt 07d9c6a3be Cast malloc() to type 2018-11-07 16:13:03 +01:00
Robert Schmidt 6bd69d6eaa Leave OER support in asn1c enabled
OER can be disable with the switch -DASN_DISABLE_OER_SUPPORT. In F1AP,
disabling OER leads to a typedef void a_type; leading to lots of compilation
errors because of illegal void variable declarations. This commit leaves OER
support enabled, avoiding this error.
2018-11-07 16:13:03 +01:00
Robert Schmidt 397d2f4815 Merge commit 'develop' into feature-127-protocol-split
* remove a lot of white spaces
* many conflicts in enb_config.c
2018-11-07 16:07:59 +01:00
Robert Schmidt c1e680dd89 FlexRAN: free memory of statistics reports 2018-11-07 10:58:09 +01:00
Robert Schmidt 836f6c6374 Include statistics flag only when values are written 2018-11-07 10:54:35 +01:00
Robert Schmidt f02b539234 Correct init_cont_stats_update(), test for result 2018-11-07 10:54:35 +01:00
Robert Schmidt 2cf4060680 Implement stats_reply-specific destroy function 2018-11-07 10:54:35 +01:00
Robert Schmidt 86d8e21445 Test for CMs before taking CM-specific stats 2018-11-07 10:54:34 +01:00
Robert Schmidt 23650bdea3 Make flexran_agent_handle_stats() respect presence of MAC, RRC CMs 2018-11-07 10:54:34 +01:00
Robert Schmidt 3b3c9daefb Reformat flexran_agent_handle_stats() for better readability 2018-11-07 10:54:34 +01:00
Robert Schmidt 328448e875 Remove flexran_agent_send_update_stats() which is unnecessary 2018-11-07 10:54:34 +01:00
Robert Schmidt 70f74777f3 Correctly implement proto_agent_stop(), call it 2018-11-07 10:54:34 +01:00
Robert Schmidt 920a4abb6d Make link_manager threads joinable
This makes it possible to stop the link_manager by joining its threads.
2018-11-07 10:53:59 +01:00
Robert Schmidt e71adffcfd Correct logging messages in FlexRAN & PROTO_AGENT 2018-11-07 10:53:52 +01:00
Robert Schmidt f01c78e532 Set thread names for FlexRAN and PROTO rx_thread 2018-11-07 10:53:52 +01:00
Robert Schmidt 1290552647 Introduce LOG_W logger for PROTO_AGENT 2018-11-07 10:53:52 +01:00
Robert Schmidt 54da66eeac Bugfix: Rename proto_agent global channel variable
The PROTO_AGENT variable holding the channel for various was named as the same
one for FlexRAN. In C, global variables with the same name are merged into one,
which had the effect that the same queues where used for PROTO_AGENT and
FlexRAN, locking the FlexRAN RX thread. Renaming the PROTO_AGENT variable (it
was introduced second) resolves this issue.
2018-11-07 10:53:52 +01:00
Robert Schmidt eaff77695b Correct malloc in proto_agent_async_channel_info 2018-11-07 10:53:52 +01:00
Robert Schmidt 44b29d04c3 Read config before starting FlexRAN for node_type and ID 2018-11-07 10:53:52 +01:00
Robert Schmidt 0efde02161 Sanitize link_manager interface, correct in FlexRAN/PROTO_AGENT
This commit cleans up the link_manager interface:
* don't provide peer_addr/port in create_link_manager() (for TCP/SCTP it is not
  needed, so in the UDP case in needs to be set explicitly)
* Make FlexRAN connect again (correct hardcoded address)
* Fix FlexRAN: retain the manager pointer
* Fix FlexRAN: store receive_queue pointer
* the link_manager's sender thread passes the correct peer_addr/port for the
  UDP case
2018-11-07 10:48:36 +01:00
Robert Schmidt 34adfd2af8 ASYNC_IF link_{send,receive}_packet(): infer socket type automatically 2018-11-07 10:48:36 +01:00
Robert Schmidt ec9e70a023 FlexRAN: provide better error messages in async channel 2018-11-07 10:48:36 +01:00
Robert Schmidt d7948d04b4 Always fill RRC part of ue_config with all parameters 2018-11-07 10:48:36 +01:00