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
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
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
ZhouShuya
OpenXG-RAN
Commits
3514b247
Commit
3514b247
authored
Sep 08, 2016
by
hbilel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix UE-DFT segmentation fault: align rx_data buffer
parent
64cd0076
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
32 additions
and
19 deletions
+32
-19
openair1/PHY/MODULATION/slot_fep_ul.c
openair1/PHY/MODULATION/slot_fep_ul.c
+32
-19
No files found.
openair1/PHY/MODULATION/slot_fep_ul.c
View file @
3514b247
...
...
@@ -50,6 +50,10 @@ int slot_fep_ul(LTE_DL_FRAME_PARMS *frame_parms,
void
(
*
dft
)(
int16_t
*
,
int16_t
*
,
int
);
int
tmp_dft_in
[
2048
]
__attribute__
((
aligned
(
32
)));
// This is for misalignment issues for 6 and 15 PRBs
unsigned
int
frame_length_samples
=
frame_parms
->
samples_per_tti
*
10
;
unsigned
int
rx_offset
;
switch
(
frame_parms
->
ofdm_symbol_size
)
{
case
128
:
dft
=
dft128
;
...
...
@@ -103,28 +107,37 @@ int slot_fep_ul(LTE_DL_FRAME_PARMS *frame_parms,
#endif
for
(
aa
=
0
;
aa
<
frame_parms
->
nb_antennas_rx
;
aa
++
)
{
rx_offset
=
slot_offset
+
nb_prefix_samples0
;
if
(
l
==
0
)
{
dft
(
#ifndef OFDMA_ULSCH
(
int16_t
*
)
&
eNB_common_vars
->
rxdata_7_5kHz
[
eNB_id
][
aa
][
slot_offset
+
nb_prefix_samples0
],
#else
(
int16_t
*
)
&
eNB_common_vars
->
rxdata
[
eNB_id
][
aa
][((
frame_parms
->
samples_per_tti
>>
1
)
*
Ns
)
+
nb_prefix_samples0
],
#endif
(
int16_t
*
)
&
eNB_common_vars
->
rxdataF
[
eNB_id
][
aa
][
frame_parms
->
ofdm_symbol_size
*
symbol
],
1
);
dft
(
(
int16_t
*
)
&
eNB_common_vars
->
rxdata_7_5kHz
[
eNB_id
][
aa
][
rx_offset
],
(
int16_t
*
)
&
eNB_common_vars
->
rxdataF
[
eNB_id
][
aa
][
frame_parms
->
ofdm_symbol_size
*
symbol
],
1
);
}
else
{
dft
(
#ifndef OFDMA_ULSCH
(
short
*
)
&
eNB_common_vars
->
rxdata_7_5kHz
[
eNB_id
][
aa
][
slot_offset
+
#else
(
short
*
)
&
eNB_common_vars
->
rxdata
[
eNB_id
][
aa
][((
frame_parms
->
samples_per_tti
>>
1
)
*
Ns
)
+
#endif
(
frame_parms
->
ofdm_symbol_size
+
nb_prefix_samples0
+
nb_prefix_samples
)
+
(
frame_parms
->
ofdm_symbol_size
+
nb_prefix_samples
)
*
(
l
-
1
)],
(
short
*
)
&
eNB_common_vars
->
rxdataF
[
eNB_id
][
aa
][
frame_parms
->
ofdm_symbol_size
*
symbol
],
1
);
rx_offset
+=
(
frame_parms
->
ofdm_symbol_size
+
nb_prefix_samples
)
*
l
;
if
(
rx_offset
>
(
frame_length_samples
-
frame_parms
->
ofdm_symbol_size
))
{
memcpy
((
void
*
)
&
eNB_common_vars
->
rxdata_7_5kHz
[
eNB_id
][
aa
][
frame_length_samples
],
(
void
*
)
&
eNB_common_vars
->
rxdata_7_5kHz
[
eNB_id
][
aa
][
0
],
frame_parms
->
ofdm_symbol_size
*
sizeof
(
int
));
}
if
(
(
rx_offset
&
7
)
!=
0
){
memcpy
((
void
*
)
&
tmp_dft_in
,
(
void
*
)
&
eNB_common_vars
->
rxdata_7_5kHz
[
eNB_id
][
aa
][(
rx_offset
%
frame_length_samples
)],
frame_parms
->
ofdm_symbol_size
*
sizeof
(
int
));
dft
(
(
short
*
)
tmp_dft_in
,
(
short
*
)
&
eNB_common_vars
->
rxdataF
[
eNB_id
][
aa
][
frame_parms
->
ofdm_symbol_size
*
symbol
],
1
);
}
else
{
dft
(
(
short
*
)
&
eNB_common_vars
->
rxdata_7_5kHz
[
eNB_id
][
aa
][
rx_offset
],
(
short
*
)
&
eNB_common_vars
->
rxdataF
[
eNB_id
][
aa
][
frame_parms
->
ofdm_symbol_size
*
symbol
],
1
);
}
}
}
...
...
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