net/hns3: fix error code in xstats
authorHuisong Li <lihuisong@huawei.com>
Wed, 6 Jan 2021 03:46:29 +0000 (11:46 +0800)
committerFerruh Yigit <ferruh.yigit@intel.com>
Tue, 19 Jan 2021 02:30:13 +0000 (03:30 +0100)
commitdcb33fd7602408dbb7c3bc78537667b3ee33e05c
tree5a03aa268940a5278554e8f0a805ecce90158ceb
parent3213d584b698f41dbef14599a41ab0a7a78739b4
net/hns3: fix error code in xstats

The ethdev API has processed the failure to obtain
xstats statistics. Therefore, driver should return
an error code instead of 0 in 'hns3_dev_xstats_get'
API.

Fixes: 8839c5e202f3 ("net/hns3: support device stats")
Cc: stable@dpdk.org
Signed-off-by: Huisong Li <lihuisong@huawei.com>
Signed-off-by: Lijun Ou <oulijun@huawei.com>
drivers/net/hns3/hns3_stats.c