1 Star 0 Fork 32

compile_success/gazelle_3

forked from src-openEuler/gazelle 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
0215-cleancode-rename-gazelle-files-in-lwip.patch 14.95 KB
一键复制 编辑 原始数据 按行查看 历史
From 8ce0711285aaa897b08cf894e2908fef9fffe112 Mon Sep 17 00:00:00 2001
From: Lemmy Huang <huangliming5@huawei.com>
Date: Tue, 9 Jul 2024 21:52:51 +0800
Subject: [PATCH] cleancode: rename gazelle files in lwip
Signed-off-by: Lemmy Huang <huangliming5@huawei.com>
---
src/common/gazelle_dfx_msg.h | 2 +-
src/lstack/api/lstack_epoll.c | 6 +++---
src/lstack/api/lstack_fork.c | 2 +-
src/lstack/api/lstack_rtc_api.c | 4 ++--
src/lstack/api/lstack_rtw_api.c | 2 +-
src/lstack/api/lstack_signal.c | 4 ++--
src/lstack/api/lstack_wrap.c | 4 ++--
src/lstack/core/lstack_cfg.c | 4 ++--
src/lstack/core/lstack_control_plane.c | 4 ++--
src/lstack/core/lstack_dpdk.c | 4 ++--
src/lstack/core/lstack_init.c | 6 +++---
src/lstack/core/lstack_lwip.c | 4 ++--
src/lstack/core/lstack_preload.c | 4 ++--
src/lstack/core/lstack_protocol_stack.c | 6 +++---
src/lstack/core/lstack_stack_stat.c | 4 ++--
src/lstack/core/lstack_thread_rpc.c | 2 +-
src/lstack/core/lstack_virtio.c | 2 +-
src/lstack/include/lstack_dpdk.h | 2 +-
src/lstack/include/lstack_protocol_stack.h | 2 +-
src/lstack/include/posix/lstack_epoll.h | 2 +-
src/lstack/netif/lstack_ethdev.c | 2 +-
src/lstack/netif/lstack_fault_inject.c | 2 +-
src/lstack/netif/lstack_flow.c | 2 +-
src/lstack/netif/lstack_vdev.c | 4 ++--
src/ltran/ltran_instance.h | 2 +-
src/ltran/ltran_stack.h | 2 +-
src/ltran/ltran_tcp_conn.h | 4 ++--
src/ltran/ltran_tcp_sock.c | 2 +-
src/ltran/ltran_tcp_sock.h | 2 +-
src/ltran/ltran_timer.c | 2 +-
30 files changed, 47 insertions(+), 47 deletions(-)
diff --git a/src/common/gazelle_dfx_msg.h b/src/common/gazelle_dfx_msg.h
index 57bf631..a2ec07b 100644
--- a/src/common/gazelle_dfx_msg.h
+++ b/src/common/gazelle_dfx_msg.h
@@ -16,7 +16,7 @@
#include <sys/types.h>
#include <stdint.h>
-#include <lwip/reg_sock.h>
+#include <lwip/lwipgz_flow.h>
#ifdef GAZELLE_FAULT_INJECT_ENABLE
#include "gazelle_fault_inject_common.h"
diff --git a/src/lstack/api/lstack_epoll.c b/src/lstack/api/lstack_epoll.c
index 9c0aef7..7d00de7 100644
--- a/src/lstack/api/lstack_epoll.c
+++ b/src/lstack/api/lstack_epoll.c
@@ -19,13 +19,13 @@
#include <stdatomic.h>
#include <pthread.h>
-#include <lwip/lwipsock.h>
+#include <lwip/lwipgz_sock.h>
#include <lwip/sockets.h>
-#include <lwip/eventpoll.h>
+#include <lwip/lwipgz_event.h>
#include <lwip/api.h>
#include <lwip/tcp.h>
#include <lwip/timeouts.h>
-#include <lwip/posix_api.h>
+#include <lwip/lwipgz_posix_api.h>
#include "lstack_ethdev.h"
#include "lstack_stack_stat.h"
diff --git a/src/lstack/api/lstack_fork.c b/src/lstack/api/lstack_fork.c
index 43c212b..5cddee2 100644
--- a/src/lstack/api/lstack_fork.c
+++ b/src/lstack/api/lstack_fork.c
@@ -13,7 +13,7 @@
#include <sys/socket.h>
#include <unistd.h>
-#include <lwip/posix_api.h>
+#include <lwip/lwipgz_posix_api.h>
pid_t lstack_fork(void)
{
diff --git a/src/lstack/api/lstack_rtc_api.c b/src/lstack/api/lstack_rtc_api.c
index 18664ca..e77edec 100644
--- a/src/lstack/api/lstack_rtc_api.c
+++ b/src/lstack/api/lstack_rtc_api.c
@@ -14,8 +14,8 @@
#include <sys/epoll.h>
#include <sys/socket.h>
#include <unistd.h>
-#include <lwip/posix_api.h>
-#include <lwip/lwipsock.h>
+#include <lwip/lwipgz_posix_api.h>
+#include <lwip/lwipgz_sock.h>
#include "posix/lstack_epoll.h"
#include "lstack_log.h"
#include "lstack_cfg.h"
diff --git a/src/lstack/api/lstack_rtw_api.c b/src/lstack/api/lstack_rtw_api.c
index e43be59..0f23ffd 100644
--- a/src/lstack/api/lstack_rtw_api.c
+++ b/src/lstack/api/lstack_rtw_api.c
@@ -15,7 +15,7 @@
#include <sys/socket.h>
#include <unistd.h>
-#include <lwip/lwipsock.h>
+#include <lwip/lwipgz_sock.h>
#include "lstack_thread_rpc.h"
#include "posix/lstack_epoll.h"
diff --git a/src/lstack/api/lstack_signal.c b/src/lstack/api/lstack_signal.c
index 3dd5d03..9d0431b 100644
--- a/src/lstack/api/lstack_signal.c
+++ b/src/lstack/api/lstack_signal.c
@@ -15,8 +15,8 @@
#include <sys/socket.h>
#include <execinfo.h>
#include <unistd.h>
-#include <lwip/lwipsock.h>
-#include <lwip/posix_api.h>
+#include <lwip/lwipgz_sock.h>
+#include <lwip/lwipgz_posix_api.h>
#include "common/gazelle_base_func.h"
#include "lstack_cfg.h"
diff --git a/src/lstack/api/lstack_wrap.c b/src/lstack/api/lstack_wrap.c
index 3a60cbb..cf0d302 100644
--- a/src/lstack/api/lstack_wrap.c
+++ b/src/lstack/api/lstack_wrap.c
@@ -22,8 +22,8 @@
#include <net/if.h>
#include <securec.h>
-#include <lwip/posix_api.h>
-#include <lwip/lwipsock.h>
+#include <lwip/lwipgz_posix_api.h>
+#include <lwip/lwipgz_sock.h>
#include <lwip/tcp.h>
#include "posix/lstack_unistd.h"
diff --git a/src/lstack/core/lstack_cfg.c b/src/lstack/core/lstack_cfg.c
index 4bc4217..a1f6c2f 100644
--- a/src/lstack/core/lstack_cfg.c
+++ b/src/lstack/core/lstack_cfg.c
@@ -24,8 +24,8 @@
#include <sched.h>
#include <rte_eth_bond.h>
-#include <lwip/lwipsock.h>
-#include <lwip/posix_api.h>
+#include <lwip/lwipgz_sock.h>
+#include <lwip/lwipgz_posix_api.h>
#include <lwip/inet.h>
#include "common/gazelle_reg_msg.h"
diff --git a/src/lstack/core/lstack_control_plane.c b/src/lstack/core/lstack_control_plane.c
index 4ab12f6..5545b9f 100644
--- a/src/lstack/core/lstack_control_plane.c
+++ b/src/lstack/core/lstack_control_plane.c
@@ -21,8 +21,8 @@
#include <lwip/tcp.h>
#include <rte_eal.h>
#include <rte_errno.h>
-#include <lwip/posix_api.h>
-#include <lwip/reg_sock.h>
+#include <lwip/lwipgz_posix_api.h>
+#include <lwip/lwipgz_flow.h>
#include "lstack_cfg.h"
#include "lstack_dpdk.h"
diff --git a/src/lstack/core/lstack_dpdk.c b/src/lstack/core/lstack_dpdk.c
index 583bb09..a095cbd 100644
--- a/src/lstack/core/lstack_dpdk.c
+++ b/src/lstack/core/lstack_dpdk.c
@@ -32,10 +32,10 @@
#endif
#include <rte_pdump.h>
#include <rte_thash.h>
-#include <lwip/posix_api.h>
+#include <lwip/lwipgz_posix_api.h>
#include <lwipopts.h>
#include <lwip/pbuf.h>
-#include <lwip/reg_sock.h>
+#include <lwip/lwipgz_flow.h>
#include <lwip/priv/tcp_priv.h>
#include <rte_eth_bond_8023ad.h>
diff --git a/src/lstack/core/lstack_init.c b/src/lstack/core/lstack_init.c
index d97b218..a5a4a4e 100644
--- a/src/lstack/core/lstack_init.c
+++ b/src/lstack/core/lstack_init.c
@@ -28,11 +28,11 @@
#include <lwip/def.h>
#include <lwip/init.h>
-#include <lwip/lwipsock.h>
+#include <lwip/lwipgz_sock.h>
#include <lwip/tcpip.h>
-#include <lwip/memp_def.h>
+#include <lwip/lwipgz_memp.h>
#include <lwip/lwipopts.h>
-#include <lwip/posix_api.h>
+#include <lwip/lwipgz_posix_api.h>
#include "lstack_cfg.h"
#include "lstack_control_plane.h"
diff --git a/src/lstack/core/lstack_lwip.c b/src/lstack/core/lstack_lwip.c
index 6e50e4d..75ef5f6 100644
--- a/src/lstack/core/lstack_lwip.c
+++ b/src/lstack/core/lstack_lwip.c
@@ -15,11 +15,11 @@
#include <lwip/sockets.h>
#include <lwip/tcp.h>
#include <lwip/udp.h>
-#include <lwipsock.h>
+#include <lwipgz_sock.h>
#include <arch/sys_arch.h>
#include <lwip/pbuf.h>
#include <lwip/priv/tcp_priv.h>
-#include <lwip/posix_api.h>
+#include <lwip/lwipgz_posix_api.h>
#include <lwip/api.h>
#include <lwip/tcp.h>
#include <lwip/prot/etharp.h>
diff --git a/src/lstack/core/lstack_preload.c b/src/lstack/core/lstack_preload.c
index f7caef5..0974e9e 100644
--- a/src/lstack/core/lstack_preload.c
+++ b/src/lstack/core/lstack_preload.c
@@ -15,8 +15,8 @@
#include <pthread.h>
#include <securec.h>
-#include <lwip/posix_api.h>
-#include <lwip/lwipsock.h>
+#include <lwip/lwipgz_posix_api.h>
+#include <lwip/lwipgz_sock.h>
#include <lwip/lwipopts.h>
#include "lstack_log.h"
diff --git a/src/lstack/core/lstack_protocol_stack.c b/src/lstack/core/lstack_protocol_stack.c
index 1983c0b..d8bdd3c 100644
--- a/src/lstack/core/lstack_protocol_stack.c
+++ b/src/lstack/core/lstack_protocol_stack.c
@@ -16,9 +16,9 @@
#include <lwip/sockets.h>
#include <lwip/tcpip.h>
#include <lwip/tcp.h>
-#include <lwip/memp_def.h>
-#include <lwipsock.h>
-#include <lwip/posix_api.h>
+#include <lwip/lwipgz_memp.h>
+#include <lwipgz_sock.h>
+#include <lwip/lwipgz_posix_api.h>
#include <securec.h>
#include <numa.h>
diff --git a/src/lstack/core/lstack_stack_stat.c b/src/lstack/core/lstack_stack_stat.c
index 423be81..e77f21a 100644
--- a/src/lstack/core/lstack_stack_stat.c
+++ b/src/lstack/core/lstack_stack_stat.c
@@ -15,11 +15,11 @@
#include <sys/un.h>
#include <sys/socket.h>
#include <lwip/api.h>
-#include <lwip/lwipsock.h>
+#include <lwip/lwipgz_sock.h>
+#include <lwip/lwipgz_posix_api.h>
#include "lstack_cfg.h"
#include "lstack_ethdev.h"
-#include "posix_api.h"
#include "lstack_control_plane.h"
#include "lstack_log.h"
#include "common/dpdk_common.h"
diff --git a/src/lstack/core/lstack_thread_rpc.c b/src/lstack/core/lstack_thread_rpc.c
index e438c37..a6d2dbf 100644
--- a/src/lstack/core/lstack_thread_rpc.c
+++ b/src/lstack/core/lstack_thread_rpc.c
@@ -10,7 +10,7 @@
* See the Mulan PSL v2 for more details.
*/
#include <lwip/sockets.h>
-#include <lwip/lwipsock.h>
+#include <lwip/lwipgz_sock.h>
#include <rte_mempool.h>
#include "lstack_log.h"
diff --git a/src/lstack/core/lstack_virtio.c b/src/lstack/core/lstack_virtio.c
index bc42bb9..36159c9 100644
--- a/src/lstack/core/lstack_virtio.c
+++ b/src/lstack/core/lstack_virtio.c
@@ -13,7 +13,7 @@
#include <sys/ioctl.h>
#include <sys/socket.h>
#include <net/if.h>
-#include <lwip/posix_api.h>
+#include <lwip/lwipgz_posix_api.h>
#include <linux/ipv6.h>
#include "lstack_cfg.h"
#include "lstack_log.h"
diff --git a/src/lstack/include/lstack_dpdk.h b/src/lstack/include/lstack_dpdk.h
index 91af3c5..d058409 100644
--- a/src/lstack/include/lstack_dpdk.h
+++ b/src/lstack/include/lstack_dpdk.h
@@ -13,7 +13,7 @@
#ifndef _GAZELLE_DPDK_H_
#define _GAZELLE_DPDK_H_
-#include <lwip/reg_sock.h>
+#include <lwip/lwipgz_flow.h>
#include "common/gazelle_opt.h"
#include "common/gazelle_dfx_msg.h"
diff --git a/src/lstack/include/lstack_protocol_stack.h b/src/lstack/include/lstack_protocol_stack.h
index 5b04c6d..7dce757 100644
--- a/src/lstack/include/lstack_protocol_stack.h
+++ b/src/lstack/include/lstack_protocol_stack.h
@@ -17,7 +17,7 @@
#include <sys/epoll.h>
#include <stdbool.h>
-#include <lwip/list.h>
+#include <lwip/lwipgz_list.h>
#include <lwip/netif.h>
#include "common/gazelle_opt.h"
diff --git a/src/lstack/include/posix/lstack_epoll.h b/src/lstack/include/posix/lstack_epoll.h
index 77b6ebb..6e02615 100644
--- a/src/lstack/include/posix/lstack_epoll.h
+++ b/src/lstack/include/posix/lstack_epoll.h
@@ -18,7 +18,7 @@
#include <semaphore.h>
#include <pthread.h>
-#include <lwip/list.h>
+#include <lwip/lwipgz_list.h>
#include "common/gazelle_dfx_msg.h"
#include "common/gazelle_opt.h"
diff --git a/src/lstack/netif/lstack_ethdev.c b/src/lstack/netif/lstack_ethdev.c
index e23d313..5685d11 100644
--- a/src/lstack/netif/lstack_ethdev.c
+++ b/src/lstack/netif/lstack_ethdev.c
@@ -19,7 +19,7 @@
#include <lwip/etharp.h>
#include <lwip/ethip6.h>
-#include <lwip/posix_api.h>
+#include <lwip/lwipgz_posix_api.h>
#include <netif/ethernet.h>
#include <securec.h>
diff --git a/src/lstack/netif/lstack_fault_inject.c b/src/lstack/netif/lstack_fault_inject.c
index 4736e29..9fae745 100644
--- a/src/lstack/netif/lstack_fault_inject.c
+++ b/src/lstack/netif/lstack_fault_inject.c
@@ -14,7 +14,7 @@
#include <rte_gro.h>
#include <rte_net.h>
-#include <lwip/posix_api.h>
+#include <lwip/lwipgz_posix_api.h>
#include "lstack_cfg.h"
#include "lstack_log.h"
diff --git a/src/lstack/netif/lstack_flow.c b/src/lstack/netif/lstack_flow.c
index 84497dc..84c5c61 100644
--- a/src/lstack/netif/lstack_flow.c
+++ b/src/lstack/netif/lstack_flow.c
@@ -18,7 +18,7 @@
#include <rte_jhash.h>
#include <uthash.h>
-#include <lwip/posix_api.h>
+#include <lwip/lwipgz_posix_api.h>
#include <lwip/tcp.h>
#include <lwip/prot/tcp.h>
diff --git a/src/lstack/netif/lstack_vdev.c b/src/lstack/netif/lstack_vdev.c
index 63f9e40..a590b30 100644
--- a/src/lstack/netif/lstack_vdev.c
+++ b/src/lstack/netif/lstack_vdev.c
@@ -14,7 +14,7 @@
#include <lwip/memp.h>
#include <lwip/lwipopts.h>
#include <lwip/sys.h>
-#include <lwip/reg_sock.h>
+#include <lwip/lwipgz_flow.h>
#include <rte_ring.h>
#include <rte_malloc.h>
#include <rte_ethdev.h>
@@ -201,7 +201,7 @@ int32_t vdev_reg_xmit(enum reg_ring_type type, struct gazelle_quintuple *qtuple)
uint16_t local_port = ntohs(qtuple->src_port);
if (get_global_cfg_params()->flow_bifurcation && get_global_cfg_params()->is_primary) {
- if (type == REG_RING_TCP_LISTEN_CLOSE || type == REG_RING_UDP_BIND_CLOSE) { // add enum type in reg_sock.h
+ if (type == REG_RING_TCP_LISTEN_CLOSE || type == REG_RING_UDP_BIND_CLOSE) { // add enum type in lwipgz_flow.h
port_map_mod(local_port, 0);
} else if (type == REG_RING_TCP_LISTEN || type == REG_RING_UDP_BIND) {
port_map_mod(local_port, 1);
diff --git a/src/ltran/ltran_instance.h b/src/ltran/ltran_instance.h
index f0fe580..9cb6d31 100644
--- a/src/ltran/ltran_instance.h
+++ b/src/ltran/ltran_instance.h
@@ -13,7 +13,7 @@
#ifndef __GAZELLE_INSTANCE_H__
#define __GAZELLE_INSTANCE_H__
-#include <lwip/hlist.h>
+#include <lwip/lwipgz_hlist.h>
#include <netinet/in.h>
#include <limits.h>
diff --git a/src/ltran/ltran_stack.h b/src/ltran/ltran_stack.h
index 693bb33..7dd1cb1 100644
--- a/src/ltran/ltran_stack.h
+++ b/src/ltran/ltran_stack.h
@@ -13,7 +13,7 @@
#ifndef __GAZELLE_STACK_H__
#define __GAZELLE_STACK_H__
-#include <lwip/hlist.h>
+#include <lwip/lwipgz_hlist.h>
#include "ltran_stat.h"
diff --git a/src/ltran/ltran_tcp_conn.h b/src/ltran/ltran_tcp_conn.h
index 82c5faf..87491de 100644
--- a/src/ltran/ltran_tcp_conn.h
+++ b/src/ltran/ltran_tcp_conn.h
@@ -13,10 +13,10 @@
#ifndef __GAZELLE_TCP_CONN_H__
#define __GAZELLE_TCP_CONN_H__
-#include <lwip/hlist.h>
+#include <lwip/lwipgz_hlist.h>
#include <stdint.h>
#include <stdbool.h>
-#include <lwip/reg_sock.h>
+#include <lwip/lwipgz_flow.h>
#include "common/gazelle_opt.h"
diff --git a/src/ltran/ltran_tcp_sock.c b/src/ltran/ltran_tcp_sock.c
index 4044fc0..eef2821 100644
--- a/src/ltran/ltran_tcp_sock.c
+++ b/src/ltran/ltran_tcp_sock.c
@@ -12,7 +12,7 @@
#include <stdlib.h>
-#include <lwip/hlist.h>
+#include <lwip/lwipgz_hlist.h>
#include "ltran_tcp_conn.h"
#include "ltran_instance.h"
diff --git a/src/ltran/ltran_tcp_sock.h b/src/ltran/ltran_tcp_sock.h
index e40891d..6ca97ec 100644
--- a/src/ltran/ltran_tcp_sock.h
+++ b/src/ltran/ltran_tcp_sock.h
@@ -13,7 +13,7 @@
#ifndef __GAZELLE_TCP_SOCK_H__
#define __GAZELLE_TCP_SOCK_H__
-#include <lwip/hlist.h>
+#include <lwip/lwipgz_hlist.h>
#include <pthread.h>
#include <stdint.h>
diff --git a/src/ltran/ltran_timer.c b/src/ltran/ltran_timer.c
index 0832c5f..87046cb 100644
--- a/src/ltran/ltran_timer.c
+++ b/src/ltran/ltran_timer.c
@@ -17,7 +17,7 @@
#include <rte_malloc.h>
#include <rte_errno.h>
#include <rte_cycles.h>
-#include <lwip/hlist.h>
+#include <lwip/lwipgz_hlist.h>
#include "ltran_param.h"
#include "ltran_log.h"
--
2.33.0
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/compile_success/gazelle_3.git
git@gitee.com:compile_success/gazelle_3.git
compile_success
gazelle_3
gazelle_3
master

搜索帮助

0d507c66 1850385 C8b1a773 1850385