patches for DPDK stable branches
 help / color / mirror / Atom feed
* [dpdk-stable] [PATCH] net/ixgbe: fix calling null function of VF
@ 2017-05-10  7:00 Wei Dai
  2017-05-10  9:34 ` [dpdk-stable] [dpdk-dev] " Gregory Etelson
  2017-05-10  9:50 ` [dpdk-stable] " Ferruh Yigit
  0 siblings, 2 replies; 6+ messages in thread
From: Wei Dai @ 2017-05-10  7:00 UTC (permalink / raw)
  To: wenzhuo.lu, konstantin.ananyev; +Cc: dev, Wei Dai, stable

hw->mac.ops.get_media-type() of ixgbe VF is NULL and should not
be called directly. It had better be replaced by calling
ixgbe_get_media_type( ) to avoid crash.

Fixes: c12d22f65b13 ("net/ixgbe: ensure link status is updated")
Cc: stable@dpdk.org

Signed-off-by: Wei Dai <wei.dai@intel.com>
---
 drivers/net/ixgbe/ixgbe_ethdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_ethdev.c
index ec667d8..ed2baec 100644
--- a/drivers/net/ixgbe/ixgbe_ethdev.c
+++ b/drivers/net/ixgbe/ixgbe_ethdev.c
@@ -3799,7 +3799,7 @@ ixgbe_dev_link_update(struct rte_eth_dev *dev, int wait_to_complete)
 	hw->mac.get_link_status = true;
 
 	if ((intr->flags & IXGBE_FLAG_NEED_LINK_CONFIG) &&
-		hw->mac.ops.get_media_type(hw) == ixgbe_media_type_fiber) {
+		ixgbe_get_media_type(hw) == ixgbe_media_type_fiber) {
 		speed = hw->phy.autoneg_advertised;
 		if (!speed)
 			ixgbe_get_link_capabilities(hw, &speed, &autoneg);
-- 
2.7.4

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2017-05-10 12:33 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-10  7:00 [dpdk-stable] [PATCH] net/ixgbe: fix calling null function of VF Wei Dai
2017-05-10  9:34 ` [dpdk-stable] [dpdk-dev] " Gregory Etelson
2017-05-10  9:49   ` Ferruh Yigit
2017-05-10  9:50 ` [dpdk-stable] " Ferruh Yigit
2017-05-10 12:20   ` Roger B. Melton
2017-05-10 12:33     ` Laurent Hardy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).