sync move select_thread_path after posix_api_init
(cherry picked from commit 4a34a374cf09b03d2f0ab5ff5c70818165e38f66)
This commit is contained in:
parent
90cdb74002
commit
399202e307
43
0157-move-select_thread_path-after-posix_api_init.patch
Normal file
43
0157-move-select_thread_path-after-posix_api_init.patch
Normal file
@ -0,0 +1,43 @@
|
||||
From bd238ab678150c216d672409a5ddb4b7dd778fec Mon Sep 17 00:00:00 2001
|
||||
From: kircher <majun65@huawei.com>
|
||||
Date: Fri, 16 Dec 2022 16:53:21 +0800
|
||||
Subject: [PATCH] move select_thread_path after posix_api_init
|
||||
|
||||
---
|
||||
src/lstack/api/lstack_wrap.c | 13 ++++++++-----
|
||||
1 file changed, 8 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/src/lstack/api/lstack_wrap.c b/src/lstack/api/lstack_wrap.c
|
||||
index 2eeda6b..d976f74 100644
|
||||
--- a/src/lstack/api/lstack_wrap.c
|
||||
+++ b/src/lstack/api/lstack_wrap.c
|
||||
@@ -50,18 +50,21 @@ bool select_thread_path(void);
|
||||
|
||||
static enum KERNEL_LWIP_PATH select_path(int fd)
|
||||
{
|
||||
- if (!select_thread_path()) {
|
||||
- return PATH_KERNEL;
|
||||
- }
|
||||
-
|
||||
if (unlikely(posix_api == NULL)) {
|
||||
- /* posix api maybe call before gazelle init */
|
||||
+ /*
|
||||
+ * posix api maybe call before gazelle init
|
||||
+ * So, we must call posix_api_init at the head of select_path
|
||||
+ */
|
||||
if (posix_api_init() != 0) {
|
||||
LSTACK_PRE_LOG(LSTACK_ERR, "posix_api_init failed\n");
|
||||
}
|
||||
return PATH_KERNEL;
|
||||
}
|
||||
|
||||
+ if (!select_thread_path()) {
|
||||
+ return PATH_KERNEL;
|
||||
+ }
|
||||
+
|
||||
if (unlikely(posix_api->ues_posix)) {
|
||||
return PATH_KERNEL;
|
||||
}
|
||||
--
|
||||
2.33.0
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
|
||||
Name: gazelle
|
||||
Version: 1.0.1
|
||||
Release: 32
|
||||
Release: 33
|
||||
Summary: gazelle is a high performance user-mode stack
|
||||
License: MulanPSL-2.0
|
||||
URL: https://gitee.com/openeuler/gazelle
|
||||
@ -171,6 +171,7 @@ Patch9153: 0153-rxtx-mbuf-pool-size-config-by-conf.patch
|
||||
Patch9154: 0154-fix-kernel-event-thread-bind-numa-failed.patch
|
||||
Patch9155: 0155-stack-thread-parms-config-by-conf.patch
|
||||
Patch9156: 0156-ltran-rxtx-mbuf-pool-size-config-by-conf.patch
|
||||
Patch9157: 0157-move-select_thread_path-after-posix_api_init.patch
|
||||
|
||||
%description
|
||||
%{name} is a high performance user-mode stack.
|
||||
@ -211,6 +212,9 @@ install -Dpm 0640 %{_builddir}/%{name}-%{version}/src/ltran/ltran.conf %{b
|
||||
%config(noreplace) %{conf_path}/ltran.conf
|
||||
|
||||
%changelog
|
||||
* Fri Dec 16 2022 kircher <majun65@huawei.com> - 1.0.1-33
|
||||
- move select_thread_path after posix_api_init
|
||||
|
||||
* Thu Dec 15 2022 jiangheng <jiangheng14@huawei.com> - 1.0.1-32
|
||||
- ltran rxtx mbuf pool size config by conf
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user