In loopback mode, it's expected force link up even when there's no cable
connect.
But in codes, setup_sfp() rewrites the related register.
It causes in the case 'multispeed_fiber', it can't link up without cable
connect.
Signed-off-by: Cunming Liang
---
lib/librte_pmd_ixgbe/ixgbe_ethdev.c
rom Konstantin, Bruce, Mirek and Stephen in
RFC review.
*** BLURB HERE ***
Cunming Liang (19):
eal: add cpuset into per EAL thread lcore_config
eal: fix PAGE_SIZE redefine complaint on freebsd
eal: new eal option '--lcores' for cpu assignment
eal: fix wrong strnlen() return value in 32bit
cpus.
Signed-off-by: Cunming Liang
---
v5 changes:
separate eal_memory.c to the new patch
lib/librte_eal/bsdapp/eal/eal_lcore.c | 7 +++
lib/librte_eal/common/include/rte_lcore.h | 8
lib/librte_eal/linuxapp/eal/Makefile | 1 +
lib/librte_eal/linuxapp/eal/eal_lcore.c
Signed-off-by: Cunming Liang
---
lib/librte_eal/bsdapp/eal/eal_memory.c | 8 +---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/lib/librte_eal/bsdapp/eal/eal_memory.c
b/lib/librte_eal/bsdapp/eal/eal_memory.c
index 65ee87d..33ebd0f 100644
--- a/lib/librte_eal/bsdapp/eal
pu 0,6)
lcore 7 runs on cpuset 0x80 (cpu 7)
lcore 8 runs on cpuset 0x100 (cpu 8)
Signed-off-by: Cunming Liang
---
v5 changes:
add more comments for eal_parse_set
fix some typo
remove inline prefix from convert_to_cpuset()
fix a bug introduced on v2 which broke case '(0,6)'
v2 c
The problem is that strnlen() here may return invalid value with 32bit icc.
(actually it returns it?s second parameter,e.g: sysconf(_SC_ARG_MAX)).
It starts to manifest hwen max_len parameter is > 2M and using icc ?m32 ?O2 (or
above).
Suggested-by: Konstantin Ananyev
Signed-off-by: Cunm
It returns the socket_id if all cpus in the cpuset belongs
to the same NUMA node, otherwise it will return SOCKET_ID_ANY.
Signed-off-by: Cunming Liang
---
v5 changes:
expose cpu_socket_id as eal_cpu_socket_id for linuxapp
eal_cpuset_socket_id() remove static inline and move to c file
1. add two TLS *_socket_id* and *_cpuset*
2. add two external API rte_thread_set/get_affinity
3. add one internal API eal_thread_dump_affinity
Signed-off-by: Cunming Liang
---
v5 changes:
add comments for RTE_CPU_AFFINITY_STR_LEN
update comments for eal_thread_dump_affinity()
return
The API works for both EAL thread and none EAL thread.
When calling rte_thread_set_affinity, the *_socket_id* and
*_cpuset* of calling thread will be updated if the thread
successful set the cpu affinity.
Signed-off-by: Cunming Liang
---
v5 changes:
refine code of rte_thread_set_affinity
Signed-off-by: Cunming Liang
---
lib/librte_eal/bsdapp/eal/eal.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/librte_eal/bsdapp/eal/eal.c b/lib/librte_eal/bsdapp/eal/eal.c
index 69f3c03..cb11b5c 100644
--- a/lib/librte_eal/bsdapp/eal/eal.c
+++ b/lib/librte_eal
The rte_gettid() wraps the linux and freebsd syscall gettid().
It provides a persistent unique thread id for the calling thread.
It will save the unique id in TLS on the first time.
Signed-off-by: Cunming Liang
---
lib/librte_eal/bsdapp/eal/eal_thread.c | 9 +
lib/librte_eal/common
EAL threads use assigned cpuset to set core affinity during startup.
It keeps 1:1 mapping, if no '--lcores' option is used.
Signed-off-by: Cunming Liang
---
v5 changes:
add return check for dump_affinity
call rte_thread_set_affinity() directly during EAL thread set
lib/librte_eal/bsdapp
Some macro already been defined by freebsd 'sys/param.h'.
Signed-off-by: Cunming Liang
---
v5 changes:
rename the redefined MACRO instead of undefine them
lib/librte_pmd_enic/enic.h | 4 ++--
lib/librte_pmd_enic/enic_compat.h | 2 +-
lib/librte_pmd_enic/vnic/vnic_dev.c | 6
For those non-EAL thread, *_lcore_id* is invalid and probably larger than
RTE_MAX_LCORE.
The patch adds the check and allows only EAL thread using EAL per thread log
level and log type.
Others shares the global log level.
Signed-off-by: Cunming Liang
---
lib/librte_eal/common/eal_common_log.c
Add check for rte_socket_id(), avoid get unexpected return like (-1).
Signed-off-by: Cunming Liang
---
lib/librte_malloc/malloc_heap.h | 7 ++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/lib/librte_malloc/malloc_heap.h b/lib/librte_malloc/malloc_heap.h
index b4aec45
For those none EAL thread, *_lcore_id* shall always be LCORE_ID_ANY.
The libraries using *_lcore_id* as index need to take care.
*_socket_id* always be SOCKET_ID_ANY unitl the thread changes the affinity
by rte_thread_set_affinity()
Signed-off-by: Cunming Liang
---
v5 changes:
define
.
It will get bad performance and has critical risk if scheduling policy is RT.
Haven't found significant performance decrease by mempool_perf_test.
Signed-off-by: Cunming Liang
---
v5 changes:
check __lcore_id with LCORE_ID_ANY instead of RTE_MAX_LCORE
lib/librte_mempool/rte_mempool.h | 18
In non-EAL thread, lcore_id alrways be LCORE_ID_ANY.
It cann't be used as unique id for recursive spinlock.
Then use rte_gettid() to replace it.
Signed-off-by: Cunming Liang
---
lib/librte_eal/common/include/generic/rte_spinlock.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff
ring debug stat won't take care non-EAL thread.
Signed-off-by: Cunming Liang
---
v5 changes:
check __lcore_id with LCORE_ID_ANY instead of RTE_MAX_LCORE
lib/librte_ring/rte_ring.h | 10 ++
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/lib/librte_ring/rte_ring.h b
Klocwork report 'req' might be used uninitialized.
In some cases it can 'goto error' when '*internals' not been set.
The result is unexpected checking the value of '*internals'.
Signed-off-by: Cunming Liang
---
lib/librte_pmd_af_packet/rte_eth_af_packet.c | 4 +++-
1 file changed, 3 insertions
(dynamic created by user).
Each fix libraries take care the case of rte_lcore_id() >= RTE_MAX_LCORE.
Thanks a million for the comments from Konstantin, Bruce, Mirek and Stephen in
RFC review.
Cunming Liang (19):
eal: add cpuset into per EAL thread lcore_config
eal: fix PAGE_SIZE redef
cpus.
Signed-off-by: Cunming Liang
---
v5 changes:
separate eal_memory.c to the new patch
lib/librte_eal/bsdapp/eal/eal_lcore.c | 7 +++
lib/librte_eal/common/include/rte_lcore.h | 8
lib/librte_eal/linuxapp/eal/Makefile | 1 +
lib/librte_eal/linuxapp/eal/eal_lcore.c
Signed-off-by: Cunming Liang
---
lib/librte_eal/bsdapp/eal/eal_memory.c | 8 +---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/lib/librte_eal/bsdapp/eal/eal_memory.c
b/lib/librte_eal/bsdapp/eal/eal_memory.c
index 65ee87d..33ebd0f 100644
--- a/lib/librte_eal/bsdapp/eal
The problem is that strnlen() here may return invalid value with 32bit icc.
(actually it returns it?s second parameter,e.g: sysconf(_SC_ARG_MAX)).
It starts to manifest hwen max_len parameter is > 2M and using icc ?m32 ?O2 (or
above).
Suggested-by: Konstantin Ananyev
Signed-off-by: Cunm
1. add two TLS *_socket_id* and *_cpuset*
2. add two external API rte_thread_set/get_affinity
3. add one internal API eal_thread_dump_affinity
Signed-off-by: Cunming Liang
---
v5 changes:
add comments for RTE_CPU_AFFINITY_STR_LEN
update comments for eal_thread_dump_affinity()
return
The API works for both EAL thread and none EAL thread.
When calling rte_thread_set_affinity, the *_socket_id* and
*_cpuset* of calling thread will be updated if the thread
successful set the cpu affinity.
Signed-off-by: Cunming Liang
---
v5 changes:
refine code of rte_thread_set_affinity
Signed-off-by: Cunming Liang
---
lib/librte_eal/bsdapp/eal/eal.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/librte_eal/bsdapp/eal/eal.c b/lib/librte_eal/bsdapp/eal/eal.c
index 69f3c03..cb11b5c 100644
--- a/lib/librte_eal/bsdapp/eal/eal.c
+++ b/lib/librte_eal
The rte_gettid() wraps the linux and freebsd syscall gettid().
It provides a persistent unique thread id for the calling thread.
It will save the unique id in TLS on the first time.
Signed-off-by: Cunming Liang
---
lib/librte_eal/bsdapp/eal/eal_thread.c | 9 +
lib/librte_eal/common
EAL threads use assigned cpuset to set core affinity during startup.
It keeps 1:1 mapping, if no '--lcores' option is used.
Signed-off-by: Cunming Liang
---
v5 changes:
add return check for dump_affinity
call rte_thread_set_affinity() directly during EAL thread set
lib/librte_eal/bsdapp
Some macro already been defined by freebsd 'sys/param.h'.
Signed-off-by: Cunming Liang
---
v5 changes:
rename the redefined MACRO instead of undefine them
lib/librte_pmd_enic/enic.h | 4 ++--
lib/librte_pmd_enic/enic_compat.h | 2 +-
lib/librte_pmd_enic/vnic/vnic_dev.c | 6
For those non-EAL thread, *_lcore_id* is invalid and probably larger than
RTE_MAX_LCORE.
The patch adds the check and allows only EAL thread using EAL per thread log
level and log type.
Others shares the global log level.
Signed-off-by: Cunming Liang
---
lib/librte_eal/common/eal_common_log.c
In non-EAL thread, lcore_id alrways be LCORE_ID_ANY.
It cann't be used as unique id for recursive spinlock.
Then use rte_gettid() to replace it.
Signed-off-by: Cunming Liang
---
lib/librte_eal/common/include/generic/rte_spinlock.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff
.
It will get bad performance and has critical risk if scheduling policy is RT.
Haven't found significant performance decrease by mempool_perf_test.
Signed-off-by: Cunming Liang
---
v6 changes:
rollback v5 changes
v5 changes:
check __lcore_id with LCORE_ID_ANY instead of RTE_MAX_LCORE
lib
ring debug stat won't take care non-EAL thread.
Signed-off-by: Cunming Liang
---
v6 changes:
rollback v5 changes
v5 changes:
check __lcore_id with LCORE_ID_ANY instead of RTE_MAX_LCORE
lib/librte_ring/rte_ring.h | 10 ++
1 file changed, 6 insertions(+), 4 deletions(-)
diff
shows additional perf penalty.
Signed-off-by: Cunming Liang
---
v6 changes:
rename RTE_RING_PAUSE_REP to RTE_RING_PAUSE_REP_COUNT
set default value as '0' in configure file
v5 changes:
add RTE_RING_PAUSE_REP to config file
v4 changes:
update and add more comments on sched_yield
uld simply do nothing and return
straightway.
Signed-off-by: Cunming Liang
---
v6 changes:
use 'RTE_MAX_LCORE' to check the EAL thread with valid lcore_id.
use 'LCORE_ID_ANY' for any unspecified lcore_id assignment.
v5 changes:
add assert in rte_timer_manage
remove duplicate ch
cpus.
Signed-off-by: Cunming Liang
---
v5 changes:
separate eal_memory.c to the new patch
lib/librte_eal/bsdapp/eal/eal_lcore.c | 7 +++
lib/librte_eal/common/include/rte_lcore.h | 8
lib/librte_eal/linuxapp/eal/Makefile | 1 +
lib/librte_eal/linuxapp/eal/eal_lcore.c
Signed-off-by: Cunming Liang
---
lib/librte_eal/bsdapp/eal/eal_memory.c | 8 +---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/lib/librte_eal/bsdapp/eal/eal_memory.c
b/lib/librte_eal/bsdapp/eal/eal_memory.c
index 65ee87d..33ebd0f 100644
--- a/lib/librte_eal/bsdapp/eal
pu 0,6)
lcore 7 runs on cpuset 0x80 (cpu 7)
lcore 8 runs on cpuset 0x100 (cpu 8)
Signed-off-by: Cunming Liang
---
v5 changes:
add more comments for eal_parse_set
fix some typo
remove inline prefix from convert_to_cpuset()
fix a bug introduced on v2 which broke case '(0,6)'
v2 c
The problem is that strnlen() here may return invalid value with 32bit icc.
(actually it returns it?s second parameter,e.g: sysconf(_SC_ARG_MAX)).
It starts to manifest hwen max_len parameter is > 2M and using icc ?m32 ?O2 (or
above).
Suggested-by: Konstantin Ananyev
Signed-off-by: Cunm
It defines eal_cpu_socket_id() which exposing the origin private
cpu_socket_id().
The function is only used inside EAL. It returns socket_id of the specified
cpu_id.
Signed-off-by: Cunming Liang
---
v7 changes:
reword comments
v5 changes:
expose cpu_socket_id as eal_cpu_socket_id
1. add two TLS *_socket_id* and *_cpuset*
2. add two internal API, eal_cpu_socket_id/eal_thread_dump_affinity
3. add two public API, rte_thread_set/get_affinity
4. update EAL version map for EAL public API
Signed-off-by: Cunming Liang
---
v7 changes:
update version map for EAL public API
The API works for both EAL thread and none EAL thread.
When calling rte_thread_set_affinity, the *_socket_id* and
*_cpuset* of calling thread will be updated if the thread
successful set the cpu affinity.
Signed-off-by: Cunming Liang
---
v5 changes:
refine code of rte_thread_set_affinity
Signed-off-by: Cunming Liang
---
lib/librte_eal/bsdapp/eal/eal.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/librte_eal/bsdapp/eal/eal.c b/lib/librte_eal/bsdapp/eal/eal.c
index 69f3c03..cb11b5c 100644
--- a/lib/librte_eal/bsdapp/eal/eal.c
+++ b/lib/librte_eal
The rte_gettid() wraps the linux and freebsd syscall gettid().
It provides a persistent unique thread id for the calling thread.
It will save the unique id in TLS on the first time.
Signed-off-by: Cunming Liang
---
lib/librte_eal/bsdapp/eal/eal_thread.c | 9 +
lib/librte_eal/common
EAL threads use assigned cpuset to set core affinity during startup.
It keeps 1:1 mapping, if no '--lcores' option is used.
Signed-off-by: Cunming Liang
---
v5 changes:
add return check for dump_affinity
call rte_thread_set_affinity() directly during EAL thread set
lib/librte_eal/bsdapp
Some macro already been defined by freebsd 'sys/param.h'.
Signed-off-by: Cunming Liang
---
v5 changes:
rename the redefined MACRO instead of undefine them
lib/librte_pmd_enic/enic.h | 4 ++--
lib/librte_pmd_enic/enic_compat.h | 2 +-
lib/librte_pmd_enic/vnic/vnic_dev.c | 6
in the cpuset may belongs to
different NUMA nodes.
The value of _socket_id probably be SOCKET_ID_ANY(-1), the case is not expected
in origin malloc_get_numa_socket().
Signed-off-by: Cunming Liang
---
v7 changes:
reword comments
lib/librte_malloc/malloc_heap.h | 7 ++-
1 file changed, 6
For those non-EAL thread, *_lcore_id* is invalid and probably larger than
RTE_MAX_LCORE.
The patch adds the check and allows only EAL thread using EAL per thread log
level and log type.
Others shares the global log level.
Signed-off-by: Cunming Liang
---
lib/librte_eal/common/eal_common_log.c
For those none EAL thread, *_lcore_id* shall always be LCORE_ID_ANY.
The libraries using *_lcore_id* as index need to take care.
*_socket_id* always be SOCKET_ID_ANY unitl the thread changes the affinity
by rte_thread_set_affinity()
Signed-off-by: Cunming Liang
---
v5 changes:
define
In non-EAL thread, lcore_id alrways be LCORE_ID_ANY.
It cann't be used as unique id for recursive spinlock.
Then use rte_gettid() to replace it.
Signed-off-by: Cunming Liang
---
lib/librte_eal/common/include/generic/rte_spinlock.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff
.
It will get bad performance and has critical risk if scheduling policy is RT.
Haven't found significant performance decrease by mempool_perf_test.
Signed-off-by: Cunming Liang
---
v6 changes:
rollback v5 changes
v5 changes:
check __lcore_id with LCORE_ID_ANY instead of RTE_MAX_LCORE
lib
ring debug stat won't take care non-EAL thread.
Signed-off-by: Cunming Liang
---
v6 changes:
rollback v5 changes
v5 changes:
check __lcore_id with LCORE_ID_ANY instead of RTE_MAX_LCORE
lib/librte_ring/rte_ring.h | 10 ++
1 file changed, 6 insertions(+), 4 deletions(-)
diff
shows additional perf penalty.
Signed-off-by: Cunming Liang
---
v6 changes:
rename RTE_RING_PAUSE_REP to RTE_RING_PAUSE_REP_COUNT
set default value as '0' in configure file
v5 changes:
add RTE_RING_PAUSE_REP to config file
v4 changes:
update and add more comments on sched_yield
uld simply do nothing and return
straightway.
Signed-off-by: Cunming Liang
---
v6 changes:
use 'RTE_MAX_LCORE' to check the EAL thread with valid lcore_id.
use 'LCORE_ID_ANY' for any unspecified lcore_id assignment.
v5 changes:
add assert in rte_timer_manage
remove duplicate ch
The patch add unit test for the new eal option "--lcores".
Signed-off-by: Cunming Liang
---
It depends on the previous patch which enabling EAL "--lcores" option.
http://dpdk.org/ml/archives/dev/2015-February/013204.html
app/test/t
The patch add the multi-pthread section under EAL chapter of prog_guide.
Signed-off-by: Cunming Liang
---
doc/guides/prog_guide/env_abstraction_layer.rst | 157
1 file changed, 157 insertions(+)
diff --git a/doc/guides/prog_guide/env_abstraction_layer.rst
b/doc/guides
ion for the comments from Konstantin, Bruce, Mirek and Stephen in
RFC review.
Cunming Liang (19):
eal: add cpuset into per EAL thread lcore_config
eal: fix PAGE_SIZE redefine complaint on freebsd
eal: new eal option '--lcores' for cpu assignment
eal: fix wrong strnlen() return value in 32bit icc
et 0x41 (cpu 0,6)
lcore 7 runs on cpuset 0x80 (cpu 7)
lcore 8 runs on cpuset 0x100 (cpu 8)
Signed-off-by: Cunming Liang
---
v5 changes:
add more comments for eal_parse_set
fix some typo
remove inline prefix from convert_to_cpuset()
fix a bug introduced on v2 which broke case '(0,6)'
Signed-off-by: Cunming Liang
---
lib/librte_eal/bsdapp/eal/eal_memory.c | 8 +---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/lib/librte_eal/bsdapp/eal/eal_memory.c
b/lib/librte_eal/bsdapp/eal/eal_memory.c
index 65ee87d..33ebd0f 100644
--- a/lib/librte_eal/bsdapp/eal
It defines eal_cpu_socket_id() which exposing the origin private
cpu_socket_id().
The function is only used inside EAL. It returns socket_id of the specified
cpu_id.
Signed-off-by: Cunming Liang
---
v7 changes:
reword comments
v5 changes:
expose cpu_socket_id as eal_cpu_socket_id
cpus.
Signed-off-by: Cunming Liang
---
v5 changes:
separate eal_memory.c to the new patch
lib/librte_eal/bsdapp/eal/eal_lcore.c | 7 +++
lib/librte_eal/common/include/rte_lcore.h | 8
lib/librte_eal/linuxapp/eal/Makefile | 1 +
lib/librte_eal/linuxapp/eal/eal_lcore.c
The problem is that strnlen() here may return invalid value with 32bit icc.
(actually it returns it?s second parameter,e.g: sysconf(_SC_ARG_MAX)).
It starts to manifest hwen max_len parameter is > 2M and using icc ?m32 ?O2 (or
above).
Suggested-by: Konstantin Ananyev
Signed-off-by: Cunm
1. add two TLS *_socket_id* and *_cpuset*
2. add one internal API, eal_cpu_socket_id/eal_thread_dump_affinity
3. add two public API, rte_thread_set/get_affinity
4. update EAL version map for EAL public API
Signed-off-by: Cunming Liang
---
v7 changes:
update version map for EAL public API
The API works for both EAL thread and none EAL thread.
When calling rte_thread_set_affinity, the *_socket_id* and
*_cpuset* of calling thread will be updated if the thread
successful set the cpu affinity.
Signed-off-by: Cunming Liang
---
v5 changes:
refine code of rte_thread_set_affinity
Signed-off-by: Cunming Liang
---
lib/librte_eal/bsdapp/eal/eal.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/librte_eal/bsdapp/eal/eal.c b/lib/librte_eal/bsdapp/eal/eal.c
index 69f3c03..cb11b5c 100644
--- a/lib/librte_eal/bsdapp/eal/eal.c
+++ b/lib/librte_eal
The rte_gettid() wraps the linux and freebsd syscall gettid().
It provides a persistent unique thread id for the calling thread.
It will save the unique id in TLS on the first time.
Signed-off-by: Cunming Liang
---
lib/librte_eal/bsdapp/eal/eal_thread.c | 9 +
lib/librte_eal/common
EAL threads use assigned cpuset to set core affinity during startup.
It keeps 1:1 mapping, if no '--lcores' option is used.
Signed-off-by: Cunming Liang
---
v5 changes:
add return check for dump_affinity
call rte_thread_set_affinity() directly during EAL thread set
lib/librte_eal/bsdapp
Some macro already been defined by freebsd 'sys/param.h'.
Signed-off-by: Cunming Liang
---
v5 changes:
rename the redefined MACRO instead of undefine them
lib/librte_pmd_enic/enic.h | 4 ++--
lib/librte_pmd_enic/enic_compat.h | 2 +-
lib/librte_pmd_enic/vnic/vnic_dev.c | 6
in the cpuset may belongs to
different NUMA nodes.
The value of _socket_id probably be SOCKET_ID_ANY(-1), the case is not expected
in origin malloc_get_numa_socket().
Signed-off-by: Cunming Liang
---
v7 changes:
reword comments
lib/librte_malloc/malloc_heap.h | 7 ++-
1 file changed, 6
For those non-EAL thread, *_lcore_id* is invalid and probably larger than
RTE_MAX_LCORE.
The patch adds the check and allows only EAL thread using EAL per thread log
level and log type.
Others shares the global log level.
Signed-off-by: Cunming Liang
---
lib/librte_eal/common/eal_common_log.c
For those none EAL thread, *_lcore_id* shall always be LCORE_ID_ANY.
The libraries using *_lcore_id* as index need to take care.
*_socket_id* always be SOCKET_ID_ANY unitl the thread changes the affinity
by rte_thread_set_affinity()
Signed-off-by: Cunming Liang
---
v5 changes:
define
.
It will get bad performance and has critical risk if scheduling policy is RT.
Haven't found significant performance decrease by mempool_perf_test.
Signed-off-by: Cunming Liang
---
v6 changes:
rollback v5 changes
v5 changes:
check __lcore_id with LCORE_ID_ANY instead of RTE_MAX_LCORE
lib
ring debug stat won't take care non-EAL thread.
Signed-off-by: Cunming Liang
---
v6 changes:
rollback v5 changes
v5 changes:
check __lcore_id with LCORE_ID_ANY instead of RTE_MAX_LCORE
lib/librte_ring/rte_ring.h | 10 ++
1 file changed, 6 insertions(+), 4 deletions(-)
diff
In non-EAL thread, lcore_id alrways be LCORE_ID_ANY.
It cann't be used as unique id for recursive spinlock.
Then use rte_gettid() to replace it.
Signed-off-by: Cunming Liang
---
lib/librte_eal/common/include/generic/rte_spinlock.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff
shows additional perf penalty.
Signed-off-by: Cunming Liang
---
v6 changes:
rename RTE_RING_PAUSE_REP to RTE_RING_PAUSE_REP_COUNT
set default value as '0' in configure file
v5 changes:
add RTE_RING_PAUSE_REP to config file
v4 changes:
update and add more comments on sched_yield
uld simply do nothing and return
straightway.
Signed-off-by: Cunming Liang
---
v6 changes:
use 'RTE_MAX_LCORE' to check the EAL thread with valid lcore_id.
use 'LCORE_ID_ANY' for any unspecified lcore_id assignment.
v5 changes:
add assert in rte_timer_manage
remove duplicate ch
These two patches are the fixing for the compling error when
CONFIG_RTE_BUILD_SHARED_LIB=y.
The root cause is *per_lcore__socket_id* and *rte_sys_gettid* are missing in
the version map.
Thanks for the notification from Tetsuya Mukawa .
Cunming Liang (2):
eal/linux: fix symbol missing
As per_lcore__socket_id and rte_sys_gettid are missing in version map,
it causes compiling error when CONFIG_RTE_BUILD_SHARED_LIB is enabled.
Signed-off-by: Cunming Liang
---
lib/librte_eal/linuxapp/eal/rte_eal_version.map | 2 ++
1 file changed, 2 insertions(+)
diff --git a/lib/librte_eal
As per_lcore__socket_id and rte_sys_gettid are missing in version map,
it causes compiling error when CONFIG_RTE_BUILD_SHARED_LIB is enabled.
Signed-off-by: Cunming Liang
---
lib/librte_eal/bsdapp/eal/rte_eal_version.map | 2 ++
1 file changed, 2 insertions(+)
diff --git a/lib/librte_eal
ueue interrupts on a PF.
Cunming Liang (5):
eal: declare new interrupt api
eal/linux: add rx queue interrupt FDs to intr handle struct
eal/bsd: dummy for new intr definition
eal/linux: add per rx queue interrupt handling based on VFIO
ethdev: add rx interrupt enable/disable functions
Add two API *rte_intr_rx_wait* and *rte_intr_rx_set* for RX interrupt.
They're only available in VFIO_MSIX.
Signed-off-by: Cunming Liang
---
lib/librte_eal/common/include/rte_interrupts.h | 38 ++
1 file changed, 38 insertions(+)
diff --git a/lib/librte_eal/common
To make bsd compiling happy with new intr changes.
Signed-off-by: Cunming Liang
---
lib/librte_eal/bsdapp/eal/eal_interrupts.c| 15 +++
.../bsdapp/eal/include/exec-env/rte_interrupts.h | 4
lib/librte_eal/bsdapp/eal/rte_eal_version.map | 2
Signed-off-by: Cunming Liang
---
v6 changes
- split rte_intr_wait_rx_pkt into two function, wait and set.
- rewrite rte_intr_rx_wait/rte_intr_rx_set to remove queue visibility on eal.
- rte_intr_rx_wait to support multiplexing.
- allow epfd as input to support flexible event fd combination.
v5
Per vector event fd will store in rte_intr_handle during init.
Device drivers take responsibility to fill queue-vec mapping table(vec_num[]).
Signed-off-by: Danny Zhou
Signed-off-by: Cunming Liang
---
v6 changes:
- add mapping table between irq vector number and queue id.
v5 changes
From: "Zhou, Danny" <danny.z...@intel.com>
The patch does below for igb PF:
- Setup NIC to generate MSI-X interrupts
- Set the IVAR register to map interrupt causes to vectors
- Implement interrupt enable/disable functions
Signed-off-by: Danny Zhou
Signed-off-by: Cunming Liang
Add three dev_ops functions to enable and disable rx queue interrupts; and to
retrieve the vector num which the specified queue assosiated with.
Signed-off-by: Danny Zhou
Signed-off-by: Cunming Liang
---
v6 changes
- add rx_intr_vec_get to retrieve the vector num of the queue.
v5 changes
rsapce interrupt notification generally takes a lot more cycles
than kernel, so one-shot interrupt is used here to guarantee minimum
overhead and DPDK polling thread returns to polling mode immediately
once it receives an interrupt notificaiton for incoming packet.
Signed-off-by: Danny Zhou
Signed-off-b
ntfd shared by LSC
and rx queue interrupt handlers causes a mess. [FIXED]
2) LSC interrupt is not supported by VF driver, so it is by default disabled
in L3fwd-power now. Feel free to turn in on if you want to support both LSC
and rx queue interrupts on a PF.
Cunming Liang (13):
eal/linux:
.
The epoll event support to carry a raw user data and to register a callback
which is executed during wakeup.
Signed-off-by: Cunming Liang
---
v14 changes
- per-patch basis ABI compatibility rework
- remove unnecessary 'local: *' from version map
v13 changes
- version map cleanup for v2.1
v11
The patch adds 'rte_intr_rx_ctl' to add or delete interrupt vector events
monitor on specified epoll instance.
Signed-off-by: Cunming Liang
---
v14 changes
- per-patch basis ABI compatibility rework
- remove unnecessary 'local: *' from version map
v13 changes
- version map cleanup for v2.1
Signed-off-by: Cunming Liang
---
lib/librte_eal/linuxapp/eal/eal_interrupts.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/librte_eal/linuxapp/eal/eal_interrupts.c
b/lib/librte_eal/linuxapp/eal/eal_interrupts.c
index 4e34abc..cca2efd 100644
--- a/lib/librte_eal
The patch assigns event fds to each vfio msix interrupt vector by ioctl.
Signed-off-by: Danny Zhou
Signed-off-by: Cunming Liang
---
v14 changes
- per-patch basis ABI compatibility rework
- reword commit comments
v8 changes
- move eventfd creation out of the setup_interrupts to a standalone
The patch exposes intr event fd create and release for PMD.
The device driver can assign the number of event associated with interrupt
vector.
It also provides misc functions to check 1) allows other slowpath intr(e.g.
lsc);
2) intr event on fastpath is enabled or not.
Signed-off-by: Cunming
b_uio")
Reported-by: Yong Liu
Signed-off-by: Cunming Liang
---
lib/librte_eal/linuxapp/eal/eal_interrupts.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/lib/librte_eal/linuxapp/eal/eal_interrupts.c
b/lib/librte_eal/linuxapp/eal/eal_interrupts.c
index 0266d98..69ce974 100644
--- a/lib/librte_ea
To make bsd compiling happy with new intr changes.
Signed-off-by: Cunming Liang
---
v14 changes
- per-patch basis ABI compatibility rework
v13 changes
- version map cleanup for v2.1
v12 changes
- fix unused variables compiling warning
v8 changes
- add stub for new function
v7 changes
Signed-off-by: Cunming Liang
---
lib/librte_eal/bsdapp/eal/include/exec-env/rte_interrupts.h | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/lib/librte_eal/bsdapp/eal/include/exec-env/rte_interrupts.h
b/lib/librte_eal/bsdapp/eal/include/exec-env/rte_interrupts.h
index
The patch does below for igb PF:
- Setup NIC to generate MSI-X interrupts
- Set the IVAR register to map interrupt causes to vectors
- Implement interrupt enable/disable functions
Signed-off-by: Danny Zhou
Signed-off-by: Cunming Liang
---
v14 changes
- per-patch basis ABI compatibility rework
it receives an
interrupt notification caused by the incoming packets.
The sample keeps running in polling mode if the binding PMD hasn't supported
the rx interrupt yet. Now only ixgbe(pf/vf) and igb support it.
Signed-off-by: Danny Zhou
Signed-off-by: Cunming Liang
---
v14 changes
- per-patch basis
turn in on if you want to support both LSC
and rx queue interrupts on a PF.
Cunming Liang (13):
eal/linux: add interrupt vectors support in intr_handle
eal/linux: add rte_epoll_wait/ctl support
eal/linux: add API to set rx interrupt event monitor
eal/linux: fix comments typo on vfio msi
eal/linux:
1 - 100 of 372 matches
Mail list logo