DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] net/ixgbe: firmware status check
@ 2018-09-07 15:01 Xiaoyun Li
  2018-09-13  2:27 ` Zhang, Qi Z
  2018-09-26  9:04 ` [dpdk-dev] [PATCH v2] " Xiaoyun Li
  0 siblings, 2 replies; 5+ messages in thread
From: Xiaoyun Li @ 2018-09-07 15:01 UTC (permalink / raw)
  To: wenzhuo.lu, dev, helin.zhang, jingjing.wu; +Cc: Xiaoyun Li

Check the firmware status at init time. If the firmware is in
recovery mode, alert the user to check it.

Signed-off-by: Xiaoyun Li <xiaoyun.li@intel.com>
---
v1:
 * This patch needs base code updating which will be done later.
---
 drivers/net/ixgbe/ixgbe_ethdev.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_ethdev.c
index 26b1927..263c72b 100644
--- a/drivers/net/ixgbe/ixgbe_ethdev.c
+++ b/drivers/net/ixgbe/ixgbe_ethdev.c
@@ -1107,6 +1107,14 @@ eth_ixgbe_dev_init(struct rte_eth_dev *eth_dev, void *init_params __rte_unused)
 	hw->hw_addr = (void *)pci_dev->mem_resource[0].addr;
 	hw->allow_unsupported_sfp = 1;
 
+	if (hw->mac.ops.fw_recovery_mode && hw->mac.ops.fw_recovery_mode(hw)) {
+		PMD_INIT_LOG(ERR, "\nERROR:"
+			"Firmware recovery mode detected. Limiting functionality.\n"
+			"Refer to the Intel(R) Ethernet Adapters and Devices "
+			"User Guide for details on firmware recovery mode.");
+		return -EIO;
+	}
+
 	/* Initialize the shared code (base driver) */
 #ifdef RTE_LIBRTE_IXGBE_BYPASS
 	diag = ixgbe_bypass_init_shared_code(hw);
-- 
2.7.4

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

* Re: [dpdk-dev] [PATCH] net/ixgbe: firmware status check
  2018-09-07 15:01 [dpdk-dev] [PATCH] net/ixgbe: firmware status check Xiaoyun Li
@ 2018-09-13  2:27 ` Zhang, Qi Z
  2018-09-26  9:04 ` [dpdk-dev] [PATCH v2] " Xiaoyun Li
  1 sibling, 0 replies; 5+ messages in thread
From: Zhang, Qi Z @ 2018-09-13  2:27 UTC (permalink / raw)
  To: Li, Xiaoyun, Lu, Wenzhuo, dev, Zhang, Helin, Wu, Jingjing; +Cc: Li, Xiaoyun



> -----Original Message-----
> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Xiaoyun Li
> Sent: Friday, September 7, 2018 11:01 PM
> To: Lu, Wenzhuo <wenzhuo.lu@intel.com>; dev@dpdk.org; Zhang, Helin
> <helin.zhang@intel.com>; Wu, Jingjing <jingjing.wu@intel.com>
> Cc: Li, Xiaoyun <xiaoyun.li@intel.com>
> Subject: [dpdk-dev] [PATCH] net/ixgbe: firmware status check
> 
> Check the firmware status at init time. If the firmware is in recovery mode,
> alert the user to check it.
> 
> Signed-off-by: Xiaoyun Li <xiaoyun.li@intel.com>

Acked-by: Qi Zhang <qi.z.zhang@intel.com>

Applied to dpdk-next-net-intel.

Thanks
Qi

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

* [dpdk-dev] [PATCH v2] net/ixgbe: firmware status check
  2018-09-07 15:01 [dpdk-dev] [PATCH] net/ixgbe: firmware status check Xiaoyun Li
  2018-09-13  2:27 ` Zhang, Qi Z
@ 2018-09-26  9:04 ` Xiaoyun Li
  2018-09-26 10:58   ` Zhang, Qi Z
  1 sibling, 1 reply; 5+ messages in thread
From: Xiaoyun Li @ 2018-09-26  9:04 UTC (permalink / raw)
  To: wenzhuo.lu, qi.z.zhang, ferruh.yigit; +Cc: dev, Xiaoyun Li

Check the firmware status at init time. If the firmware is in
recovery mode, alert the user to check it.

Signed-off-by: Xiaoyun Li <xiaoyun.li@intel.com>
---
v2:
 * The check should be after the shared code init. Fix it.
---
 drivers/net/ixgbe/ixgbe_ethdev.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_ethdev.c
index cee886754..192ebd285 100644
--- a/drivers/net/ixgbe/ixgbe_ethdev.c
+++ b/drivers/net/ixgbe/ixgbe_ethdev.c
@@ -1119,6 +1119,14 @@ eth_ixgbe_dev_init(struct rte_eth_dev *eth_dev, void *init_params __rte_unused)
 		return -EIO;
 	}
 
+	if (hw->mac.ops.fw_recovery_mode && hw->mac.ops.fw_recovery_mode(hw)) {
+		PMD_INIT_LOG(ERR, "\nERROR: "
+			"Firmware recovery mode detected. Limiting functionality.\n"
+			"Refer to the Intel(R) Ethernet Adapters and Devices "
+			"User Guide for details on firmware recovery mode.");
+		return -EIO;
+	}
+
 	/* pick up the PCI bus settings for reporting later */
 	ixgbe_get_bus_info(hw);
 
-- 
2.17.1

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

* Re: [dpdk-dev] [PATCH v2] net/ixgbe: firmware status check
  2018-09-26  9:04 ` [dpdk-dev] [PATCH v2] " Xiaoyun Li
@ 2018-09-26 10:58   ` Zhang, Qi Z
  2018-09-26 12:31     ` Ferruh Yigit
  0 siblings, 1 reply; 5+ messages in thread
From: Zhang, Qi Z @ 2018-09-26 10:58 UTC (permalink / raw)
  To: Li, Xiaoyun, Lu, Wenzhuo, Yigit, Ferruh; +Cc: dev



> -----Original Message-----
> From: Li, Xiaoyun
> Sent: Wednesday, September 26, 2018 5:05 PM
> To: Lu, Wenzhuo <wenzhuo.lu@intel.com>; Zhang, Qi Z
> <qi.z.zhang@intel.com>; Yigit, Ferruh <ferruh.yigit@intel.com>
> Cc: dev@dpdk.org; Li, Xiaoyun <xiaoyun.li@intel.com>
> Subject: [PATCH v2] net/ixgbe: firmware status check
> 
> Check the firmware status at init time. If the firmware is in recovery mode,
> alert the user to check it.
> 
> Signed-off-by: Xiaoyun Li <xiaoyun.li@intel.com>

Acked-by: Qi Zhang <qi.z.zhang@intel.com>

Applied to dpdk-next-net-intel.

Thanks
Qi

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

* Re: [dpdk-dev] [PATCH v2] net/ixgbe: firmware status check
  2018-09-26 10:58   ` Zhang, Qi Z
@ 2018-09-26 12:31     ` Ferruh Yigit
  0 siblings, 0 replies; 5+ messages in thread
From: Ferruh Yigit @ 2018-09-26 12:31 UTC (permalink / raw)
  To: Zhang, Qi Z, Li, Xiaoyun, Lu, Wenzhuo; +Cc: dev

On 9/26/2018 11:58 AM, Zhang, Qi Z wrote:
> 
> 
>> -----Original Message-----
>> From: Li, Xiaoyun
>> Sent: Wednesday, September 26, 2018 5:05 PM
>> To: Lu, Wenzhuo <wenzhuo.lu@intel.com>; Zhang, Qi Z
>> <qi.z.zhang@intel.com>; Yigit, Ferruh <ferruh.yigit@intel.com>
>> Cc: dev@dpdk.org; Li, Xiaoyun <xiaoyun.li@intel.com>
>> Subject: [PATCH v2] net/ixgbe: firmware status check
>>
>> Check the firmware status at init time. If the firmware is in recovery mode,
>> alert the user to check it.
>>
>> Signed-off-by: Xiaoyun Li <xiaoyun.li@intel.com>
> 
> Acked-by: Qi Zhang <qi.z.zhang@intel.com>
> 
> Applied to dpdk-next-net-intel.

Prev version was in next-net, replaced with this one.

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

end of thread, other threads:[~2018-09-26 12:31 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-09-07 15:01 [dpdk-dev] [PATCH] net/ixgbe: firmware status check Xiaoyun Li
2018-09-13  2:27 ` Zhang, Qi Z
2018-09-26  9:04 ` [dpdk-dev] [PATCH v2] " Xiaoyun Li
2018-09-26 10:58   ` Zhang, Qi Z
2018-09-26 12:31     ` 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).