DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] net/ixgbe: correct error when SFP not present
@ 2017-01-24  8:14 Wei Dai
  2017-01-24  8:51 ` Lu, Wenzhuo
  0 siblings, 1 reply; 3+ messages in thread
From: Wei Dai @ 2017-01-24  8:14 UTC (permalink / raw)
  To: dev; +Cc: helin.zhang, konstantin.ananyev, Wei Dai

Ignore the error=IXGBE_ERR_SFP_NOT_PRESENT when SFP is not present.
If it is not ignored, testpmd will in the NIC initialization process.
Ixgbe kernel driver ignores this error and works well. So DPDK
does same thing.

Signed-off-by: Wei Dai <wei.dai@intel.com>
Signed-off-by: Helin Zhang <helin.zhang@intel.com>
Tested-by: Yuan Peng <yuan.peng@intel.com>
---
 drivers/net/ixgbe/ixgbe_ethdev.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_ethdev.c
index bdf4e2b..ae7fb86 100644
--- a/drivers/net/ixgbe/ixgbe_ethdev.c
+++ b/drivers/net/ixgbe/ixgbe_ethdev.c
@@ -898,6 +898,8 @@ ixgbe_pf_reset_hw(struct ixgbe_hw *hw)
 	IXGBE_WRITE_REG(hw, IXGBE_CTRL_EXT, ctrl_ext);
 	IXGBE_WRITE_FLUSH(hw);
 
+	if (status == IXGBE_ERR_SFP_NOT_PRESENT)
+		status = IXGBE_SUCCESS;
 	return status;
 }
 
@@ -1237,6 +1239,9 @@ eth_ixgbe_dev_init(struct rte_eth_dev *eth_dev)
 		diag = ixgbe_init_hw(hw);
 	}
 
+	if (diag == IXGBE_ERR_SFP_NOT_PRESENT)
+		diag = IXGBE_SUCCESS;
+
 	if (diag == IXGBE_ERR_EEPROM_VERSION) {
 		PMD_INIT_LOG(ERR, "This device is a pre-production adapter/"
 			     "LOM.  Please be aware there may be issues associated "
-- 
2.7.4

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

* Re: [dpdk-dev] [PATCH] net/ixgbe: correct error when SFP not present
  2017-01-24  8:14 [dpdk-dev] [PATCH] net/ixgbe: correct error when SFP not present Wei Dai
@ 2017-01-24  8:51 ` Lu, Wenzhuo
  2017-01-24 15:55   ` Ferruh Yigit
  0 siblings, 1 reply; 3+ messages in thread
From: Lu, Wenzhuo @ 2017-01-24  8:51 UTC (permalink / raw)
  To: Dai, Wei, dev; +Cc: Zhang, Helin, Ananyev, Konstantin, Dai, Wei

Hi,


> -----Original Message-----
> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Wei Dai
> Sent: Tuesday, January 24, 2017 4:14 PM
> To: dev@dpdk.org
> Cc: Zhang, Helin; Ananyev, Konstantin; Dai, Wei
> Subject: [dpdk-dev] [PATCH] net/ixgbe: correct error when SFP not present
> 
> Ignore the error=IXGBE_ERR_SFP_NOT_PRESENT when SFP is not present.
> If it is not ignored, testpmd will in the NIC initialization process.
> Ixgbe kernel driver ignores this error and works well. So DPDK does same thing.
> 
> Signed-off-by: Wei Dai <wei.dai@intel.com>
> Signed-off-by: Helin Zhang <helin.zhang@intel.com>
> Tested-by: Yuan Peng <yuan.peng@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>

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

* Re: [dpdk-dev] [PATCH] net/ixgbe: correct error when SFP not present
  2017-01-24  8:51 ` Lu, Wenzhuo
@ 2017-01-24 15:55   ` Ferruh Yigit
  0 siblings, 0 replies; 3+ messages in thread
From: Ferruh Yigit @ 2017-01-24 15:55 UTC (permalink / raw)
  To: Lu, Wenzhuo, Dai, Wei, dev; +Cc: Zhang, Helin, Ananyev, Konstantin

On 1/24/2017 8:51 AM, Lu, Wenzhuo wrote:
<...>
>>
>> Ignore the error=IXGBE_ERR_SFP_NOT_PRESENT when SFP is not present.
>> If it is not ignored, testpmd will in the NIC initialization process.
>> Ixgbe kernel driver ignores this error and works well. So DPDK does same thing.
>>
>> Signed-off-by: Wei Dai <wei.dai@intel.com>
>> Signed-off-by: Helin Zhang <helin.zhang@intel.com>
>> Tested-by: Yuan Peng <yuan.peng@intel.com>
> Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>

Applied to dpdk-next-net/master, thanks.

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

end of thread, other threads:[~2017-01-24 15:55 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-01-24  8:14 [dpdk-dev] [PATCH] net/ixgbe: correct error when SFP not present Wei Dai
2017-01-24  8:51 ` Lu, Wenzhuo
2017-01-24 15:55   ` Ferruh Yigit

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).