MME2 changes - Propped commits from openmme/paging branch. Added scripts
for code gen
Change-Id: Ie55032217232214ac8544ca76ea34335205329e4
diff --git a/src/s6a/handlers/hss_message_delegator.c b/src/s6a/handlers/hss_message_delegator.c
new file mode 100644
index 0000000..ab7d9a0
--- /dev/null
+++ b/src/s6a/handlers/hss_message_delegator.c
@@ -0,0 +1,72 @@
+/*
+ * Copyright (c) 2003-2018, Great Software Laboratory Pvt. Ltd.
+ * Copyright (c) 2017 Intel Corporation
+ * Copyright (c) 2019, Infosys Ltd.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <arpa/inet.h>
+#include <unistd.h>
+#include <string.h>
+#include <pthread.h>
+
+#include "log.h"
+#include "hss_message.h"
+#include "s6a.h"
+
+/**Global and externs **/
+
+/*Handle all messages coming from in built perf hss*/
+void
+hss_resp_handler(void *message)
+{
+ struct hss_resp_msg *msg = (struct hss_resp_msg*)message;
+
+ log_msg(LOG_INFO, "HSS response msg handler for ue_idx %d\n",
+ msg->ue_idx);
+
+ switch(msg->hdr){
+ case HSS_AIA_MSG:
+ handle_perf_hss_aia(msg->ue_idx,
+ (struct hss_aia_msg *)&(msg->data.aia));
+ break;
+
+ case HSS_ULA_MSG:
+ handle_perf_hss_ula(msg->ue_idx,
+ (struct hss_ula_msg *)&(msg->data.ula));
+ break;
+#if 0
+ case HSS_PURGE_RESP_MSG:
+ handle_perf_hss_purge_resp(msg->ue_idx);
+ break;
+#endif
+ //NI Detach
+ case HSS_CLR_MSG:
+ log_msg(LOG_INFO,"clr msg from TC\n");
+ handle_perf_hss_clr(msg->ue_idx,
+ (struct hss_clr_msg *)&(msg->data.clr));
+ break;
+
+ default:
+ log_msg(LOG_ERROR, "Unknown message received from HSS - %d\n",
+ msg->hdr);
+ }
+ return;
+
+ /*free allocated message buffer*/
+ free(message);
+}