[v6,02/14] eal: use rte strerror

Message ID 20241114114000.1677350-3-huangdengdui@huawei.com (mailing list archive)
State New
Delegated to: Thomas Monjalon
Headers
Series use rte_strerror() for rte_errno |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

huangdengdui Nov. 14, 2024, 11:39 a.m. UTC
The rte_errno may be an RTE-specific error code,
use rte_strerror() instead of strerror().

Signed-off-by: Dengdui Huang <huangdengdui@huawei.com>
---
 lib/eal/linux/eal_dev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
  

Patch

diff --git a/lib/eal/linux/eal_dev.c b/lib/eal/linux/eal_dev.c
index e63f24d108..95b1d02c9f 100644
--- a/lib/eal/linux/eal_dev.c
+++ b/lib/eal/linux/eal_dev.c
@@ -73,7 +73,7 @@  static void sigbus_handler(int signum, siginfo_t *info,
 	if (ret == -1) {
 		rte_exit(EXIT_FAILURE,
 			 "Failed to handle SIGBUS for hot-unplug, "
-			 "(rte_errno: %s)!", strerror(rte_errno));
+			 "(rte_errno: %s)!", rte_strerror(rte_errno));
 	} else if (ret == 1) {
 		if (sigbus_action_old.sa_flags == SA_SIGINFO
 		    && sigbus_action_old.sa_sigaction) {