Commit 9b20fb79 authored by aligungr's avatar aligungr

UAC implementation

parent 1a6d3c28
......@@ -73,8 +73,9 @@ bool NasMm::isInNonAllowedArea()
return false;
}
std::bitset<16> NasMm::determineAccessIdentities()
void NasMm::performUac()
{
auto accessIdentities = [this]() {
std::bitset<16> ais;
auto currentPlmn = m_base->shCtx.getCurrentPlmn();
......@@ -83,19 +84,15 @@ std::bitset<16> NasMm::determineAccessIdentities()
{
if (currentPlmn == m_base->config->hplmn || m_storage->equivalentPlmnList->contains(currentPlmn) ||
currentPlmn.mcc == m_base->config->hplmn.mcc)
{
ais[1] = true;
}
}
if (m_base->config->uacAic.mcs && m_rmState == ERmState::RM_REGISTERED && currentPlmn.hasValue())
{
if (currentPlmn == m_base->config->hplmn || m_storage->equivalentPlmnList->contains(currentPlmn) ||
currentPlmn.mcc == m_base->config->hplmn.mcc)
{
ais[2] = true;
}
}
if (m_nwFeatureSupport)
{
......@@ -124,10 +121,9 @@ std::bitset<16> NasMm::determineAccessIdentities()
ais[0] = true;
return ais;
}
}();
int NasMm::determineAccessCategory()
{
auto accessCategory = [this]() {
/* Check for Rule #1 */
if (m_procCtl.mobilityRegistration)
{
......@@ -179,6 +175,7 @@ int NasMm::determineAccessCategory()
return 7;
return 0;
}();
}
} // namespace nr::ue
......@@ -174,8 +174,7 @@ class NasMm
bool hasEmergency();
void setN1Capability(bool enabled);
bool isInNonAllowedArea();
std::bitset<16> determineAccessIdentities();
int determineAccessCategory();
void performUac();
private: /* eCall */
bool startECallInactivityIfNeeded();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment