[PATCH v3 15/15] net/pfe: remove setting unused value

nipun.gupta at nxp.com nipun.gupta at nxp.com
Mon Jan 3 11:01:29 CET 2022


From: Apeksha Gupta <apeksha.gupta at nxp.com>

remove setting link status where it is not being used

Signed-off-by: Apeksha Gupta <apeksha.gupta at nxp.com>
---
 drivers/net/pfe/pfe_ethdev.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/net/pfe/pfe_ethdev.c b/drivers/net/pfe/pfe_ethdev.c
index 047010e15e..e5aaf5dcfd 100644
--- a/drivers/net/pfe/pfe_ethdev.c
+++ b/drivers/net/pfe/pfe_ethdev.c
@@ -587,8 +587,7 @@ pfe_eth_link_update(struct rte_eth_dev *dev, int wait_to_complete __rte_unused)
 		ret = ioctl(priv->link_fd, ioctl_cmd, &lstatus);
 		if (ret != 0) {
 			PFE_PMD_ERR("Unable to fetch link status (ioctl)\n");
-			/* use dummy link value */
-			link.link_status = 1;
+			return -1;
 		}
 		PFE_PMD_DEBUG("Fetched link state (%d) for dev %d.\n",
 			      lstatus, priv->id);
-- 
2.17.1



More information about the dev mailing list