From: Wenzhuo Lu Date: Wed, 23 Jan 2019 05:30:29 +0000 (+0800) Subject: net/ice: fix link speed X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=91c7b92061e6f1c764f54e5510908010f63033f9;p=dpdk.git net/ice: fix link speed Fix the issue that the link speed is unknown. Fixes: 690175ee51bf ("net/ice: support getting device information") Fixes: cf911d90e366 ("net/ice: support link update") Signed-off-by: Wenzhuo Lu Acked-by: Qi Zhang --- diff --git a/drivers/net/ice/ice_ethdev.c b/drivers/net/ice/ice_ethdev.c index b4501155ce..6ab66faebc 100644 --- a/drivers/net/ice/ice_ethdev.c +++ b/drivers/net/ice/ice_ethdev.c @@ -1899,7 +1899,9 @@ ice_dev_info_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info) ETH_LINK_SPEED_10G | ETH_LINK_SPEED_20G | ETH_LINK_SPEED_25G | - ETH_LINK_SPEED_40G; + ETH_LINK_SPEED_40G | + ETH_LINK_SPEED_50G | + ETH_LINK_SPEED_100G; dev_info->nb_rx_queues = dev->data->nb_rx_queues; dev_info->nb_tx_queues = dev->data->nb_tx_queues; @@ -2010,6 +2012,12 @@ ice_link_update(struct rte_eth_dev *dev, __rte_unused int wait_to_complete) case ICE_AQ_LINK_SPEED_40GB: link.link_speed = ETH_SPEED_NUM_40G; break; + case ICE_AQ_LINK_SPEED_50GB: + link.link_speed = ETH_SPEED_NUM_50G; + break; + case ICE_AQ_LINK_SPEED_100GB: + link.link_speed = ETH_SPEED_NUM_100G; + break; case ICE_AQ_LINK_SPEED_UNKNOWN: default: PMD_DRV_LOG(ERR, "Unknown link speed");