Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
U
UERANSIM
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
Libraries
UERANSIM
Commits
b9fbbf41
Commit
b9fbbf41
authored
Jan 05, 2022
by
aligungr
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Performance improvements
parent
ffbec812
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
15 additions
and
8 deletions
+15
-8
src/ue/l23/task.cpp
src/ue/l23/task.cpp
+1
-0
src/ue/l23/task.hpp
src/ue/l23/task.hpp
+7
-0
src/ue/nas/sm/release.cpp
src/ue/nas/sm/release.cpp
+3
-1
src/ue/nas/sm/resource.cpp
src/ue/nas/sm/resource.cpp
+2
-1
src/ue/nas/sm/sap.cpp
src/ue/nas/sm/sap.cpp
+1
-1
src/ue/tun/layer.cpp
src/ue/tun/layer.cpp
+1
-1
src/ue/types.hpp
src/ue/types.hpp
+0
-3
src/ue/ue.cpp
src/ue/ue.cpp
+0
-1
No files found.
src/ue/l23/task.cpp
View file @
b9fbbf41
...
...
@@ -38,6 +38,7 @@ ue::UeL23Task::UeL23Task(TaskBase *base) : m_base{base}
m_rlsCtl
=
std
::
make_unique
<
RlsCtlLayer
>
(
base
);
m_rrc
=
std
::
make_unique
<
UeRrcLayer
>
(
base
);
m_nas
=
std
::
make_unique
<
NasLayer
>
(
base
);
m_tun
=
std
::
make_unique
<
TunLayer
>
(
base
);
}
UeL23Task
::~
UeL23Task
()
=
default
;
...
...
src/ue/l23/task.hpp
View file @
b9fbbf41
...
...
@@ -21,6 +21,7 @@
#include <ue/rls/ctl_layer.hpp>
#include <ue/rls/udp_layer.hpp>
#include <ue/rrc/layer.hpp>
#include <ue/tun/layer.hpp>
#include <ue/types.hpp>
#include <utils/common_types.hpp>
#include <utils/logger.hpp>
...
...
@@ -38,6 +39,7 @@ class UeL23Task : public NtsTask
std
::
unique_ptr
<
RlsCtlLayer
>
m_rlsCtl
;
std
::
unique_ptr
<
UeRrcLayer
>
m_rrc
;
std
::
unique_ptr
<
NasLayer
>
m_nas
;
std
::
unique_ptr
<
TunLayer
>
m_tun
;
friend
class
UeCmdHandler
;
...
...
@@ -70,6 +72,11 @@ class UeL23Task : public NtsTask
{
return
*
m_nas
;
}
inline
TunLayer
&
tun
()
{
return
*
m_tun
;
}
};
}
// namespace nr::ue
\ No newline at end of file
src/ue/nas/sm/release.cpp
View file @
b9fbbf41
...
...
@@ -11,6 +11,7 @@
#include <lib/nas/utils.hpp>
#include <optional>
#include <ue/app/task.hpp>
#include <ue/l23/task.hpp>
#include <ue/nas/mm/mm.hpp>
namespace
nr
::
ue
...
...
@@ -185,7 +186,8 @@ void NasSm::setupTunInterface(const PduSession &pduSession)
std
::
string
ipAddress
=
utils
::
OctetStringToIp
(
pduSession
.
pduAddress
->
pduAddressInformation
);
auto
allocatedName
=
m_base
->
tunLayer
->
allocate
(
pduSession
.
psi
,
ipAddress
,
m_base
->
config
->
configureRouting
,
error
);
auto
allocatedName
=
m_base
->
l23Task
->
tun
().
allocate
(
pduSession
.
psi
,
ipAddress
,
m_base
->
config
->
configureRouting
,
error
);
m_logger
->
info
(
"Connection setup for PDU session[%d] is successful, TUN interface[%s, %s] is up."
,
pduSession
.
psi
,
allocatedName
.
c_str
(),
ipAddress
.
c_str
());
...
...
src/ue/nas/sm/resource.cpp
View file @
b9fbbf41
...
...
@@ -11,6 +11,7 @@
#include <lib/nas/proto_conf.hpp>
#include <lib/nas/utils.hpp>
#include <ue/app/task.hpp>
#include <ue/l23/task.hpp>
#include <ue/nas/mm/mm.hpp>
namespace
nr
::
ue
...
...
@@ -38,7 +39,7 @@ void NasSm::localReleaseSession(int psi)
freePduSessionId
(
psi
);
if
(
isEstablished
)
m_base
->
tunLayer
->
release
(
psi
);
m_base
->
l23Task
->
tun
().
release
(
psi
);
}
void
NasSm
::
localReleaseAllSessions
()
...
...
src/ue/nas/sm/sap.cpp
View file @
b9fbbf41
...
...
@@ -79,7 +79,7 @@ void NasSm::handleDownlinkDataRequest(int psi, OctetString &&data)
state
!=
EMmSubState
::
MM_SERVICE_REQUEST_INITIATED_PS
)
return
;
m_base
->
tunLayer
->
write
(
psi
,
data
.
data
(),
static_cast
<
size_t
>
(
data
.
length
()));
m_base
->
l23Task
->
tun
().
write
(
psi
,
data
.
data
(),
static_cast
<
size_t
>
(
data
.
length
()));
}
}
// namespace nr::ue
src/ue/tun/layer.cpp
View file @
b9fbbf41
...
...
@@ -37,7 +37,7 @@ static void ReceiverThread(void *args)
while
(
true
)
{
int
psi
;
size_t
s
=
base
->
tunLayer
->
read
(
buffer
,
RECEIVER_BUFFER_SIZE
,
psi
);
size_t
s
=
base
->
l23Task
->
tun
().
read
(
buffer
,
RECEIVER_BUFFER_SIZE
,
psi
);
if
(
s
>
0
)
{
...
...
src/ue/types.hpp
View file @
b9fbbf41
...
...
@@ -33,9 +33,7 @@ namespace nr::ue
class
UeAppTask
;
class
UeL23Task
;
class
UeRlsTask
;
class
UserEquipment
;
class
TunLayer
;
struct
UeCellDesc
{
...
...
@@ -201,7 +199,6 @@ struct TaskBase
UeAppTask
*
appTask
{};
UeL23Task
*
l23Task
{};
TunLayer
*
tunLayer
{};
};
struct
RrcTimers
...
...
src/ue/ue.cpp
View file @
b9fbbf41
...
...
@@ -27,7 +27,6 @@ UserEquipment::UserEquipment(UeConfig *config, app::IUeController *ueController,
base
->
l23Task
=
new
UeL23Task
(
base
);
base
->
appTask
=
new
UeAppTask
(
base
);
base
->
tunLayer
=
new
TunLayer
(
base
);
taskBase
=
base
;
}
...
...
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