diff --git a/srsue/src/phy/phy.cc b/srsue/src/phy/phy.cc index 5c8997881..ba4d25b8b 100644 --- a/srsue/src/phy/phy.cc +++ b/srsue/src/phy/phy.cc @@ -272,11 +272,8 @@ void phy::set_activation_deactivation_scell(uint32_t cmd) Info("Received SCell Activation / Deactivation command: 0x%x\n", cmd); /* Implements 3GPP 36.321 section 6.1.3.8. Activation/Deactivation MAC Control Element*/ - srslte::console("SCELL Activation / Deactivation CMD: %x\n", cmd); - log_h->info("SCELL Activation / Deactivation CMD: %x\n", cmd); - for (uint32_t i = 1; i < SRSLTE_MAX_CARRIERS; i++) { - bool activated = ((cmd >> i) & 0x1) == 0x1; + bool activated = ((cmd >> i) & 0x1u) == 0x1u; /* Enable actual cell */ common.enable_scell(i, activated); diff --git a/srsue/src/stack/mac/demux.cc b/srsue/src/stack/mac/demux.cc index 4bcc1ce03..3da497972 100644 --- a/srsue/src/stack/mac/demux.cc +++ b/srsue/src/stack/mac/demux.cc @@ -286,9 +286,13 @@ bool demux::process_ce(srslte::sch_subh* subh) case srslte::dl_sch_lcid::TA_CMD: parse_ta_cmd(subh); break; - case srslte::dl_sch_lcid::SCELL_ACTIVATION: - phy_h->set_activation_deactivation_scell((uint32_t)subh->get_activation_deactivation_cmd()); + case srslte::dl_sch_lcid::SCELL_ACTIVATION: { + uint32_t cmd = (uint32_t)subh->get_activation_deactivation_cmd(); + srslte::console("SCELL Activation / Deactivation CMD: %x\n", cmd); + log_h->info("SCELL Activation / Deactivation CMD: %x\n", cmd); + phy_h->set_activation_deactivation_scell(cmd); break; + } case srslte::dl_sch_lcid::PADDING: break; default: