reduce cpu usage when send
This commit is contained in:
parent
a6a489498c
commit
4e5a5f0349
32
0054-reduce-cpu-usage-when-send.patch
Normal file
32
0054-reduce-cpu-usage-when-send.patch
Normal file
@ -0,0 +1,32 @@
|
||||
From d3d6f7fa6e755992fd4b75b56681b5e14aa8ba14 Mon Sep 17 00:00:00 2001
|
||||
From: jiangheng12 <jiangheng14@huawei.com>
|
||||
Date: Fri, 10 Mar 2023 19:32:48 +0800
|
||||
Subject: [PATCH] reduce cpu usage when send
|
||||
|
||||
---
|
||||
src/include/lwipsock.h | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/src/include/lwipsock.h b/src/include/lwipsock.h
|
||||
index f78c9cf..810e98f 100644
|
||||
--- a/src/include/lwipsock.h
|
||||
+++ b/src/include/lwipsock.h
|
||||
@@ -33,6 +33,7 @@
|
||||
#ifndef __LWIPSOCK_H__
|
||||
#define __LWIPSOCK_H__
|
||||
|
||||
+#include <semaphore.h>
|
||||
#include "lwip/opt.h"
|
||||
#include "lwip/api.h"
|
||||
|
||||
@@ -110,6 +111,7 @@ struct lwip_sock {
|
||||
struct list_node send_list;
|
||||
struct pbuf *send_lastdata;
|
||||
struct pbuf *send_pre_del;
|
||||
+ sem_t snd_ring_sem;
|
||||
|
||||
char pad3 __rte_cache_aligned;
|
||||
/* nerver change */
|
||||
--
|
||||
2.23.0
|
||||
|
||||
@ -4,7 +4,7 @@
|
||||
Summary: lwip is a small independent implementation of the TCP/IP protocol suite
|
||||
Name: lwip
|
||||
Version: 2.1.3
|
||||
Release: 44
|
||||
Release: 45
|
||||
License: BSD
|
||||
URL: http://savannah.nongnu.org/projects/lwip/
|
||||
Source0: http://download.savannah.nongnu.org/releases/lwip/%{name}-%{version}.zip
|
||||
@ -65,6 +65,7 @@ Patch9049: 0050-lwip-reuse-ip-port.patch
|
||||
Patch9050: 0051-lwip-add-need_tso_send.patch
|
||||
Patch9051: 0052-lwip_fnctl-only-support-F_SETFL-F_GETFL.patch
|
||||
Patch9052: 0053-cleancode-improve-lwipopts.h-readability.patch
|
||||
Patch9053: 0054-reduce-cpu-usage-when-send.patch
|
||||
|
||||
BuildRequires: gcc-c++ dos2unix dpdk-devel
|
||||
|
||||
@ -134,6 +135,7 @@ find %{_builddir}/%{name}-%{version} -type f -exec dos2unix -q {} \;
|
||||
%patch9050 -p1
|
||||
%patch9051 -p1
|
||||
%patch9052 -p1
|
||||
%patch9053 -p1
|
||||
|
||||
%build
|
||||
cd %{_builddir}/%{name}-%{version}/src
|
||||
@ -149,6 +151,9 @@ cd %{_builddir}/%{name}-%{version}/src
|
||||
%{_libdir}/liblwip.a
|
||||
|
||||
%changelog
|
||||
* Fri Mar 10 2023 jiangheng <jiangheng14@huawei.com> - 2.1.3-45
|
||||
- reduce cpu usage when send
|
||||
|
||||
* Thu Mar 9 2023 Lemmy Huang <huangliming5@huawei.com> - 2.1.3-44
|
||||
- cleancode: improve lwipopts.h readability
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user