net/hns3: fix error code for firmware timeout

Configuration commands are sent to firmware for processing.
When firmware processing timeout, the corresponding error
code is returned. Considering that it is more reasonable to
use error code -ETIME for timeout error, the error code for
processing timeout is changed from -EBADE to -ETIME.

Fixes: 737f30e1c3ab ("net/hns3: support command interface with firmware")

Signed-off-by: Hongbo Zheng <zhenghongbo3@huawei.com>
Signed-off-by: Wei Hu (Xavier) <xavier.huwei@huawei.com>
This commit is contained in:
Hongbo Zheng 2019-10-25 20:37:04 +08:00 committed by Ferruh Yigit
parent ad7cf94823
commit 1a028f2bea

View File

@ -359,7 +359,7 @@ static int hns3_cmd_poll_reply(struct hns3_hw *hw)
timeout++;
} while (timeout < hw->cmq.tx_timeout);
hns3_err(hw, "Wait for reply timeout");
return -EBADE;
return -ETIME;
}
/*