From 3260064acc5854cee9ef16378b0aff338cbb8085 Mon Sep 17 00:00:00 2001 From: Xiaoyun Wang Date: Thu, 9 Jul 2020 21:43:02 +0800 Subject: [PATCH] net/hinic/base: convert error value to ETIMEDOUT Following commit updated the error codes: commit 2ae8e130cf21 ("net/hinic/base: modify returned error values") In that commit 'ETIME' errors are not used because it is not supported by FreeBSD, instead in this patch converting relevant error codes to 'ETIMEDOUT'. Signed-off-by: Xiaoyun Wang Reviewed-by: Ferruh Yigit --- drivers/net/hinic/base/hinic_pmd_hwdev.c | 2 +- drivers/net/hinic/base/hinic_pmd_hwif.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/net/hinic/base/hinic_pmd_hwdev.c b/drivers/net/hinic/base/hinic_pmd_hwdev.c index 765c47d5d8..ac2a72e388 100644 --- a/drivers/net/hinic/base/hinic_pmd_hwdev.c +++ b/drivers/net/hinic/base/hinic_pmd_hwdev.c @@ -475,7 +475,7 @@ static int wait_for_flr_finish(struct hinic_hwif *hwif) rte_delay_ms(10); } while (time_before(jiffies, end)); - return -EFAULT; + return -ETIMEDOUT; } #define HINIC_WAIT_CMDQ_IDLE_TIMEOUT 1000 diff --git a/drivers/net/hinic/base/hinic_pmd_hwif.c b/drivers/net/hinic/base/hinic_pmd_hwif.c index 4578b689db..d7fc1af707 100644 --- a/drivers/net/hinic/base/hinic_pmd_hwif.c +++ b/drivers/net/hinic/base/hinic_pmd_hwif.c @@ -321,7 +321,7 @@ int wait_until_doorbell_flush_states(struct hinic_hwif *hwif, rte_delay_ms(1); } while (time_before(jiffies, end)); - return -EFAULT; + return -ETIMEDOUT; } static int wait_until_doorbell_and_outbound_enabled(struct hinic_hwif *hwif) @@ -343,7 +343,7 @@ static int wait_until_doorbell_and_outbound_enabled(struct hinic_hwif *hwif) rte_delay_ms(1); } while (time_before(jiffies, end)); - return -EFAULT; + return -ETIMEDOUT; } u16 hinic_global_func_id(void *hwdev) -- 2.20.1