aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/framework/common/base/liblinuxapi/nsfw_lock_file.c2
-rw-r--r--src/framework/include/nsfw_mgr_com_api.h1
-rw-r--r--src/framework/ipc/mgr_com/mgr_com.c1
-rw-r--r--stacks/lwip_stack/CMakeLists.txt2
-rw-r--r--stacks/lwip_stack/lwip_src/api/spl_api_msg.c8
-rw-r--r--stacks/lwip_stack/lwip_src/common/stackx_common_opt.h1
-rw-r--r--stacks/lwip_stack/lwip_src/common/stackx_spl_msg.h2
-rw-r--r--stacks/lwip_stack/lwip_src/socket/stackx_tcp.c1
-rwxr-xr-x[-rw-r--r--]stacks/lwip_stack/release/script/nstack_var.sh0
-rwxr-xr-x[-rw-r--r--]stacks/lwip_stack/release/script/run_nstack_main.sh0
-rwxr-xr-x[-rw-r--r--]stacks/lwip_stack/release/script/run_nstack_master.sh0
-rwxr-xr-x[-rw-r--r--]stacks/lwip_stack/release/send_alarm.sh0
-rwxr-xr-x[-rw-r--r--]stacks/lwip_stack/release/start_nstack.sh0
-rwxr-xr-x[-rw-r--r--]stacks/lwip_stack/release/stop_nstack.sh0
-rwxr-xr-x[-rw-r--r--]stacks/lwip_stack/release/uninstall.sh0
15 files changed, 14 insertions, 4 deletions
diff --git a/src/framework/common/base/liblinuxapi/nsfw_lock_file.c b/src/framework/common/base/liblinuxapi/nsfw_lock_file.c
index abfbfd1..cef8d95 100644
--- a/src/framework/common/base/liblinuxapi/nsfw_lock_file.c
+++ b/src/framework/common/base/liblinuxapi/nsfw_lock_file.c
@@ -94,6 +94,8 @@ nsfw_proc_start_with_lock (u8 proc_type)
return -1;
}
+ nsfw_mgr_com_mkdir_domainpath (lock_fpath);
+
ret = STRCAT_S (lock_fpath, NSFW_FILE_PATH_LEN, module_name);
if (EOK != ret)
{
diff --git a/src/framework/include/nsfw_mgr_com_api.h b/src/framework/include/nsfw_mgr_com_api.h
index 56ec08f..9bbcaca 100644
--- a/src/framework/include/nsfw_mgr_com_api.h
+++ b/src/framework/include/nsfw_mgr_com_api.h
@@ -186,6 +186,7 @@ extern int nsfw_mgr_run_script (const char *cmd, char *result,
extern int nsfw_mgr_com_chk_hbt (int v_add);
extern i32 nsfw_set_close_on_exec (i32 sock);
extern int nsfw_mgr_comm_fd_init (u32 proc_type);
+extern void nsfw_mgr_com_mkdir_domainpath (char *pathname);
#ifdef __cplusplus
/* *INDENT-OFF* */
diff --git a/src/framework/ipc/mgr_com/mgr_com.c b/src/framework/ipc/mgr_com/mgr_com.c
index 2fb9789..a2998fa 100644
--- a/src/framework/ipc/mgr_com/mgr_com.c
+++ b/src/framework/ipc/mgr_com/mgr_com.c
@@ -1828,7 +1828,6 @@ nsfw_mgr_comm_fd_init (u32 proc_type)
* Calls :
* Called By :
*****************************************************************************/
-void nsfw_mgr_com_mkdir_domainpath (char *pathname);
void
nsfw_mgr_com_mkdir_domainpath (char *pathname)
{
diff --git a/stacks/lwip_stack/CMakeLists.txt b/stacks/lwip_stack/CMakeLists.txt
index 297d2d9..3992f20 100644
--- a/stacks/lwip_stack/CMakeLists.txt
+++ b/stacks/lwip_stack/CMakeLists.txt
@@ -48,8 +48,6 @@ FILE(WRITE ${post_compile} "#!/bin/bash\n")
FILE(APPEND ${post_compile}
"
-find ${CMAKE_CURRENT_LIST_DIR}/release/ -name \"*.sh\" -exec chmod +x {} \\;
-find ${CMAKE_CURRENT_LIST_DIR}/release/ -name \"*.py\" -exec chmod +x {} \\;
ln -sfn ./run_nstack_main.sh ${CMAKE_CURRENT_LIST_DIR}/release/script/run_nstack.sh
echo post compile process success.
"
diff --git a/stacks/lwip_stack/lwip_src/api/spl_api_msg.c b/stacks/lwip_stack/lwip_src/api/spl_api_msg.c
index 1c9bf92..d8e088a 100644
--- a/stacks/lwip_stack/lwip_src/api/spl_api_msg.c
+++ b/stacks/lwip_stack/lwip_src/api/spl_api_msg.c
@@ -22,6 +22,7 @@
//#include "sockets.h"
#include <netinet/in.h>
#include <errno.h>
+#include <netinet/tcp.h>
#include "stackx_prot_com.h"
#include "spl_api.h"
@@ -2523,7 +2524,12 @@ do_get_tcpproto_getsockopt_internal (struct common_pcb *cpcb,
NSPOL_LOGDBG (SOCKETS_DEBUG, "]fd=%d,SPL_TCP_KEEPCNT=%d",
cpcb->socket, *(int *) optval);
break;
-
+ case SPL_TCP_INFO:
+ ((struct tcp_info *) optval)->tcpi_total_retrans = (int) tpcb->nrtx;
+ ((struct tcp_info *) optval)->tcpi_snd_mss = (int) tpcb->mss;
+ ((struct tcp_info *) optval)->tcpi_rtt = (int) tpcb->sa;
+ ((struct tcp_info *) optval)->tcpi_snd_cwnd = (int) tpcb->cwnd;
+ break;
default:
NSPOL_LOGDBG (SOCKETS_DEBUG, "unsupported]optname=%d", optname);
SET_MSG_ERR (m, EOPNOTSUPP);
diff --git a/stacks/lwip_stack/lwip_src/common/stackx_common_opt.h b/stacks/lwip_stack/lwip_src/common/stackx_common_opt.h
index d2d01e5..feccc3f 100644
--- a/stacks/lwip_stack/lwip_src/common/stackx_common_opt.h
+++ b/stacks/lwip_stack/lwip_src/common/stackx_common_opt.h
@@ -102,6 +102,7 @@ extern "C" {
#define SPL_TCP_KEEPCNT 0x06
#define SPL_TCP_LINGER2 0x08
#define SPL_TCP_DEFER_ACCEPT 0x09
+#define SPL_TCP_INFO 0x0B
typedef enum spl_netconn_type
{
diff --git a/stacks/lwip_stack/lwip_src/common/stackx_spl_msg.h b/stacks/lwip_stack/lwip_src/common/stackx_spl_msg.h
index 119c26a..3088150 100644
--- a/stacks/lwip_stack/lwip_src/common/stackx_spl_msg.h
+++ b/stacks/lwip_stack/lwip_src/common/stackx_spl_msg.h
@@ -21,6 +21,7 @@
#include "stackx_spl_share.h"
#include "stackx_common_opt.h"
#include <sys/socket.h>
+#include <netinet/tcp.h>
#ifdef __cplusplus
/* *INDENT-OFF* */
@@ -207,6 +208,7 @@ typedef struct
//struct in_addr inaddr_optval;
//struct linger _linger;
struct timeval timeval_optval;
+ struct tcp_info tpinfo;
//ipmreq ipmreq_optval; //Multicast support later
} optval;
diff --git a/stacks/lwip_stack/lwip_src/socket/stackx_tcp.c b/stacks/lwip_stack/lwip_src/socket/stackx_tcp.c
index 3225c2f..0042e54 100644
--- a/stacks/lwip_stack/lwip_src/socket/stackx_tcp.c
+++ b/stacks/lwip_stack/lwip_src/socket/stackx_tcp.c
@@ -498,6 +498,7 @@ sbr_getsockopt_ipproto_tcp (int optname, void *optval, socklen_t optlen)
case SPL_TCP_KEEPIDLE:
case SPL_TCP_KEEPINTVL:
case SPL_TCP_KEEPCNT:
+ case SPL_TCP_INFO:
break;
default:
err = ENOPROTOOPT;
diff --git a/stacks/lwip_stack/release/script/nstack_var.sh b/stacks/lwip_stack/release/script/nstack_var.sh
index 9a1c612..9a1c612 100644..100755
--- a/stacks/lwip_stack/release/script/nstack_var.sh
+++ b/stacks/lwip_stack/release/script/nstack_var.sh
diff --git a/stacks/lwip_stack/release/script/run_nstack_main.sh b/stacks/lwip_stack/release/script/run_nstack_main.sh
index 2bd9e0d..2bd9e0d 100644..100755
--- a/stacks/lwip_stack/release/script/run_nstack_main.sh
+++ b/stacks/lwip_stack/release/script/run_nstack_main.sh
diff --git a/stacks/lwip_stack/release/script/run_nstack_master.sh b/stacks/lwip_stack/release/script/run_nstack_master.sh
index 8da0d49..8da0d49 100644..100755
--- a/stacks/lwip_stack/release/script/run_nstack_master.sh
+++ b/stacks/lwip_stack/release/script/run_nstack_master.sh
diff --git a/stacks/lwip_stack/release/send_alarm.sh b/stacks/lwip_stack/release/send_alarm.sh
index 46ea413..46ea413 100644..100755
--- a/stacks/lwip_stack/release/send_alarm.sh
+++ b/stacks/lwip_stack/release/send_alarm.sh
diff --git a/stacks/lwip_stack/release/start_nstack.sh b/stacks/lwip_stack/release/start_nstack.sh
index db0c084..db0c084 100644..100755
--- a/stacks/lwip_stack/release/start_nstack.sh
+++ b/stacks/lwip_stack/release/start_nstack.sh
diff --git a/stacks/lwip_stack/release/stop_nstack.sh b/stacks/lwip_stack/release/stop_nstack.sh
index 48d1af7..48d1af7 100644..100755
--- a/stacks/lwip_stack/release/stop_nstack.sh
+++ b/stacks/lwip_stack/release/stop_nstack.sh
diff --git a/stacks/lwip_stack/release/uninstall.sh b/stacks/lwip_stack/release/uninstall.sh
index 92ae5fe..92ae5fe 100644..100755
--- a/stacks/lwip_stack/release/uninstall.sh
+++ b/stacks/lwip_stack/release/uninstall.sh