|
Revision tags: v24.07-rc2, v24.07-rc1, v24.03, v24.03-rc4, v24.03-rc3, v24.03-rc2, v24.03-rc1, v23.11, v23.11-rc4, v23.11-rc3, v23.11-rc2, v23.11-rc1 |
|
| #
ce703c47 |
| 13-Sep-2023 |
Thomas Monjalon <thomas@monjalon.net> |
eal: force prefix for internal threads
In order to make sure all threads created in DPDK drivers and libraries have the same prefix in their name, some wrapper functions are added for internal use w
eal: force prefix for internal threads
In order to make sure all threads created in DPDK drivers and libraries have the same prefix in their name, some wrapper functions are added for internal use when creating a control thread or setting a thread name: - rte_thread_create_internal_control - rte_thread_set_prefixed_name
The equivalent public functions are then forbidden for internal use: - rte_thread_create_control - rte_thread_set_name
Note: the libraries and drivers conversion is done in next patches, while doing other thread-related changes.
Signed-off-by: Thomas Monjalon <thomas@monjalon.net> Acked-by: Morten Brørup <mb@smartsharesystems.com> Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com> Acked-by: Konstantin Ananyev <konstantin.v.ananyev@yandex.ru>
show more ...
|
| #
531a04aa |
| 13-Sep-2023 |
Thomas Monjalon <thomas@monjalon.net> |
eal: promote thread API as stable
The rte_thread API must be used to ease OS porting. One step of this process is to mark the necessary API as stable.
Signed-off-by: Thomas Monjalon <thomas@monjalo
eal: promote thread API as stable
The rte_thread API must be used to ease OS porting. One step of this process is to mark the necessary API as stable.
Signed-off-by: Thomas Monjalon <thomas@monjalon.net> Acked-by: Morten Brørup <mb@smartsharesystems.com> Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com> Acked-by: Konstantin Ananyev <konstantin.v.ananyev@yandex.ru>
show more ...
|
| #
70d19787 |
| 13-Sep-2023 |
Thomas Monjalon <thomas@monjalon.net> |
eal: remove attributes from control thread creation
The experimental function rte_thread_create_control() is supposed to wrap actions needed to create a control thread in DPDK. This function should
eal: remove attributes from control thread creation
The experimental function rte_thread_create_control() is supposed to wrap actions needed to create a control thread in DPDK. This function should be easy to port on any OS.
As such, the thread attributes should not be customizable in this API. The thread priority should be normal, and the affinity is on "free cores". That's why the custom attributes parameter thread_attr is dropped.
Signed-off-by: Thomas Monjalon <thomas@monjalon.net> Acked-by: Morten Brørup <mb@smartsharesystems.com> Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com> Acked-by: Konstantin Ananyev <konstantin.v.ananyev@yandex.ru>
show more ...
|
| #
93d8a7ed |
| 13-Sep-2023 |
Thomas Monjalon <thomas@monjalon.net> |
eal: rename thread name length definition
RTE_MAX_THREAD_NAME_LEN is including the NUL character, so it should be named "size" instead of "length". A new constant RTE_THREAD_NAME_SIZE is introduced
eal: rename thread name length definition
RTE_MAX_THREAD_NAME_LEN is including the NUL character, so it should be named "size" instead of "length". A new constant RTE_THREAD_NAME_SIZE is introduced for naming accuracy. For API compatibility, the old name is kept.
At the same time, the original definition is moved from rte_eal.h to rte_thread.h.
Signed-off-by: Thomas Monjalon <thomas@monjalon.net> Acked-by: Morten Brørup <mb@smartsharesystems.com> Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com> Acked-by: Konstantin Ananyev <konstantin.v.ananyev@yandex.ru>
show more ...
|
|
Revision tags: v23.07, v23.07-rc4, v23.07-rc3, v23.07-rc2 |
|
| #
b4f0a9bb |
| 14-Jun-2023 |
Thomas Monjalon <thomas@monjalon.net> |
lib: remove blank line ending comment blocks
At the end of a comment, no need for an extra line.
This pattern was fixed with the following command: git ls lib | xargs sed -i '/^ *\* *$/{N;/ *\*\/ *
lib: remove blank line ending comment blocks
At the end of a comment, no need for an extra line.
This pattern was fixed with the following command: git ls lib | xargs sed -i '/^ *\* *$/{N;/ *\*\/ *$/D;}'
Signed-off-by: Thomas Monjalon <thomas@monjalon.net> Acked-by: Bruce Richardson <bruce.richardson@intel.com> Reviewed-by: Ruifeng Wang <ruifeng.wang@arm.com>
show more ...
|
|
Revision tags: v23.07-rc1, v23.03, v23.03-rc4, v23.03-rc3, v23.03-rc2, v23.03-rc1 |
|
| #
878b7468 |
| 08-Feb-2023 |
Tyler Retzlaff <roretzla@linux.microsoft.com> |
eal: add platform agnostic control thread API
Add rte_thread_create_control API as a replacement for rte_ctrl_thread_create to allow deprecation of the use of platform specific types in DPDK public
eal: add platform agnostic control thread API
Add rte_thread_create_control API as a replacement for rte_ctrl_thread_create to allow deprecation of the use of platform specific types in DPDK public API.
Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com> Acked-by: Morten Brørup <mb@smartsharesystems.com> Reviewed-by: Mattias Rönnblom <mattias.ronnblom@ericsson.com>
show more ...
|
| #
6d87be58 |
| 24-Jan-2023 |
Tyler Retzlaff <roretzla@linux.microsoft.com> |
eal: add platform agnostic thread set name API
Add a rte_thread_set_name that sets the name of an rte_thread_t thread. This is a replacement for the rte_thread_setname(pthread_t, ...) which exposes
eal: add platform agnostic thread set name API
Add a rte_thread_set_name that sets the name of an rte_thread_t thread. This is a replacement for the rte_thread_setname(pthread_t, ...) which exposes platform-specific details.
Introduces Windows implementation for rte_thread_set_name not previously available on Windows.
Adapt drivers/mlx5 to use the new internal rte_thread_set_name API instead of the soon to be deprecated rte_thread_setname API.
Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com> Acked-by: Morten Brørup <mb@smartsharesystems.com> Acked-by: Thomas Monjalon <thomas@monjalon.net>
show more ...
|
|
Revision tags: v22.11, v22.11-rc4, v22.11-rc3, v22.11-rc2, v22.11-rc1 |
|
| #
a2e94ca8 |
| 05-Oct-2022 |
Tyler Retzlaff <roretzla@linux.microsoft.com> |
eal: add thread comparison helper
Add rte_thread_equal() that tests if two rte_thread_id are equal.
Signed-off-by: Narcisa Vasile <navasile@linux.microsoft.com> Signed-off-by: Tyler Retzlaff <roret
eal: add thread comparison helper
Add rte_thread_equal() that tests if two rte_thread_id are equal.
Signed-off-by: Narcisa Vasile <navasile@linux.microsoft.com> Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com> Acked-by: Chengwen Feng <fengchengwen@huawei.com> Acked-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
show more ...
|
| #
ce6e911d |
| 05-Oct-2022 |
Tyler Retzlaff <roretzla@linux.microsoft.com> |
eal: add thread lifetime API
The *rte_thread_create()* function can optionally receive an rte_thread_attr_t object that will cause the thread to be created with the affinity and priority described b
eal: add thread lifetime API
The *rte_thread_create()* function can optionally receive an rte_thread_attr_t object that will cause the thread to be created with the affinity and priority described by the attributes object. If no rte_thread_attr_t is passed (parameter is NULL), the default affinity and priority are used.
On Windows, the function executed by a thread when the thread starts is represented by a function pointer of type DWORD (*func) (void*). On other platforms, the function pointer is a void* (*func) (void*).
Performing a cast between these two types of function pointers to uniformize the API on all platforms may result in undefined behavior. To fix this issue, a wrapper that respects the signature required by CreateThread() has been created on Windows.
Signed-off-by: Narcisa Vasile <navasile@linux.microsoft.com> Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com> Acked-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
show more ...
|
| #
51e6608a |
| 05-Oct-2022 |
Tyler Retzlaff <roretzla@linux.microsoft.com> |
eal: get/set thread attributes
Implement thread attributes for:
* thread affinity * thread priority
Implement functions for managing thread attributes.
Priority is represented through a
eal: get/set thread attributes
Implement thread attributes for:
* thread affinity * thread priority
Implement functions for managing thread attributes.
Priority is represented through an enum that allows for two levels:
* RTE_THREAD_PRIORITY_NORMAL * RTE_THREAD_PRIORITY_REALTIME_CRITICAL
Affinity is described by the rte_cpuset_t type.
An rte_thread_attr_t object can be set to the default values by calling rte_thread_attr_init().
Signed-off-by: Narcisa Vasile <navasile@linux.microsoft.com> Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com> Acked-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
show more ...
|
|
Revision tags: v22.07, v22.07-rc4, v22.07-rc3, v22.07-rc2, v22.07-rc1 |
|
| #
ca04c78b |
| 24-May-2022 |
Tyler Retzlaff <roretzla@linux.microsoft.com> |
eal: get/set thread priority per thread identifier
Add functions for setting and getting the priority of a thread. Priorities on multiple platforms are similarly determined by a priority value and a
eal: get/set thread priority per thread identifier
Add functions for setting and getting the priority of a thread. Priorities on multiple platforms are similarly determined by a priority value and a priority class/policy.
Currently in DPDK most threads operate at the OS-default priority level but there are cases when increasing the priority is useful. For example, high performance applications may require elevated priority levels.
For these reasons, EAL will expose two priority levels which are named suggestively "normal" and "realtime_critical" and are computed as follows:
On Linux, the following mapping is created: RTE_THREAD_PRIORITY_NORMAL corresponds to * policy SCHED_OTHER * priority value: (sched_get_priority_min(SCHED_OTHER) + sched_get_priority_max(SCHED_OTHER))/2; RTE_THREAD_PRIORITY_REALTIME_CRITICAL corresponds to * policy SCHED_RR * priority value: sched_get_priority_max(SCHED_RR);
On Windows, the following mapping is created: RTE_THREAD_PRIORITY_NORMAL corresponds to * class NORMAL_PRIORITY_CLASS * priority THREAD_PRIORITY_NORMAL RTE_THREAD_PRIORITY_REALTIME_CRITICAL corresponds to * class REALTIME_PRIORITY_CLASS (when running with privileges) * class HIGH_PRIORITY_CLASS (when running without privileges) * priority THREAD_PRIORITY_TIME_CRITICAL
Note that on Linux the resulting priority value will be 0, in accordance to the documentation that mention the value should be 0 for SCHED_OTHER policy.
Signed-off-by: Narcisa Vasile <navasile@linux.microsoft.com> Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com> Acked-by: Stephen Hemminger <stephen@networkplumber.org>
show more ...
|
| #
b70a9b78 |
| 12-May-2022 |
Tyler Retzlaff <roretzla@linux.microsoft.com> |
eal: get/set thread affinity per thread identifier
Implement functions for getting/setting thread affinity. Threads can be pinned to specific cores by setting their affinity attribute.
Windows erro
eal: get/set thread affinity per thread identifier
Implement functions for getting/setting thread affinity. Threads can be pinned to specific cores by setting their affinity attribute.
Windows error codes are translated to errno-style error codes. The possible return values are chosen so that we have as much semantic compatibility between platforms as possible.
note: convert_cpuset_to_affinity has a limitation that all cpus of the set belong to the same processor group.
Signed-off-by: Narcisa Vasile <navasile@linux.microsoft.com> Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com> Acked-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
show more ...
|
| #
56539289 |
| 12-May-2022 |
Tyler Retzlaff <roretzla@linux.microsoft.com> |
eal: provide current thread identifier
Provide a portable type-safe thread identifier. Provide rte_thread_self for obtaining current thread identifier.
Signed-off-by: Narcisa Vasile <navasile@linux
eal: provide current thread identifier
Provide a portable type-safe thread identifier. Provide rte_thread_self for obtaining current thread identifier.
Signed-off-by: Narcisa Vasile <navasile@linux.microsoft.com> Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com> Acked-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com> Acked-by: Konstantin Ananyev <konstantin.v.ananyev@yandex.ru>
show more ...
|
|
Revision tags: v22.03, v22.03-rc4, v22.03-rc3, v22.03-rc2, v22.03-rc1, v21.11, v21.11-rc4, v21.11-rc3, v21.11-rc2, v21.11-rc1, v21.08, v21.08-rc4, v21.08-rc3, v21.08-rc2, v21.08-rc1, v21.05, v21.05-rc4, v21.05-rc3, v21.05-rc2, v21.05-rc1 |
|
| #
99a2dd95 |
| 20-Apr-2021 |
Bruce Richardson <bruce.richardson@intel.com> |
lib: remove librte_ prefix from directory names
There is no reason for the DPDK libraries to all have 'librte_' prefix on the directory names. This prefix makes the directory names longer and also m
lib: remove librte_ prefix from directory names
There is no reason for the DPDK libraries to all have 'librte_' prefix on the directory names. This prefix makes the directory names longer and also makes it awkward to add features referring to individual libraries in the build - should the lib names be specified with or without the prefix. Therefore, we can just remove the library prefix and use the library's unique name as the directory name, i.e. 'eal' rather than 'librte_eal'
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
show more ...
|