net/ice: add DCF hardware initialization
[dpdk.git] / drivers / net / qede / base / ecore_dcbx.c
index 7981c42..ccd4383 100644 (file)
@@ -159,7 +159,7 @@ ecore_dcbx_set_params(struct ecore_dcbx_results *p_data,
        if (OSAL_TEST_BIT(ECORE_MF_UFP_SPECIFIC, &p_hwfn->p_dev->mf_bits) &&
            (type == DCBX_PROTOCOL_ROCE)) {
                ecore_wr(p_hwfn, p_ptt, DORQ_REG_TAG1_OVRD_MODE, 1);
-               ecore_wr(p_hwfn, p_ptt, DORQ_REG_PF_PCP_BB_K2, prio << 1);
+               ecore_wr(p_hwfn, p_ptt, DORQ_REG_PF_PCP, prio << 1);
        }
 }
 
@@ -310,8 +310,9 @@ ecore_dcbx_process_tlv(struct ecore_hwfn *p_hwfn, struct ecore_ptt *p_ptt,
                        continue;
 
                /* if no app tlv was present, don't override in FW */
-               ecore_dcbx_update_app_info(p_data, p_hwfn, p_ptt, false,
-                                          priority, tc, type);
+               ecore_dcbx_update_app_info(p_data, p_hwfn, p_ptt,
+                                         p_data->arr[DCBX_PROTOCOL_ETH].enable,
+                                         priority, tc, type);
        }
 
        return ECORE_SUCCESS;
@@ -325,7 +326,7 @@ ecore_dcbx_process_mib_info(struct ecore_hwfn *p_hwfn, struct ecore_ptt *p_ptt)
 {
        struct dcbx_app_priority_feature *p_app;
        struct dcbx_app_priority_entry *p_tbl;
-       struct ecore_dcbx_results data = { 0 };
+       struct ecore_dcbx_results data;
        struct dcbx_ets_feature *p_ets;
        struct ecore_hw_info *p_info;
        u32 pri_tc_tbl, flags;
@@ -345,6 +346,7 @@ ecore_dcbx_process_mib_info(struct ecore_hwfn *p_hwfn, struct ecore_ptt *p_ptt)
        p_info = &p_hwfn->hw_info;
        num_entries = GET_MFW_FIELD(p_app->flags, DCBX_APP_NUM_ENTRIES);
 
+       OSAL_MEMSET(&data, 0, sizeof(struct ecore_dcbx_results));
        rc = ecore_dcbx_process_tlv(p_hwfn, p_ptt, &data, p_tbl, pri_tc_tbl,
                                    num_entries, dcbx_version);
        if (rc != ECORE_SUCCESS)