Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG-RAN
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenXG
OpenXG-RAN
Commits
bab159ca
Commit
bab159ca
authored
Mar 29, 2024
by
Robert Schmidt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
L1 DLSCH: don't "steal" pointer but cpy payload
parent
a72ed521
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
18 additions
and
14 deletions
+18
-14
openair1/PHY/NR_TRANSPORT/nr_dlsch.c
openair1/PHY/NR_TRANSPORT/nr_dlsch.c
+2
-1
openair1/PHY/NR_TRANSPORT/nr_dlsch.h
openair1/PHY/NR_TRANSPORT/nr_dlsch.h
+1
-1
openair1/PHY/NR_TRANSPORT/nr_dlsch_coding.c
openair1/PHY/NR_TRANSPORT/nr_dlsch_coding.c
+5
-6
openair1/PHY/NR_TRANSPORT/nr_dlsch_tools.c
openair1/PHY/NR_TRANSPORT/nr_dlsch_tools.c
+4
-3
openair1/PHY/defs_gNB.h
openair1/PHY/defs_gNB.h
+4
-2
openair1/SCHED_NR/fapi_nr_l1.c
openair1/SCHED_NR/fapi_nr_l1.c
+2
-1
No files found.
openair1/PHY/NR_TRANSPORT/nr_dlsch.c
View file @
bab159ca
...
...
@@ -105,8 +105,9 @@ void nr_generate_pdsch(processingData_L1tx_t *msgTx, int frame, int slot)
harq
->
unav_res
=
ptrsSymbPerSlot
*
n_ptrs
;
/// CRC, coding, interleaving and rate matching
AssertError
(
harq
->
pdu
!=
NULL
,
return
,
"harq->pdu is null
\n
"
);
AssertError
(
harq
->
sdu_len
>
0
,
return
,
"no HARQ SDU present
\n
"
);
unsigned
char
output
[
rel15
->
rbSize
*
NR_SYMBOLS_PER_SLOT
*
NR_NB_SC_PER_RB
*
Qm
*
rel15
->
nrOfLayers
]
__attribute__
((
aligned
(
64
)));
DevAssert
(
harq
->
sdu_len
<
rel15
->
rbSize
*
NR_SYMBOLS_PER_SLOT
*
NR_NB_SC_PER_RB
*
Qm
*
rel15
->
nrOfLayers
);
bzero
(
output
,
rel15
->
rbSize
*
NR_SYMBOLS_PER_SLOT
*
NR_NB_SC_PER_RB
*
Qm
*
rel15
->
nrOfLayers
);
start_meas
(
dlsch_encoding_stats
);
...
...
openair1/PHY/NR_TRANSPORT/nr_dlsch.h
View file @
bab159ca
...
...
@@ -36,7 +36,7 @@
#include "PHY/defs_gNB.h"
void
nr_fill_dlsch_dl_tti_req
(
processingData_L1tx_t
*
msgTx
,
nfapi_nr_dl_tti_pdsch_pdu
*
pdsch_pdu
);
void
nr_fill_dlsch_tx_req
(
processingData_L1tx_t
*
msgTx
,
int
idx
,
uint8_t
*
sdu
);
void
nr_fill_dlsch_tx_req
(
processingData_L1tx_t
*
msgTx
,
int
idx
,
uint8_t
*
sdu
,
uint16_t
sdu_len
);
void
nr_generate_pdsch
(
processingData_L1tx_t
*
msgTx
,
int
frame
,
...
...
openair1/PHY/NR_TRANSPORT/nr_dlsch_coding.c
View file @
bab159ca
...
...
@@ -72,7 +72,6 @@ void free_gNB_dlsch(NR_gNB_DLSCH_t *dlsch, uint16_t N_RB, const NR_DL_FRAME_PARM
harq
->
c
[
r
]
=
NULL
;
}
free
(
harq
->
c
);
free
(
harq
->
pdu
);
for
(
int
layer
=
0
;
layer
<
max_layers
;
layer
++
)
{
for
(
int
aa
=
0
;
aa
<
64
;
aa
++
)
...
...
@@ -113,10 +112,9 @@ NR_gNB_DLSCH_t new_gNB_dlsch(NR_DL_FRAME_PARMS *frame_parms, uint16_t N_RB)
bzero
(
harq
,
sizeof
(
NR_DL_gNB_HARQ_t
));
harq
->
b
=
malloc16
(
dlsch_bytes
);
AssertFatal
(
harq
->
b
,
"cannot allocate memory for harq->b
\n
"
);
harq
->
pdu
=
malloc16
(
dlsch_bytes
);
AssertFatal
(
harq
->
pdu
,
"cannot allocate memory for harq->pdu
\n
"
);
bzero
(
harq
->
pdu
,
dlsch_bytes
);
nr_emulate_dlsch_payload
(
harq
->
pdu
,
(
dlsch_bytes
)
>>
3
);
bzero
(
harq
->
sdu
,
dlsch_bytes
);
harq
->
sdu_len
=
dlsch_bytes
;
nr_emulate_dlsch_payload
(
harq
->
sdu
,
(
dlsch_bytes
)
>>
3
);
bzero
(
harq
->
b
,
dlsch_bytes
);
harq
->
c
=
(
uint8_t
**
)
malloc16
(
a_segments
*
sizeof
(
uint8_t
*
));
...
...
@@ -275,7 +273,8 @@ int nr_dlsch_encoding(PHY_VARS_gNB *gNB,
impp
.
Zc
=
harq
->
Z
;
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME
(
VCD_SIGNAL_DUMPER_FUNCTIONS_gNB_DLSCH_ENCODING
,
VCD_FUNCTION_IN
);
uint32_t
A
=
rel15
->
TBSize
[
0
]
<<
3
;
unsigned
char
*
a
=
harq
->
pdu
;
AssertFatal
(
A
==
harq
->
sdu_len
*
8
,
"A %d bits sdu_len %d bytes %d bits
\n
"
,
A
,
harq
->
sdu_len
,
harq
->
sdu_len
*
8
);
unsigned
char
*
a
=
harq
->
sdu
;
if
(
rel15
->
rnti
!=
SI_RNTI
)
trace_NRpdu
(
DIRECTION_DOWNLINK
,
a
,
rel15
->
TBSize
[
0
],
WS_C_RNTI
,
rel15
->
rnti
,
frame
,
slot
,
0
,
0
);
...
...
openair1/PHY/NR_TRANSPORT/nr_dlsch_tools.c
View file @
bab159ca
...
...
@@ -55,10 +55,10 @@ void nr_fill_dlsch_dl_tti_req(processingData_L1tx_t *msgTx, nfapi_nr_dl_tti_pdsc
pdsch_pdu
->
pdsch_pdu_rel15
.
pduIndex
,
msgTx
->
num_pdsch_slot
);
msgTx
->
num_pdsch_slot
++
;
harq
->
pdu
=
NULL
;
harq
->
sdu_len
=
0
;
}
void
nr_fill_dlsch_tx_req
(
processingData_L1tx_t
*
msgTx
,
int
idx
,
uint8_t
*
sdu
)
void
nr_fill_dlsch_tx_req
(
processingData_L1tx_t
*
msgTx
,
int
idx
,
uint8_t
*
sdu
,
uint16_t
sdu_len
)
{
AssertFatal
(
sdu
!=
NULL
,
"sdu is null
\n
"
);
...
...
@@ -68,5 +68,6 @@ void nr_fill_dlsch_tx_req(processingData_L1tx_t *msgTx, int idx, uint8_t *sdu)
NR_DL_gNB_HARQ_t
*
harq
=
&
dlsch
->
harq_process
;
nfapi_nr_dl_tti_pdsch_pdu
*
pdsch
=
&
harq
->
pdsch_pdu
;
AssertFatal
(
pdsch
->
pdsch_pdu_rel15
.
pduIndex
==
idx
,
"PDSCH PDU index %d does not match %d
\n
"
,
pdsch
->
pdsch_pdu_rel15
.
pduIndex
,
idx
);
harq
->
pdu
=
sdu
;
harq
->
sdu_len
=
sdu_len
;
memcpy
(
harq
->
sdu
,
sdu
,
sdu_len
);
}
openair1/PHY/defs_gNB.h
View file @
bab159ca
...
...
@@ -73,8 +73,10 @@ typedef enum {
typedef
struct
{
/// Nfapi DLSCH PDU
nfapi_nr_dl_tti_pdsch_pdu
pdsch_pdu
;
/// pointer to pdu from MAC interface (this is "a" in 36.212)
uint8_t
*
pdu
;
/// length of PDU to encode
uint32_t
sdu_len
;
/// sdu from MAC interface (this is "a" in 36.212)
uint8_t
sdu
[
65536
];
/// Pointer to the payload
uint8_t
*
b
;
/// Pointers to transport block segments
...
...
openair1/SCHED_NR/fapi_nr_l1.c
View file @
bab159ca
...
...
@@ -192,8 +192,9 @@ void nr_schedule_tx_req(PHY_VARS_gNB *gNB, nfapi_nr_tx_data_request_t *TX_req)
processingData_L1tx_t
*
msgTx
=
gNB
->
msgDataTx
;
for
(
int
idx
=
0
;
idx
<
TX_req
->
Number_of_PDUs
;
++
idx
)
{
uint16_t
len
=
TX_req
->
pdu_list
[
idx
].
TLVs
[
0
].
length
;
uint8_t
*
sdu
=
(
uint8_t
*
)
TX_req
->
pdu_list
[
idx
].
TLVs
[
0
].
value
.
direct
;
nr_fill_dlsch_tx_req
(
msgTx
,
idx
,
sdu
);
nr_fill_dlsch_tx_req
(
msgTx
,
idx
,
sdu
,
len
);
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment