|
|
@ -39,22 +39,26 @@ namespace srsenb {
|
|
|
|
class x2_adapter final : public x2_interface
|
|
|
|
class x2_adapter final : public x2_interface
|
|
|
|
{
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
public:
|
|
|
|
x2_adapter(enb_stack_lte* eutra_stack_, gnb_stack_nr* nr_stack_) : nr_stack(nr_stack_), eutra_stack(eutra_stack_) {}
|
|
|
|
x2_adapter(enb_stack_lte* eutra_stack_, gnb_stack_nr* nr_stack_) :
|
|
|
|
|
|
|
|
nr_stack(nr_stack_), eutra_stack(eutra_stack_), logger(srslog::fetch_basic_logger("X2"))
|
|
|
|
|
|
|
|
{}
|
|
|
|
|
|
|
|
|
|
|
|
/// rrc_nr_interface_rrc
|
|
|
|
/// rrc_nr_interface_rrc
|
|
|
|
int sgnb_addition_request(uint16_t eutra_rnti, const sgnb_addition_req_params_t& params) override
|
|
|
|
void sgnb_addition_request(uint16_t eutra_rnti, const sgnb_addition_req_params_t& params) override
|
|
|
|
{
|
|
|
|
{
|
|
|
|
if (nr_stack == nullptr) {
|
|
|
|
if (nr_stack == nullptr) {
|
|
|
|
return SRSRAN_ERROR;
|
|
|
|
logger.error("SgNB Addition Requested for inexistent NR stack");
|
|
|
|
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return nr_stack->sgnb_addition_request(eutra_rnti, params);
|
|
|
|
nr_stack->sgnb_addition_request(eutra_rnti, params);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
int sgnb_reconfiguration_complete(uint16_t eutra_rnti, asn1::dyn_octstring reconfig_response) override
|
|
|
|
void sgnb_reconfiguration_complete(uint16_t eutra_rnti, const asn1::dyn_octstring& reconfig_response) override
|
|
|
|
{
|
|
|
|
{
|
|
|
|
if (nr_stack == nullptr) {
|
|
|
|
if (nr_stack == nullptr) {
|
|
|
|
return SRSRAN_ERROR;
|
|
|
|
logger.error("SgNB Addition Requested for inexistent NR stack");
|
|
|
|
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return nr_stack->sgnb_reconfiguration_complete(eutra_rnti, reconfig_response);
|
|
|
|
nr_stack->sgnb_reconfiguration_complete(eutra_rnti, reconfig_response);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// rrc_eutra_interface_rrc_nr
|
|
|
|
/// rrc_eutra_interface_rrc_nr
|
|
|
@ -96,12 +100,13 @@ public:
|
|
|
|
eutra_stack->set_activity_user(eutra_rnti);
|
|
|
|
eutra_stack->set_activity_user(eutra_rnti);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
int sgnb_release_request(uint16_t nr_rnti) override
|
|
|
|
void sgnb_release_request(uint16_t nr_rnti) override
|
|
|
|
{
|
|
|
|
{
|
|
|
|
if (nr_stack == nullptr) {
|
|
|
|
if (nr_stack == nullptr) {
|
|
|
|
return SRSRAN_ERROR;
|
|
|
|
logger.error("SgNB Addition Requested for inexistent NR stack");
|
|
|
|
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return nr_stack->sgnb_release_request(nr_rnti);
|
|
|
|
nr_stack->sgnb_release_request(nr_rnti);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// pdcp_interface_gtpu
|
|
|
|
// pdcp_interface_gtpu
|
|
|
@ -132,6 +137,7 @@ public:
|
|
|
|
private:
|
|
|
|
private:
|
|
|
|
enb_stack_lte* eutra_stack = nullptr;
|
|
|
|
enb_stack_lte* eutra_stack = nullptr;
|
|
|
|
gnb_stack_nr* nr_stack = nullptr;
|
|
|
|
gnb_stack_nr* nr_stack = nullptr;
|
|
|
|
|
|
|
|
srslog::basic_logger& logger;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
} // namespace srsenb
|
|
|
|
} // namespace srsenb
|
|
|
|