Merge antenna muting mechanism onto 2026.w17

Brings the O-RAN compliant antenna muting feature (originally introduced
on the 'new' branch) onto the latest upstream 2026.w17 tag.

Files added:
  openair1/PHY/NR_TRANSPORT/nr_antenna_state.{c,h}
  openair1/PHY/NR_TRANSPORT/nr_antenna_control.{c,h}

Files modified (integration hooks):
  CMakeLists.txt, executables/nr-gnb.c
  openair1/PHY/INIT/nr_init.c, openair1/PHY/defs_gNB.h
  openair1/PHY/MODULATION/{beamforming.c,nr_modulation.h,nr_beamforming.c}
  openair1/SCHED_NR/nr_ru_procedures.c
  openair2/LAYER2/NR_MAC_gNB/mac_proto.h
  openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_{primitives,dlsch,uci}.c

Conflicts resolved:
  - defs_gNB.h: kept upstream's new headers + appended antenna_state.h
  - nr_init.c: dropped reference to upstream-removed nr_srs_info init,
    kept nr_init_antenna_state() call
  - beamforming.c: upstream moved nr_beam_precoding into new file
    nr_beamforming.c; nr_beam_precoding_with_muting added there with
    upstream's signature (no slot param)
  - nr_modulation.h: aligned _with_muting decl to upstream signature
  - nr_ru_procedures.c: muting check applied around upstream's new
    fft_shift in nr_feptx, and around per-port memcpy in nr_feptx_prec
  - gNB_scheduler_uci.c: SINR-based MCS hint uses get_dl_nrOfLayers(NULL,
    sched_ctrl, ...) since nrmac is not in scope at the call site
  - mac_proto.h: get_dl_nrOfLayers signature updated to take gNB_MAC_INST*

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-04-27 06:25:57 +09:00
co-authored by Claude Opus 4.7
parent bfb177c38e
commit 7cd72323af
16 changed files with 1478 additions and 79 deletions
+10
View File
@@ -24,6 +24,8 @@
#include "NR_PHY_INTERFACE/NR_IF_Module.h"
#include "PHY/INIT/nr_phy_init.h"
#include "PHY/MODULATION/nr_modulation.h"
#include "openair2/LAYER2/NR_MAC_gNB/nr_mac_gNB.h"
#include "PHY/NR_TRANSPORT/nr_antenna_control.h"
#include "PHY/NR_TRANSPORT/nr_transport_proto.h"
#include "PHY/TOOLS/tools_defs.h"
#include "PHY/defs_RU.h"
@@ -372,6 +374,14 @@ void init_eNB_afterRU(void)
*/
//init_precoding_weights(RC.gNB[inst]);
init_gNB_Tpool(inst);
// antenna control
if (nr_antenna_control_start_test_server(&gNB->antenna_state, 9999))
LOG_I(PHY, "[ANTENNA_CTRL] Test control server started on port 9999\n");
if (inst < RC.nb_nr_macrlc_inst && RC.nrmac && RC.nrmac[inst]) {
RC.nrmac[inst]->antenna_state = &gNB->antenna_state;
LOG_I(PHY, "[ANTENNA_STATE] Connected MAC scheduler to PHY antenna state for dynamic layer adaptation\n");
}
}
}