From 067f6e7a38305b72f0574fc9d47cc0bda0e5f4b9 Mon Sep 17 00:00:00 2001 From: Robert Schmidt <robert.schmidt@eurecom.fr> Date: Wed, 4 Jul 2018 15:21:34 +0200 Subject: [PATCH] NNSF by GUMMEI: do not use highest capacity --- openair3/S1AP/s1ap_eNB_nnsf.c | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git a/openair3/S1AP/s1ap_eNB_nnsf.c b/openair3/S1AP/s1ap_eNB_nnsf.c index a3fa634db1..0d5519149c 100644 --- a/openair3/S1AP/s1ap_eNB_nnsf.c +++ b/openair3/S1AP/s1ap_eNB_nnsf.c @@ -173,8 +173,6 @@ s1ap_eNB_nnsf_select_mme_by_gummei(s1ap_eNB_instance_t *instance_p, s1ap_gummei_t gummei) { struct s1ap_eNB_mme_data_s *mme_data_p = NULL; - struct s1ap_eNB_mme_data_s *mme_highest_capacity_p = NULL; - uint8_t current_capacity = 0; RB_FOREACH(mme_data_p, s1ap_mme_map, &instance_p->s1ap_mme_head) { struct served_gummei_s *gummei_p = NULL; @@ -213,12 +211,6 @@ s1ap_eNB_nnsf_select_mme_by_gummei(s1ap_eNB_instance_t *instance_p, } } - if (current_capacity < mme_data_p->relative_mme_capacity) { - /* We find a better MME, keep a reference to it */ - current_capacity = mme_data_p->relative_mme_capacity; - mme_highest_capacity_p = mme_data_p; - } - /* Looking for MME gummei matching the one provided by NAS */ STAILQ_FOREACH(gummei_p, &mme_data_p->served_gummei, next) { struct served_group_id_s *group_id_p = NULL; @@ -254,10 +246,8 @@ s1ap_eNB_nnsf_select_mme_by_gummei(s1ap_eNB_instance_t *instance_p, } } - /* At this point no MME matches the provided GUMMEI. Select the one with the - * highest relative capacity. - * In case the list of known MME is empty, simply return NULL, that way the RRC - * layer should know about it and reject RRC connectivity. - */ - return mme_highest_capacity_p; + /* At this point no MME matches the provided GUMMEI. In this case, return + * NULL. That way the RRC layer should know about it and reject RRC + * connectivity. */ + return NULL; } -- GitLab