net/mlx5: rearrange creation of WQ and CQ object
[dpdk.git] / drivers / net / bnxt / bnxt_hwrm.c
index 43e3e27..b269526 100644 (file)
@@ -530,6 +530,9 @@ int bnxt_hwrm_set_l2_filter(struct bnxt *bp,
 
        HWRM_PREP(&req, HWRM_CFA_L2_FILTER_ALLOC, BNXT_USE_CHIMP_MB);
 
+       /* PMD does not support XDP and RoCE */
+       filter->flags |= HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_XDP_DISABLE |
+                       HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_TRAFFIC_L2;
        req.flags = rte_cpu_to_le_32(filter->flags);
 
        enables = filter->enables |
@@ -936,6 +939,10 @@ int bnxt_hwrm_func_driver_register(struct bnxt *bp)
                req.async_event_fwd[1] |=
                        rte_cpu_to_le_32(ASYNC_CMPL_EVENT_ID_DBG_NOTIFICATION);
 
+       if (BNXT_VF_IS_TRUSTED(bp))
+               req.async_event_fwd[1] |=
+               rte_cpu_to_le_32(ASYNC_CMPL_EVENT_ID_DEFAULT_VNIC_CHANGE);
+
        rc = bnxt_hwrm_send_message(bp, &req, sizeof(req), BNXT_USE_CHIMP_MB);
 
        HWRM_CHECK_RESULT();
@@ -2260,8 +2267,8 @@ int bnxt_hwrm_vnic_tpa_cfg(struct bnxt *bp,
                                HWRM_VNIC_TPA_CFG_INPUT_FLAGS_GRO |
                                HWRM_VNIC_TPA_CFG_INPUT_FLAGS_AGG_WITH_ECN |
                        HWRM_VNIC_TPA_CFG_INPUT_FLAGS_AGG_WITH_SAME_GRE_SEQ);
-               req.max_agg_segs = rte_cpu_to_le_16(BNXT_TPA_MAX_AGGS(bp));
-               req.max_aggs = rte_cpu_to_le_16(BNXT_TPA_MAX_SEGS(bp));
+               req.max_aggs = rte_cpu_to_le_16(BNXT_TPA_MAX_AGGS(bp));
+               req.max_agg_segs = rte_cpu_to_le_16(BNXT_TPA_MAX_SEGS(bp));
                req.min_agg_len = rte_cpu_to_le_32(512);
        }
        req.vnic_id = rte_cpu_to_le_16(vnic->fw_vnic_id);
@@ -3616,17 +3623,19 @@ int bnxt_hwrm_tunnel_dst_port_alloc(struct bnxt *bp, uint16_t port,
 
        HWRM_PREP(&req, HWRM_TUNNEL_DST_PORT_ALLOC, BNXT_USE_CHIMP_MB);
        req.tunnel_type = tunnel_type;
-       req.tunnel_dst_port_val = port;
+       req.tunnel_dst_port_val = rte_cpu_to_be_16(port);
        rc = bnxt_hwrm_send_message(bp, &req, sizeof(req), BNXT_USE_CHIMP_MB);
        HWRM_CHECK_RESULT();
 
        switch (tunnel_type) {
        case HWRM_TUNNEL_DST_PORT_ALLOC_INPUT_TUNNEL_TYPE_VXLAN:
-               bp->vxlan_fw_dst_port_id = resp->tunnel_dst_port_id;
+               bp->vxlan_fw_dst_port_id =
+                       rte_le_to_cpu_16(resp->tunnel_dst_port_id);
                bp->vxlan_port = port;
                break;
        case HWRM_TUNNEL_DST_PORT_ALLOC_INPUT_TUNNEL_TYPE_GENEVE:
-               bp->geneve_fw_dst_port_id = resp->tunnel_dst_port_id;
+               bp->geneve_fw_dst_port_id =
+                       rte_le_to_cpu_16(resp->tunnel_dst_port_id);
                bp->geneve_port = port;
                break;
        default: