Fix FFT size for xran_fh_tx_send_slot_BySymbol() and xran_fh_rx_read_slot_BySymbol()

This commit is contained in:
Mario Joa-Ng
2026-01-22 02:54:03 +01:00
parent 102965a669
commit 2f6b30cdb4
3 changed files with 12 additions and 2 deletions
+4 -2
View File
@@ -702,6 +702,7 @@ int xran_fh_tx_send_slot(ru_info_t *ru, int frame, int slot, uint64_t timestamp)
return (0); return (0);
} }
#ifdef F_RELEASE
/** @details Read PRACH and PUSCH data from xran buffers. If /** @details Read PRACH and PUSCH data from xran buffers. If
* I/Q compression (bitwidth < 16 bits) is configured, deccompresses the data * I/Q compression (bitwidth < 16 bits) is configured, deccompresses the data
* before writing. Prints ON TIME counters every 128 frames. * before writing. Prints ON TIME counters every 128 frames.
@@ -764,7 +765,7 @@ int xran_fh_rx_read_slot_BySymbol(ru_info_t *ru, int *frame, int *slot)
const struct xran_fh_init *fh_init = get_xran_fh_init(); const struct xran_fh_init *fh_init = get_xran_fh_init();
int nPRBs = fh_cfg->nULRBs; int nPRBs = fh_cfg->nULRBs;
int fftsize = 1 << fh_cfg->ru_conf.fftSize; int fftsize = 1 << fh_cfg->nULFftSize;
int slot_offset_rxdata = 3 & (*slot); int slot_offset_rxdata = 3 & (*slot);
uint32_t slot_size = 4 * 14 * fftsize; uint32_t slot_size = 4 * 14 * fftsize;
@@ -942,7 +943,7 @@ int xran_fh_tx_send_slot_BySymbol(ru_info_t *ru, int frame, int slot, uint64_t t
const struct xran_fh_init *fh_init = get_xran_fh_init(); const struct xran_fh_init *fh_init = get_xran_fh_init();
const struct xran_fh_config *fh_cfg = get_xran_fh_config(0); const struct xran_fh_config *fh_cfg = get_xran_fh_config(0);
int nPRBs = fh_cfg->nDLRBs; int nPRBs = fh_cfg->nDLRBs;
int fftsize = 1 << fh_cfg->ru_conf.fftSize; int fftsize = 1 << fh_cfg->nDLFftSize;
int nb_tx_per_ru = ru->nb_tx / fh_init->xran_ports; int nb_tx_per_ru = ru->nb_tx / fh_init->xran_ports;
int nb_rx_per_ru = ru->nb_rx / fh_init->xran_ports; int nb_rx_per_ru = ru->nb_rx / fh_init->xran_ports;
@@ -1168,3 +1169,4 @@ int xran_fh_tx_send_slot_BySymbol(ru_info_t *ru, int frame, int slot, uint64_t t
} }
return (0); return (0);
} }
#endif
+4
View File
@@ -230,9 +230,11 @@ void oran_fh_if4p5_south_in(RU_t *ru, int *frame, int *slot)
start_meas(&ru->rx_fhaul); start_meas(&ru->rx_fhaul);
struct xran_fh_config *fh_cfg = get_xran_fh_config(0); struct xran_fh_config *fh_cfg = get_xran_fh_config(0);
int ret = 0; int ret = 0;
#ifdef F_RELEASE
if (fh_cfg->RunSlotPrbMapBySymbolEnable) if (fh_cfg->RunSlotPrbMapBySymbolEnable)
ret = xran_fh_rx_read_slot_BySymbol(&ru_info, &f, &sl); ret = xran_fh_rx_read_slot_BySymbol(&ru_info, &f, &sl);
else else
#endif
ret = xran_fh_rx_read_slot(&ru_info, &f, &sl); ret = xran_fh_rx_read_slot(&ru_info, &f, &sl);
stop_meas(&ru->rx_fhaul); stop_meas(&ru->rx_fhaul);
LOG_D(HW, "Read %d.%d rxdataF %p,%p\n", f, sl, ru_info.rxdataF[0], ru_info.rxdataF[1]); LOG_D(HW, "Read %d.%d rxdataF %p,%p\n", f, sl, ru_info.rxdataF[0], ru_info.rxdataF[1]);
@@ -290,9 +292,11 @@ void oran_fh_if4p5_south_out(RU_t *ru, int frame, int slot, uint64_t timestamp)
struct xran_fh_config *fh_cfg = get_xran_fh_config(0); struct xran_fh_config *fh_cfg = get_xran_fh_config(0);
int ret = 0; int ret = 0;
#ifdef F_RELEASE
if (fh_cfg->RunSlotPrbMapBySymbolEnable) if (fh_cfg->RunSlotPrbMapBySymbolEnable)
ret = xran_fh_tx_send_slot_BySymbol(&ru_info, frame, slot, timestamp); ret = xran_fh_tx_send_slot_BySymbol(&ru_info, frame, slot, timestamp);
else else
#endif
ret = xran_fh_tx_send_slot(&ru_info, frame, slot, timestamp); ret = xran_fh_tx_send_slot(&ru_info, frame, slot, timestamp);
if (ret != 0) { if (ret != 0) {
printf("ORAN: ORAN_fh_if4p5_south_out ERROR in TX function \n"); printf("ORAN: ORAN_fh_if4p5_south_out ERROR in TX function \n");
+4
View File
@@ -60,9 +60,13 @@ typedef struct ru_info_s {
* @param frame output of the frame which has been read. * @param frame output of the frame which has been read.
* @param slot output of the slot which has been read. */ * @param slot output of the slot which has been read. */
int xran_fh_rx_read_slot(ru_info_t *ru, int *frame, int *slot); int xran_fh_rx_read_slot(ru_info_t *ru, int *frame, int *slot);
#ifdef F_RELEASE
int xran_fh_rx_read_slot_BySymbol(ru_info_t *ru, int *frame, int *slot); int xran_fh_rx_read_slot_BySymbol(ru_info_t *ru, int *frame, int *slot);
#endif
/** @brief Writes TX data (PDSCH) of given slot. */ /** @brief Writes TX data (PDSCH) of given slot. */
int xran_fh_tx_send_slot(ru_info_t *ru, int frame, int slot, uint64_t timestamp); int xran_fh_tx_send_slot(ru_info_t *ru, int frame, int slot, uint64_t timestamp);
#ifdef F_RELEASE
int xran_fh_tx_send_slot_BySymbol(ru_info_t *ru, int frame, int slot, uint64_t timestamp); int xran_fh_tx_send_slot_BySymbol(ru_info_t *ru, int frame, int slot, uint64_t timestamp);
#endif
#endif /* _ORAN_ISOLATE_H_ */ #endif /* _ORAN_ISOLATE_H_ */