Commit Graph

8731 Commits

Author SHA1 Message Date
Andre Puschmann 272fc47bc2 ue,worker_pool: fix logging of Msg3 UL grant 2021-09-06 10:35:59 +02:00
Andre Puschmann 66c87aafdb rrc_nr: fix PRACH seq and RNTI for RRC Reconfig 2021-09-06 10:35:59 +02:00
Andre Puschmann 14758b087c enb,mac_nr: fix Msg3 UL grant packing in RAR 2021-09-06 10:35:59 +02:00
Francisco Paisana e146345df0 sched,nr: add ue removal method to nr sched 2021-09-04 11:34:56 +02:00
Francisco Paisana a7bf1ad26d sched,nr: use NR UL DCI to fill RAR grant contents 2021-09-03 12:50:36 +02:00
Andre Puschmann efa79bf408 sched_nr_helpers: fix copy-paste error UL vs DL 2021-09-03 12:09:41 +02:00
Andre Puschmann 548c45a8fc enb,mac_nr: add RAR packing 2021-09-03 12:09:41 +02:00
Andre Puschmann f3e8847ad3 mac_pdu_nr_test: fix test 2021-09-03 12:09:41 +02:00
Andre Puschmann 82e9652a92 mac_sch_pdu_nr: fix ASAN/fmt issue when print space 2021-09-03 12:09:41 +02:00
Andre Puschmann ea48a350a4 mac_rar_pdu_nr: fix clearing of padding bytes 2021-09-03 12:09:41 +02:00
Andre Puschmann 02bd15878e mac_sch_pdu_nr: fix logging 2021-09-03 12:09:41 +02:00
Andre Puschmann ede81be5e4 mac_rar_pdu_nr: add packing routines
* add packing for RAR PDUs
* rewrite to_string() to use fmt lib
* add test case for packer
2021-09-03 12:09:41 +02:00
Andre Puschmann b20fefbe45 mac_nr_test: flush srslog at the end of test
fixes stack use after free detected by ASAN

2021-08-31T17:21:44.885938 [MAC-NR ] [D] [    0] Building new MAC PDU (9 B)
==10908==ERROR: AddressSanitizer: stack-use-after-scope on address 0x7ffc481b5340 at pc 0x563c0486d489 bp 0x7ffc481b4470 sp 0x7ffc481b4460
READ of size 1 at 0x7ffc481b5340 thread T0
    #0 0x563c0486d488 in srsran::mac_sch_subpdu_nr::to_string(fmt::v7::basic_memory_buffer<char, 500ul, std::allocator<char> >&) (/home/ubuntu/workspace/srslte_ubuntu_20.04_pull_request/srslte/build/srsue/src/stack/mac_nr/test/mac_nr_test+0x139488)
    #1 0x563c0486db87 in srsran::mac_sch_pdu_nr::to_string(fmt::v7::basic_memory_buffer<char, 500ul, std::allocator<char> >&) (/home/ubuntu/workspace/srslte_ubuntu_20.04_pull_request/srslte/build/srsue/src/stack/mac_nr/test/mac_nr_test+0x139b87)
    #2 0x563c0481c127 in srsue::mux_nr::get_pdu(unsigned int) (/home/ubuntu/workspace/srslte_ubuntu_20.04_pull_request/srslte/build/srsue/src/stack/mac_nr/test/mac_nr_test+0xe8127)
    #3 0x563c0484e62b in srsue::ul_harq_entity_nr::ul_harq_process_nr::new_grant_ul(srsue::mac_interface_phy_nr::mac_nr_grant_ul_t const&, bool const&, srsue::mac_interface_phy_nr::tb_action_ul_t*) (/home/ubuntu/workspace/srslte_ubuntu_20.04_pull_request/srslte/build/srsue/src/stack/mac_nr/test/mac_nr_test+0x11a62b)
    #4 0x563c04850de4 in srsue::ul_harq_entity_nr::new_grant_ul(srsue::mac_interface_phy_nr::mac_nr_grant_ul_t const&, srsue::mac_interface_phy_nr::tb_action_ul_t*) (/home/ubuntu/workspace/srslte_ubuntu_20.04_pull_request/srslte/build/srsue/src/stack/mac_nr/test/mac_nr_test+0x11cde4)
    #5 0x563c047bb004 in srsue::mac_nr::new_grant_ul(unsigned int, srsue::mac_interface_phy_nr::mac_nr_grant_ul_t const&, srsue::mac_interface_phy_nr::tb_action_ul_t*) (/home/ubuntu/workspace/srslte_ubuntu_20.04_pull_request/srslte/build/srsue/src/stack/mac_nr/test/mac_nr_test+0x87004)
    #6 0x563c04760cdc in msg3_test() (/home/ubuntu/workspace/srslte_ubuntu_20.04_pull_request/srslte/build/srsue/src/stack/mac_nr/test/mac_nr_test+0x2ccdc)
    #7 0x563c0475f762 in main (/home/ubuntu/workspace/srslte_ubuntu_20.04_pull_request/srslte/build/srsue/src/stack/mac_nr/test/mac_nr_test+0x2b762)
    #8 0x7fae1cf400b2 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x270b2)
    #9 0x563c047601bd in _start (/home/ubuntu/workspace/srslte_ubuntu_20.04_pull_request/srslte/build/srsue/src/stack/mac_nr/test/mac_nr_test+0x2c1bd)

Address 0x7ffc481b5340 is located in stack of thread T0 at offset 320 in frame
    #0 0x563c0486d78f in srsran::mac_sch_pdu_nr::to_string(fmt::v7::basic_memory_buffer<char, 500ul, std::allocator<char> >&) (/home/ubuntu/workspace/srslte_ubuntu_20.04_pull_request/srslte/build/srsue/src/stack/mac_nr/test/mac_nr_test+0x13978f)
2021-09-03 12:09:41 +02:00
Andre Puschmann 9b4f6cb8bb mac_nr: pretty-print received/transmitted MAC PDUs in logs 2021-09-03 12:09:41 +02:00
Andre Puschmann 20c0e0bc41 mac_sch_pdu_nr: add to_string() helper to format MAC PDUs in logs 2021-09-03 12:09:41 +02:00
Francisco Paisana 1dfc884b65 Changed S1AP causes for non-existing cell in HO and not available radio resources in HO for more apropriate ones. 2021-09-03 12:06:28 +02:00
Francisco Paisana 227ae97bcb workaround gcc4.8 issue with inability to derive move ctor noexcept specifier 2021-09-03 12:06:17 +02:00
Francisco Paisana ebd12b0778 stack lte,refactor: pass bearer manager instead of stack pointer to srsenb::rrc 2021-09-03 12:06:17 +02:00
Francisco Paisana f4df55c245 stack lte: separate bearer manager into two classes, one for the ue and one for the enb 2021-09-03 12:06:17 +02:00
Francisco Paisana cb2c339456 sched,nr: fix max number of UEs in NR scheduler 2021-09-03 12:05:55 +02:00
Andre Puschmann 201f29b4e5 enb,rrc_nr: register DRB1 at RLC/PDCP when enabling NSA mode 2021-09-03 11:23:17 +02:00
Francisco Paisana 296949b5f9 stack lte: use adapter for pdcp->gtpu write_pdu interface that converts lcid to eps bearer id 2021-09-02 17:12:04 +02:00
Francisco Paisana 2ade4628ca stack lte: create an gtpu-pdcp adapter class that correctly converts lcids to eps bearers and vice-versa 2021-09-02 17:12:04 +02:00
Francisco Paisana 4b2f079581 gtpu: renamed lcid to eps_bearer_id as parte of the refactor of gtpu to use eps_bearer_ids 2021-09-02 17:12:04 +02:00
Andre Puschmann b27d1d913e enb_stack_lte: use bearer manager class
* user common bearer manager in eNB
* register/deregister bearers (LTE only so far
* provide dummy stack class for RRC tests
2021-09-02 17:12:04 +02:00
Andre Puschmann 3949a727a7 enb_interface: add stack interface for RRC
RRC uses the interface to register/deregister EPS bearer
2021-09-02 17:12:04 +02:00
Andre Puschmann db8b710442 bearer_manager: move to lib folder and extend for multiple users
prepare bearer manager to be used by eNB which requires
to support multiple RNTIs
2021-09-02 17:12:04 +02:00
Andre Puschmann ebef8a4cc4 enb_stack_lte: implement the PDCP interface for GTPU on the stack
this prepares for a change in which GTPU no longer writes into PDCP
directly but instead uses the stack as a wrapper.

For this the interface will be changed to use the EPS bearer ID instead
of the LCID

The stack will know which PDCP entity (EUTRA or NR) is currently associated
with the EPS bearer ID and will forward the PDU accordingly.
2021-09-02 17:12:04 +02:00
faluco 5f9aceb8b6 Fix alignment issue with the stdout metrics in srsue. 2021-09-02 17:10:56 +02:00
Francisco Paisana 75cd71b794 sched,nr: fix older gcc compilation array initialization 2021-09-01 20:08:11 +02:00
Francisco Paisana 510a87e4b2 sched,nr: added logic to update UE DL and UL buffer status 2021-09-01 20:08:11 +02:00
Francisco Paisana 020bec025e sched: created class common to LTE and NR for ue buffer status management 2021-09-01 20:08:11 +02:00
Francisco Paisana de06dbc684 sched,nr: implemented basic UE buffer status manager 2021-09-01 20:08:11 +02:00
Francisco Paisana 2fb2598f8c sched,nr: avoid extra copy of DL result and other small fixes 2021-09-01 20:08:11 +02:00
Xavier Arteaga 9e1669c403 Better comments in minimum size symbol selection 2021-08-31 18:56:41 +02:00
Xavier Arteaga 4858202bf6 Fix NR symbol size for 270RB 2021-08-31 18:56:41 +02:00
Xavier Arteaga 54c39d8447 Set nr_phy_test scheduler logger to the level defined in the arguments 2021-08-31 18:56:41 +02:00
Xavier Arteaga 14a85d31ec Fix symbol size simensioning for LTE standard rate 2021-08-31 18:56:41 +02:00
Xavier Arteaga 01390a7340 Better NR softbuffer size adjustment 2021-08-31 18:56:41 +02:00
Andre Puschmann a80fdc0703 mac_nr: set logger slot context in get_dl_sched() 2021-08-31 17:20:13 +02:00
Andre Puschmann f20e131083 mac_nr: when reserving RNTI in MAC, don't automatically reserve it in RRC
we assume that RRC itself will reserve the RNTI if it needs to
2021-08-31 17:20:13 +02:00
Andre Puschmann 9bf74843f6 mac_pdu_nr: add error handling to init_tx() method
check provided byte_buffer and return error if it's not valid
2021-08-31 17:20:13 +02:00
Andre Puschmann 4ef1ac2649 gw: (re-)use class mutex when updating the DL/UL metrics 2021-08-31 17:01:50 +02:00
Andre Puschmann aa43e3c8d6 ue,mac: adding missing mutex when updating metrics 2021-08-31 17:01:50 +02:00
Andre Puschmann e1776f8d28 ue,phy: update the PRACH params inside the lambda that also executes the reconfig
setting the new PRACH params (writing the the local var) needs to protected as well
because it is called from the RRC context and the PHY worker will call configure_prach_params()
if it sees changes to it.
2021-08-31 17:01:50 +02:00
Andre Puschmann 40499e6b6d ue_stack_lte: use std::atomic for running var 2021-08-31 17:01:50 +02:00
Andre Puschmann 79cdc28015 nas_test_common: call NAS layer from stack thread context
since NAS layers insn't thread safe, all calls must come from
the same thread
2021-08-31 17:00:59 +02:00
Andre Puschmann 78d60bc138 nas: remove all uses of atomic from 4G and 5G classes
the NAS classes aren't thread safe and thread-safety shouldn't be
pretended by using atomics. Remove them and add explicit notice.
2021-08-31 17:00:59 +02:00
Fabian Eckermann c63932f514 Added RACH, PDSCH, PUCCH, Sounding Reference Signal and UL Power Control configurations from target cell to RRCConnectionReconfigurationMessage 2021-08-31 15:47:46 +02:00
Francisco Paisana 5f9cfb56f6 lte,gtpu: fix and refactor gtpu tunnel management during handover 2021-08-31 15:46:46 +02:00