The function pthread_setname_np is non-portable,
so it may be unavailable in old glibc or other systems.
The function rte_thread_setname is workarounding portability issues.
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Reviewed-by: Chenbo Xia <chenbo.xia@intel.com>
Acked-by: Matan Azrad <matan@nvidia.com>
Reviewed-by: Chengwen Feng <fengchengwen@huawei.com>
goto error;
}
snprintf(name, sizeof(name), "vDPA-mlx5-%d", priv->vid);
- ret = pthread_setname_np(priv->timer_tid, name);
+ ret = rte_thread_setname(priv->timer_tid, name);
if (ret) {
DRV_LOG(ERR, "Failed to set timer thread name.");
return -1;