summaryrefslogtreecommitdiff
path: root/drivers/net/qede
diff options
context:
space:
mode:
authorRasesh Mody <rasesh.mody@cavium.com>2018-09-08 13:30:52 -0700
committerFerruh Yigit <ferruh.yigit@intel.com>2018-09-28 01:41:01 +0200
commit4fe58a3ecfb0bbabc05a6e05191534775c9dbd7b (patch)
treeed4f35e7586ab1db4d0d8fd39c0276ccb902af76 /drivers/net/qede
parentebbc55b87185544f37b9552a39ad8899da806fa5 (diff)
downloaddpdk-next-eventdev-4fe58a3ecfb0bbabc05a6e05191534775c9dbd7b.zip
dpdk-next-eventdev-4fe58a3ecfb0bbabc05a6e05191534775c9dbd7b.tar.gz
dpdk-next-eventdev-4fe58a3ecfb0bbabc05a6e05191534775c9dbd7b.tar.xz
net/qede/base: get pre-negotiated values for stag and bw
Request management FW for STAG and bandwidth values negotiated prior to the driver load. Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
Diffstat (limited to 'drivers/net/qede')
-rw-r--r--drivers/net/qede/base/ecore_dev.c14
-rw-r--r--drivers/net/qede/base/mcp_public.h3
2 files changed, 17 insertions, 0 deletions
diff --git a/drivers/net/qede/base/ecore_dev.c b/drivers/net/qede/base/ecore_dev.c
index be68a12..958d7a0 100644
--- a/drivers/net/qede/base/ecore_dev.c
+++ b/drivers/net/qede/base/ecore_dev.c
@@ -2591,6 +2591,20 @@ enum _ecore_status_t ecore_hw_init(struct ecore_dev *p_dev,
}
if (IS_PF(p_dev)) {
+ /* Get pre-negotiated values for stag, bandwidth etc. */
+ p_hwfn = ECORE_LEADING_HWFN(p_dev);
+ DP_VERBOSE(p_hwfn, ECORE_MSG_SPQ,
+ "Sending GET_OEM_UPDATES command to trigger stag/bandwidth attention handling\n");
+ rc = ecore_mcp_cmd(p_hwfn, p_hwfn->p_main_ptt,
+ DRV_MSG_CODE_GET_OEM_UPDATES,
+ 1 << DRV_MB_PARAM_DUMMY_OEM_UPDATES_OFFSET,
+ &resp, &param);
+ if (rc != ECORE_SUCCESS)
+ DP_NOTICE(p_hwfn, false,
+ "Failed to send GET_OEM_UPDATES attention request\n");
+ }
+
+ if (IS_PF(p_dev)) {
p_hwfn = ECORE_LEADING_HWFN(p_dev);
drv_mb_param = STORM_FW_VERSION;
rc = ecore_mcp_cmd(p_hwfn, p_hwfn->p_main_ptt,
diff --git a/drivers/net/qede/base/mcp_public.h b/drivers/net/qede/base/mcp_public.h
index 5575d9d..e9f3350 100644
--- a/drivers/net/qede/base/mcp_public.h
+++ b/drivers/net/qede/base/mcp_public.h
@@ -1598,6 +1598,9 @@ struct public_drv_mb {
#define DRV_MB_PARAM_ESWITCH_MODE_VEB 0x1
#define DRV_MB_PARAM_ESWITCH_MODE_VEPA 0x2
+#define DRV_MB_PARAM_DUMMY_OEM_UPDATES_MASK 0x1
+#define DRV_MB_PARAM_DUMMY_OEM_UPDATES_OFFSET 0
+
#define DRV_MB_PARAM_SET_LED_MODE_OPER 0x0
#define DRV_MB_PARAM_SET_LED_MODE_ON 0x1
#define DRV_MB_PARAM_SET_LED_MODE_OFF 0x2