net/bntx: use new API to get iova address XXX
[dpdk.git] / drivers / net / bnxt / hsi_struct_def_dpdk.h
index 2fcfce6..c16edba 100644 (file)
 
 #ifndef _HSI_STRUCT_DEF_DPDK_
 #define _HSI_STRUCT_DEF_DPDK_
-/* HSI and HWRM Specification 1.7.7 */
+/* HSI and HWRM Specification 1.8.2 */
 #define HWRM_VERSION_MAJOR     1
-#define HWRM_VERSION_MINOR     7
-#define HWRM_VERSION_UPDATE    7
+#define HWRM_VERSION_MINOR     8
+#define HWRM_VERSION_UPDATE    2
 
-#define HWRM_VERSION_STR       "1.7.7"
+#define HWRM_VERSION_RSVD      0 /* non-zero means beta version */
+
+#define HWRM_VERSION_STR       "1.8.2.0"
 /*
  * Following is the signature for HWRM message field that indicates not
  * applicable  (All F's). Need to cast it the size of the field if needed.
  */
 #define HWRM_NA_SIGNATURE      ((uint32_t)(-1))
 #define HWRM_MAX_REQ_LEN       (128)  /* hwrm_func_buf_rgtr */
-#define HWRM_MAX_RESP_LEN      (248)  /* hwrm_selftest_qlist */
+#define HWRM_MAX_RESP_LEN      (280)  /* hwrm_selftest_qlist */
 #define HW_HASH_INDEX_SIZE      0x80   /* 7 bit indirection table index. */
 #define HW_HASH_KEY_SIZE       40
 #define HWRM_RESP_VALID_KEY    1 /* valid key for HWRM response */
 #define HWRM_ROCE_SP_HSI_VERSION_MAJOR 1
-#define HWRM_ROCE_SP_HSI_VERSION_MINOR 7
-#define HWRM_ROCE_SP_HSI_VERSION_UPDATE        4
+#define HWRM_ROCE_SP_HSI_VERSION_MINOR 8
+#define HWRM_ROCE_SP_HSI_VERSION_UPDATE        2
 
 /*
  * Request types
 #define HWRM_VNIC_RSS_QCFG             (UINT32_C(0x47))
 #define HWRM_VNIC_PLCMODES_CFG         (UINT32_C(0x48))
 #define HWRM_VNIC_PLCMODES_QCFG                (UINT32_C(0x49))
+#define HWRM_VNIC_QCAPS                        (UINT32_C(0x4a))
 #define HWRM_RING_ALLOC                        (UINT32_C(0x50))
 #define HWRM_RING_FREE                 (UINT32_C(0x51))
-#define HWRM_RING_CMPL_RING_CFG_AGGINT_PARAM   (UINT32_C(0x53))
+#define HWRM_RING_CMPL_RING_QAGGINT_PARAMS     (UINT32_C(0x52))
+#define HWRM_RING_CMPL_RING_CFG_AGGINT_PARAMS  (UINT32_C(0x53))
 #define HWRM_RING_RESET                        (UINT32_C(0x5e))
 #define HWRM_RING_GRP_ALLOC            (UINT32_C(0x60))
-#define HWRM_RING_GRP_ALLOC            (UINT32_C(0x60))
 #define HWRM_RING_GRP_FREE             (UINT32_C(0x61))
 #define HWRM_VNIC_RSS_COS_LB_CTX_ALLOC (UINT32_C(0x70))
 #define HWRM_VNIC_RSS_COS_LB_CTX_FREE  (UINT32_C(0x71))
 #define HWRM_CFA_L2_FILTER_CFG         (UINT32_C(0x92))
 #define HWRM_CFA_L2_SET_RX_MASK                (UINT32_C(0x93))
     /* Reserved for future use */
-#define RESERVED4                      (UINT32_C(0x94))
+#define HWRM_CFA_VLAN_ANTISPOOF_CFG    (UINT32_C(0x94))
 #define HWRM_CFA_TUNNEL_FILTER_ALLOC   (UINT32_C(0x95))
 #define HWRM_CFA_TUNNEL_FILTER_FREE    (UINT32_C(0x96))
 #define HWRM_CFA_NTUPLE_FILTER_ALLOC   (UINT32_C(0x99))
 #define HWRM_CFA_NTUPLE_FILTER_FREE    (UINT32_C(0x9a))
 #define HWRM_CFA_NTUPLE_FILTER_CFG     (UINT32_C(0x9b))
+#define HWRM_CFA_EM_FLOW_ALLOC         (UINT32_C(0x9c))
+#define HWRM_CFA_EM_FLOW_FREE          (UINT32_C(0x9d))
+#define HWRM_CFA_EM_FLOW_CFG           (UINT32_C(0x9e))
 #define HWRM_TUNNEL_DST_PORT_QUERY     (UINT32_C(0xa0))
 #define HWRM_TUNNEL_DST_PORT_ALLOC     (UINT32_C(0xa1))
 #define HWRM_TUNNEL_DST_PORT_FREE      (UINT32_C(0xa2))
 #define HWRM_STAT_CTX_FREE             (UINT32_C(0xb1))
 #define HWRM_STAT_CTX_QUERY            (UINT32_C(0xb2))
 #define HWRM_STAT_CTX_CLR_STATS                (UINT32_C(0xb3))
+#define HWRM_FW_RESET                  (UINT32_C(0xc0))
+#define HWRM_FW_QSTATUS                        (UINT32_C(0xc1))
 #define HWRM_EXEC_FWD_RESP             (UINT32_C(0xd0))
 #define HWRM_REJECT_FWD_RESP           (UINT32_C(0xd1))
 #define HWRM_FWD_RESP                  (UINT32_C(0xd2))
@@ -812,8 +820,6 @@ struct rx_pkt_cmpl {
         * packet. Length = 32B
         */
        #define RX_PKT_CMPL_TYPE_RX_L2                  UINT32_C(0x11)
-       #define RX_PKT_CMPL_TYPE_RX_L2_TPA_START        UINT32_C(0x13)
-       #define RX_PKT_CMPL_TYPE_RX_L2_TPA_END          UINT32_C(0x15)
        /*
         * When this bit is '1', it indicates a packet that has an error
         * of some type. Type of error is indicated in error_flags.
@@ -1797,6 +1803,8 @@ struct hwrm_async_event_cmpl {
                UINT32_C(0x32)
        /* VF Configuration Change */
        #define HWRM_ASYNC_EVENT_CMPL_EVENT_ID_VF_CFG_CHANGE    UINT32_C(0x33)
+       /* LLFC/PFC Configuration Change */
+       #define HWRM_ASYNC_EVENT_CMPL_EVENT_ID_LLFC_PFC_CHANGE UINT32_C(0x34)
        /* HWRM Error */
        #define HWRM_ASYNC_EVENT_CMPL_EVENT_ID_HWRM_ERROR       UINT32_C(0xff)
        uint32_t event_data2;
@@ -2114,9 +2122,18 @@ struct hwrm_ver_get_output {
         * This field returns the default request timeout value in
         * milliseconds.
         */
+       uint8_t init_pending;
+       /*
+        * This field will indicate if any subsystems is not fully
+        * initialized.
+        */
+       /*
+        * If set to 1, device is not ready. If set to 0, device is
+        * ready to accept all HWRM commands.
+        */
+       #define HWRM_VER_GET_OUTPUT_INIT_PENDING_DEV_NOT_RDY UINT32_C(0x1)
        uint8_t unused_0;
        uint8_t unused_1;
-       uint8_t unused_2;
        uint8_t valid;
        /*
         * This field is used in Output records to indicate that the
@@ -2243,6 +2260,122 @@ struct hwrm_func_reset_output {
         */
 } __attribute__((packed));
 
+/* hwrm_func_vf_cfg */
+/*
+ * Description: This command allows configuration of a VF by its driver. If this
+ * function is called by a PF driver, then the HWRM shall fail this command. If
+ * guest VLAN and/or MAC address are provided in this command, then the HWRM
+ * shall set up appropriate MAC/VLAN filters for the VF that is being
+ * configured. A VF driver should set VF MTU/MRU using this command prior to
+ * allocating RX VNICs or TX rings for the corresponding VF.
+ */
+/* Input (32 bytes) */
+struct hwrm_func_vf_cfg_input {
+       uint16_t req_type;
+       /*
+        * This value indicates what type of request this is. The format for the
+        * rest of the command is determined by this field.
+        */
+       uint16_t cmpl_ring;
+       /*
+        * This value indicates the what completion ring the request will be
+        * optionally completed on. If the value is -1, then no CR completion
+        * will be generated. Any other value must be a valid CR ring_id value
+        * for this function.
+        */
+       uint16_t seq_id;
+       /* This value indicates the command sequence number. */
+       uint16_t target_id;
+       /*
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function ids
+        * 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF - HWRM
+        */
+       uint64_t resp_addr;
+       /*
+        * This is the host address where the response will be written when the
+        * request is complete. This area must be 16B aligned and must be
+        * cleared to zero before the request is made.
+        */
+       uint32_t enables;
+       /* This bit must be '1' for the mtu field to be configured. */
+       #define HWRM_FUNC_VF_CFG_INPUT_ENABLES_MTU                 UINT32_C(0x1)
+       /* This bit must be '1' for the guest_vlan field to be configured. */
+       #define HWRM_FUNC_VF_CFG_INPUT_ENABLES_GUEST_VLAN          UINT32_C(0x2)
+       /*
+        * This bit must be '1' for the async_event_cr field to be configured.
+        */
+       #define HWRM_FUNC_VF_CFG_INPUT_ENABLES_ASYNC_EVENT_CR      UINT32_C(0x4)
+       /* This bit must be '1' for the dflt_mac_addr field to be configured. */
+       #define HWRM_FUNC_VF_CFG_INPUT_ENABLES_DFLT_MAC_ADDR       UINT32_C(0x8)
+       uint16_t mtu;
+       /*
+        * The maximum transmission unit requested on the function. The HWRM
+        * should make sure that the mtu of the function does not exceed the mtu
+        * of the physical port that this function is associated with. In
+        * addition to requesting mtu per function, it is possible to configure
+        * mtu per transmit ring. By default, the mtu of each transmit ring
+        * associated with a function is equal to the mtu of the function. The
+        * HWRM should make sure that the mtu of each transmit ring that is
+        * assigned to a function has a valid mtu.
+        */
+       uint16_t guest_vlan;
+       /*
+        * The guest VLAN for the function being configured. This field's format
+        * is same as 802.1Q Tag's Tag Control Information (TCI) format that
+        * includes both Priority Code Point (PCP) and VLAN Identifier (VID).
+        */
+       uint16_t async_event_cr;
+       /*
+        * ID of the target completion ring for receiving asynchronous event
+        * completions. If this field is not valid, then the HWRM shall use the
+        * default completion ring of the function that is being configured as
+        * the target completion ring for providing any asynchronous event
+        * completions for that function. If this field is valid, then the HWRM
+        * shall use the completion ring identified by this ID as the target
+        * completion ring for providing any asynchronous event completions for
+        * the function that is being configured.
+        */
+       uint8_t dflt_mac_addr[6];
+       /*
+        * This value is the current MAC address requested by the VF driver to
+        * be configured on this VF. A value of 00-00-00-00-00-00 indicates no
+        * MAC address configuration is requested by the VF driver. The parent
+        * PF driver may reject or overwrite this MAC address.
+        */
+} __attribute__((packed));
+
+/* Output (16 bytes) */
+
+struct hwrm_func_vf_cfg_output {
+       uint16_t error_code;
+       /*
+        * Pass/Fail or error type Note: receiver to verify the in parameters,
+        * and fail the call with an error when appropriate
+        */
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
+       /*
+        * This field is the length of the response in bytes. The last
+        * byte of the response is a valid flag that will read as '1'
+        * when the command has been completely written to memory.
+        */
+       uint32_t unused_0;
+       uint8_t unused_1;
+       uint8_t unused_2;
+       uint8_t unused_3;
+       uint8_t valid;
+       /*
+        * This field is used in Output records to indicate that the output is
+        * completely written to RAM. This field should be read as '1' to
+        * indicate that the output has been completely written. When writing a
+        * command completion or response to an internal processor, the order of
+        * writes has to be such that this field is written last.
+        */
+} __attribute__((packed));
+
 /* hwrm_func_qcaps */
 /*
  * Description: This command returns capabilities of a function. The input FID
@@ -2724,8 +2857,16 @@ struct hwrm_func_qcfg_output {
        #define HWRM_FUNC_QCFG_OUTPUT_PORT_PF_CNT_UNAVAIL       UINT32_C(0x0)
        uint16_t dflt_vnic_id;
        /* The default VNIC ID assigned to a function that is being queried. */
-       uint8_t unused_0;
-       uint8_t unused_1;
+       uint16_t max_mtu_configured;
+       /*
+        * This value specifies the MAX MTU that can be configured by
+        * host drivers. This 'max_mtu_configure' can be HW max MTU or
+        * OEM applications specified value. Host drivers can't
+        * configure the MTU greater than this value. Host drivers
+        * should read this value prior to configuring the MTU. FW will
+        * fail the host request with MTU greater than
+        * 'max_mtu_configured'.
+        */
        uint32_t min_bw;
        /*
         * Minimum BW allocated for this function. The HWRM will
@@ -2823,7 +2964,7 @@ struct hwrm_func_qcfg_output {
        #define HWRM_FUNC_QCFG_OUTPUT_EVB_MODE_VEB      UINT32_C(0x1)
        /* Virtual Ethernet Port Aggregator     (VEPA) */
        #define HWRM_FUNC_QCFG_OUTPUT_EVB_MODE_VEPA     UINT32_C(0x2)
-       uint8_t unused_2;
+       uint8_t unused_0;
        uint16_t alloc_vfs;
        /*
         * The number of VFs that are allocated to the function. This is
@@ -2843,7 +2984,7 @@ struct hwrm_func_qcfg_output {
         * The number of strict priority transmit rings out of currently
         * allocated TX rings to the function   (alloc_tx_rings).
         */
-       uint8_t unused_3;
+       uint8_t unused_1;
        uint8_t valid;
        /*
         * This field is used in Output records to indicate that the
@@ -3187,6 +3328,23 @@ struct hwrm_func_cfg_input {
         * command will be persistent over warm boot.
         */
        #define HWRM_FUNC_CFG_INPUT_FLAGS_VIRT_MAC_PERSIST      UINT32_C(0x800)
+       /*
+        * This bit only applies to the VF. If this bit is set, the
+        * statistic context counters will not be cleared when the
+        * statistic context is freed or a function reset is called on
+        * VF. This bit will be cleared when the PF is unloaded or a
+        * function reset is called on the PF.
+        */
+       #define HWRM_FUNC_CFG_INPUT_FLAGS_NO_AUTOCLEAR_STATISTIC        \
+               UINT32_C(0x1000)
+       /*
+        * This bit requests that the firmware test to see if all the
+        * assets requested in this command (i.e. number of TX rings)
+        * are available. The firmware will return an error if the
+        * requested assets are not available. The firwmare will NOT
+        * reserve the assets if they are available.
+        */
+       #define HWRM_FUNC_CFG_INPUT_FLAGS_TX_ASSETS_TEST UINT32_C(0x2000)
        uint32_t enables;
        /* This bit must be '1' for the mtu field to be configured. */
        #define HWRM_FUNC_CFG_INPUT_ENABLES_MTU UINT32_C(0x1)
@@ -4224,123 +4382,6 @@ struct hwrm_func_buf_unrgtr_output {
         */
 } __attribute__((packed));
 
-/* hwrm_func_vf_cfg */
-/*
- * Description: This command allows configuration of a VF by its driver. If this
- * function is called by a PF driver, then the HWRM shall fail this command. If
- * guest VLAN and/or MAC address are provided in this command, then the HWRM
- * shall set up appropriate MAC/VLAN filters for the VF that is being
- * configured. A VF driver should set VF MTU/MRU using this command prior to
- * allocating RX VNICs or TX rings for the corresponding VF.
- */
-/* Input (32 bytes) */
-
-struct hwrm_func_vf_cfg_input {
-       uint16_t req_type;
-       /*
-        * This value indicates what type of request this is. The format for the
-        * rest of the command is determined by this field.
-        */
-       uint16_t cmpl_ring;
-       /*
-        * This value indicates the what completion ring the request will be
-        * optionally completed on. If the value is -1, then no CR completion
-        * will be generated. Any other value must be a valid CR ring_id value
-        * for this function.
-        */
-       uint16_t seq_id;
-       /* This value indicates the command sequence number. */
-       uint16_t target_id;
-       /*
-        * Target ID of this command. 0x0 - 0xFFF8 - Used for function ids
-        * 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF - HWRM
-        */
-       uint64_t resp_addr;
-       /*
-        * This is the host address where the response will be written when the
-        * request is complete. This area must be 16B aligned and must be
-        * cleared to zero before the request is made.
-        */
-       uint32_t enables;
-       /* This bit must be '1' for the mtu field to be configured. */
-       #define HWRM_FUNC_VF_CFG_INPUT_ENABLES_MTU                 UINT32_C(0x1)
-       /* This bit must be '1' for the guest_vlan field to be configured. */
-       #define HWRM_FUNC_VF_CFG_INPUT_ENABLES_GUEST_VLAN          UINT32_C(0x2)
-       /*
-        * This bit must be '1' for the async_event_cr field to be configured.
-        */
-       #define HWRM_FUNC_VF_CFG_INPUT_ENABLES_ASYNC_EVENT_CR      UINT32_C(0x4)
-       /* This bit must be '1' for the dflt_mac_addr field to be configured. */
-       #define HWRM_FUNC_VF_CFG_INPUT_ENABLES_DFLT_MAC_ADDR       UINT32_C(0x8)
-       uint16_t mtu;
-       /*
-        * The maximum transmission unit requested on the function. The HWRM
-        * should make sure that the mtu of the function does not exceed the mtu
-        * of the physical port that this function is associated with. In
-        * addition to requesting mtu per function, it is possible to configure
-        * mtu per transmit ring. By default, the mtu of each transmit ring
-        * associated with a function is equal to the mtu of the function. The
-        * HWRM should make sure that the mtu of each transmit ring that is
-        * assigned to a function has a valid mtu.
-        */
-       uint16_t guest_vlan;
-       /*
-        * The guest VLAN for the function being configured. This field's format
-        * is same as 802.1Q Tag's Tag Control Information (TCI) format that
-        * includes both Priority Code Point (PCP) and VLAN Identifier (VID).
-        */
-       uint16_t async_event_cr;
-       /*
-        * ID of the target completion ring for receiving asynchronous event
-        * completions. If this field is not valid, then the HWRM shall use the
-        * default completion ring of the function that is being configured as
-        * the target completion ring for providing any asynchronous event
-        * completions for that function. If this field is valid, then the HWRM
-        * shall use the completion ring identified by this ID as the target
-        * completion ring for providing any asynchronous event completions for
-        * the function that is being configured.
-        */
-       uint8_t dflt_mac_addr[6];
-       /*
-        * This value is the current MAC address requested by the VF driver to
-        * be configured on this VF. A value of 00-00-00-00-00-00 indicates no
-        * MAC address configuration is requested by the VF driver. The parent
-        * PF driver may reject or overwrite this MAC address.
-        */
-} __attribute__((packed));
-
-/* Output (16 bytes) */
-
-struct hwrm_func_vf_cfg_output {
-       uint16_t error_code;
-       /*
-        * Pass/Fail or error type Note: receiver to verify the in parameters,
-        * and fail the call with an error when appropriate
-        */
-       uint16_t req_type;
-       /* This field returns the type of original request. */
-       uint16_t seq_id;
-       /* This field provides original sequence number of the command. */
-       uint16_t resp_len;
-       /*
-        * This field is the length of the response in bytes. The last
-        * byte of the response is a valid flag that will read as '1'
-        * when the command has been completely written to memory.
-        */
-       uint32_t unused_0;
-       uint8_t unused_1;
-       uint8_t unused_2;
-       uint8_t unused_3;
-       uint8_t valid;
-       /*
-        * This field is used in Output records to indicate that the output is
-        * completely written to RAM. This field should be read as '1' to
-        * indicate that the output has been completely written. When writing a
-        * command completion or response to an internal processor, the order of
-        * writes has to be such that this field is written last.
-        */
-} __attribute__((packed));
-
 /* hwrm_port_phy_cfg */
 /*
  * Description: This command configures the PHY device for the port. It allows
@@ -4905,12 +4946,12 @@ struct hwrm_port_phy_qcfg_output {
        #define HWRM_PORT_PHY_QCFG_OUTPUT_LINK_SPEED_100GB      UINT32_C(0x3e8)
        /* 10Mb link speed */
        #define HWRM_PORT_PHY_QCFG_OUTPUT_LINK_SPEED_10MB       UINT32_C(0xffff)
-       uint8_t duplex;
+       uint8_t duplex_cfg;
        /* This value is indicates the duplex of the current connection. */
        /* Half Duplex connection. */
-       #define HWRM_PORT_PHY_QCFG_OUTPUT_DUPLEX_HALF   UINT32_C(0x0)
+       #define HWRM_PORT_PHY_QCFG_OUTPUT_DUPLEX_CFG_HALF UINT32_C(0x0)
        /* Full duplex connection. */
-       #define HWRM_PORT_PHY_QCFG_OUTPUT_DUPLEX_FULL   UINT32_C(0x1)
+       #define HWRM_PORT_PHY_QCFG_OUTPUT_DUPLEX_CFG_FULL UINT32_C(0x1)
        uint8_t pause;
        /*
         * This value is used to indicate the current pause
@@ -5238,6 +5279,11 @@ struct hwrm_port_phy_qcfg_output {
        /* 40G_ACTIVE_CABLE */
        #define HWRM_PORT_PHY_QCFG_OUTPUT_PHY_TYPE_40G_ACTIVE_CABLE \
                UINT32_C(0x18)
+       #define HWRM_PORT_PHY_QCFG_OUTPUT_PHY_TYPE_1G_BASET UINT32_C(0x19)
+       /* 1G_baseSX */
+       #define HWRM_PORT_PHY_QCFG_OUTPUT_PHY_TYPE_1G_BASESX UINT32_C(0x1a)
+       /* 1G_baseCX */
+       #define HWRM_PORT_PHY_QCFG_OUTPUT_PHY_TYPE_1G_BASECX UINT32_C(0x1b)
        uint8_t media_type;
        /* This value represents a media type. */
        /* Unknown */
@@ -5564,9 +5610,17 @@ struct hwrm_port_phy_qcfg_output {
         */
        #define HWRM_PORT_PHY_QCFG_OUTPUT_FEC_CFG_FEC_CLAUSE91_ENABLED  \
                UINT32_C(0x40)
-       uint8_t unused_1;
-       uint8_t unused_2;
-       char phy_vendor_name[16];
+       uint8_t duplex_state;
+       /*
+        * This value is indicates the duplex of the current connection
+        * state.
+        */
+       /* Half Duplex connection. */
+       #define HWRM_PORT_PHY_QCFG_OUTPUT_DUPLEX_STATE_HALF UINT32_C(0x0)
+       /* Full duplex connection. */
+       #define HWRM_PORT_PHY_QCFG_OUTPUT_DUPLEX_STATE_FULL UINT32_C(0x1)
+       uint8_t unused_1;
+       char phy_vendor_name[16];
        /*
         * Up to 16 bytes of null padded ASCII string representing PHY
         * vendor. If the string is set to null, then the vendor name is
@@ -5579,10 +5633,10 @@ struct hwrm_port_phy_qcfg_output {
         * to null, then the vendor specific part number is not
         * available.
         */
-       uint32_t unused_3;
+       uint32_t unused_2;
+       uint8_t unused_3;
        uint8_t unused_4;
        uint8_t unused_5;
-       uint8_t unused_6;
        uint8_t valid;
        /*
         * This field is used in Output records to indicate that the
@@ -5743,19 +5797,15 @@ struct hwrm_port_clr_stats_output {
         */
 } __attribute__((packed));
 
-/* hwrm_queue_qportcfg */
+/* hwrm_port_led_cfg */
 /*
- * Description: This function is called by a driver to query queue configuration
- * of a port. # The HWRM shall at least advertise one queue with lossy service
- * profile. # The driver shall use this command to query queue ids before
- * configuring or using any queues. # If a service profile is not set for a
- * queue, then the driver shall not use that queue without configuring a service
- * profile for it. # If the driver is not allowed to configure service profiles,
- * then the driver shall only use queues for which service profiles are pre-
- * configured.
+ * Description: This function is used to configure LEDs on a given port. Each
+ * port has individual set of LEDs associated with it. These LEDs are used for
+ * speed/link configuration as well as activity indicator configuration. Up to
+ * three LEDs can be configured, one for activity and two for speeds.
  */
-/* Input       (24 bytes) */
-struct hwrm_queue_qportcfg_input {
+/* Input       (64 bytes) */
+struct hwrm_port_led_cfg_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -5782,303 +5832,312 @@ struct hwrm_queue_qportcfg_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint32_t flags;
+       uint32_t enables;
+       /* This bit must be '1' for the led0_id field to be configured. */
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED0_ID UINT32_C(0x1)
+       /* This bit must be '1' for the led0_state field to be configured. */
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED0_STATE      UINT32_C(0x2)
+       /* This bit must be '1' for the led0_color field to be configured. */
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED0_COLOR      UINT32_C(0x4)
+       /*
+        * This bit must be '1' for the led0_blink_on field to be
+        * configured.
+        */
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED0_BLINK_ON   UINT32_C(0x8)
        /*
-        * Enumeration denoting the RX, TX type of the resource. This
-        * enumeration is used for resources that are similar for both
-        * TX and RX paths of the chip.
+        * This bit must be '1' for the led0_blink_off field to be
+        * configured.
         */
-       #define HWRM_QUEUE_QPORTCFG_INPUT_FLAGS_PATH    UINT32_C(0x1)
-       /* tx path */
-       #define HWRM_QUEUE_QPORTCFG_INPUT_FLAGS_PATH_TX UINT32_C(0x0)
-       /* rx path */
-       #define HWRM_QUEUE_QPORTCFG_INPUT_FLAGS_PATH_RX UINT32_C(0x1)
-       #define HWRM_QUEUE_QPORTCFG_INPUT_FLAGS_PATH_LAST \
-               QUEUE_QPORTCFG_INPUT_FLAGS_PATH_RX
-       uint16_t port_id;
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED0_BLINK_OFF UINT32_C(0x10)
        /*
-        * Port ID of port for which the queue configuration is being
-        * queried. This field is only required when sent by IPC.
+        * This bit must be '1' for the led0_group_id field to be
+        * configured.
         */
-       uint16_t unused_0;
-} __attribute__((packed));
-
-/* Output      (32 bytes) */
-struct hwrm_queue_qportcfg_output {
-       uint16_t error_code;
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED0_GROUP_ID UINT32_C(0x20)
+       /* This bit must be '1' for the led1_id field to be configured. */
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED1_ID UINT32_C(0x40)
+       /* This bit must be '1' for the led1_state field to be configured. */
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED1_STATE      UINT32_C(0x80)
+       /* This bit must be '1' for the led1_color field to be configured. */
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED1_COLOR      UINT32_C(0x100)
        /*
-        * Pass/Fail or error type Note: receiver to verify the in
-        * parameters, and fail the call with an error when appropriate
+        * This bit must be '1' for the led1_blink_on field to be
+        * configured.
         */
-       uint16_t req_type;
-       /* This field returns the type of original request. */
-       uint16_t seq_id;
-       /* This field provides original sequence number of the command. */
-       uint16_t resp_len;
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED1_BLINK_ON UINT32_C(0x200)
        /*
-        * This field is the length of the response in bytes. The last
-        * byte of the response is a valid flag that will read as '1'
-        * when the command has been completely written to memory.
+        * This bit must be '1' for the led1_blink_off field to be
+        * configured.
         */
-       uint8_t max_configurable_queues;
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED1_BLINK_OFF UINT32_C(0x400)
        /*
-        * The maximum number of queues that can be configured on this
-        * port. Valid values range from 1 through 8.
+        * This bit must be '1' for the led1_group_id field to be
+        * configured.
         */
-       uint8_t max_configurable_lossless_queues;
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED1_GROUP_ID UINT32_C(0x800)
+       /* This bit must be '1' for the led2_id field to be configured. */
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED2_ID UINT32_C(0x1000)
+       /* This bit must be '1' for the led2_state field to be configured. */
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED2_STATE      UINT32_C(0x2000)
+       /* This bit must be '1' for the led2_color field to be configured. */
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED2_COLOR      UINT32_C(0x4000)
        /*
-        * The maximum number of lossless queues that can be configured
-        * on this port. Valid values range from 0 through 8.
+        * This bit must be '1' for the led2_blink_on field to be
+        * configured.
         */
-       uint8_t queue_cfg_allowed;
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED2_BLINK_ON UINT32_C(0x8000)
        /*
-        * Bitmask indicating which queues can be configured by the
-        * hwrm_queue_cfg command. Each bit represents a specific queue
-        * where bit 0 represents queue 0 and bit 7 represents queue 7.
-        * # A value of 0 indicates that the queue is not configurable
-        * by the hwrm_queue_cfg command. # A value of 1 indicates that
-        * the queue is configurable. # A hwrm_queue_cfg command shall
-        * return error when trying to configure a queue not
-        * configurable.
+        * This bit must be '1' for the led2_blink_off field to be
+        * configured.
         */
-       uint8_t queue_cfg_info;
-       /* Information about queue configuration. */
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED2_BLINK_OFF UINT32_C(0x10000)
        /*
-        * If this flag is set to '1', then the queues are configured
-        * asymmetrically on TX and RX sides. If this flag is set to
-        * '0', then the queues are configured symmetrically on TX and
-        * RX sides. For symmetric configuration, the queue
-        * configuration including queue ids and service profiles on the
-        * TX side is the same as the corresponding queue configuration
-        * on the RX side.
+        * This bit must be '1' for the led2_group_id field to be
+        * configured.
         */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_CFG_INFO_ASYM_CFG UINT32_C(0x1)
-       uint8_t queue_pfcenable_cfg_allowed;
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED2_GROUP_ID UINT32_C(0x20000)
+       /* This bit must be '1' for the led3_id field to be configured. */
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED3_ID UINT32_C(0x40000)
+       /* This bit must be '1' for the led3_state field to be configured. */
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED3_STATE  UINT32_C(0x80000)
+       /* This bit must be '1' for the led3_color field to be configured. */
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED3_COLOR  UINT32_C(0x100000)
        /*
-        * Bitmask indicating which queues can be configured by the
-        * hwrm_queue_pfcenable_cfg command. Each bit represents a
-        * specific priority where bit 0 represents priority 0 and bit 7
-        * represents priority 7. # A value of 0 indicates that the
-        * priority is not configurable by the hwrm_queue_pfcenable_cfg
-        * command. # A value of 1 indicates that the priority is
-        * configurable. # A hwrm_queue_pfcenable_cfg command shall
-        * return error when trying to configure a priority that is not
-        * configurable.
+        * This bit must be '1' for the led3_blink_on field to be
+        * configured.
         */
-       uint8_t queue_pri2cos_cfg_allowed;
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED3_BLINK_ON UINT32_C(0x200000)
        /*
-        * Bitmask indicating which queues can be configured by the
-        * hwrm_queue_pri2cos_cfg command. Each bit represents a
-        * specific queue where bit 0 represents queue 0 and bit 7
-        * represents queue 7. # A value of 0 indicates that the queue
-        * is not configurable by the hwrm_queue_pri2cos_cfg command. #
-        * A value of 1 indicates that the queue is configurable. # A
-        * hwrm_queue_pri2cos_cfg command shall return error when trying
-        * to configure a queue that is not configurable.
+        * This bit must be '1' for the led3_blink_off field to be
+        * configured.
         */
-       uint8_t queue_cos2bw_cfg_allowed;
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED3_BLINK_OFF  \
+               UINT32_C(0x400000)
        /*
-        * Bitmask indicating which queues can be configured by the
-        * hwrm_queue_pri2cos_cfg command. Each bit represents a
-        * specific queue where bit 0 represents queue 0 and bit 7
-        * represents queue 7. # A value of 0 indicates that the queue
-        * is not configurable by the hwrm_queue_pri2cos_cfg command. #
-        * A value of 1 indicates that the queue is configurable. # A
-        * hwrm_queue_pri2cos_cfg command shall return error when trying
-        * to configure a queue not configurable.
+        * This bit must be '1' for the led3_group_id field to be
+        * configured.
         */
-       uint8_t queue_id0;
+       #define HWRM_PORT_LED_CFG_INPUT_ENABLES_LED3_GROUP_ID UINT32_C(0x800000)
+       uint16_t port_id;
+       /* Port ID of port whose LEDs are configured. */
+       uint8_t num_leds;
        /*
-        * ID of CoS Queue 0. FF - Invalid id # This ID can be used on
-        * any subsequent call to an hwrm command that takes a queue id.
-        * # IDs must always be queried by this command before any use
-        * by the driver or software. # Any driver or software should
-        * not make any assumptions about queue IDs. # A value of 0xff
-        * indicates that the queue is not available. # Available queues
-        * may not be in sequential order.
+        * The number of LEDs that are being configured. Up to 4 LEDs
+        * can be configured with this command.
         */
-       uint8_t queue_id0_service_profile;
-       /* This value is applicable to CoS queues only. */
-       /* Lossy        (best-effort) */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID0_SERVICE_PROFILE_LOSSY \
-               UINT32_C(0x0)
-       /* Lossless */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID0_SERVICE_PROFILE_LOSSLESS \
-               UINT32_C(0x1)
+       uint8_t rsvd;
+       /* Reserved field. */
+       uint8_t led0_id;
+       /* An identifier for the LED #0. */
+       uint8_t led0_state;
+       /* The requested state of the LED #0. */
+       /* Default state of the LED */
+       #define HWRM_PORT_LED_CFG_INPUT_LED0_STATE_DEFAULT      UINT32_C(0x0)
+       /* Off */
+       #define HWRM_PORT_LED_CFG_INPUT_LED0_STATE_OFF  UINT32_C(0x1)
+       /* On */
+       #define HWRM_PORT_LED_CFG_INPUT_LED0_STATE_ON   UINT32_C(0x2)
+       /* Blink */
+       #define HWRM_PORT_LED_CFG_INPUT_LED0_STATE_BLINK        UINT32_C(0x3)
+       /* Blink Alternately */
+       #define HWRM_PORT_LED_CFG_INPUT_LED0_STATE_BLINKALT     UINT32_C(0x4)
+       uint8_t led0_color;
+       /* The requested color of LED #0. */
+       /* Default */
+       #define HWRM_PORT_LED_CFG_INPUT_LED0_COLOR_DEFAULT      UINT32_C(0x0)
+       /* Amber */
+       #define HWRM_PORT_LED_CFG_INPUT_LED0_COLOR_AMBER        UINT32_C(0x1)
+       /* Green */
+       #define HWRM_PORT_LED_CFG_INPUT_LED0_COLOR_GREEN        UINT32_C(0x2)
+       /* Green or Amber */
+       #define HWRM_PORT_LED_CFG_INPUT_LED0_COLOR_GREENAMBER   UINT32_C(0x3)
+       uint8_t unused_0;
+       uint16_t led0_blink_on;
        /*
-        * Set to 0xFF...       (All Fs) if there is no
-        * service profile specified
+        * If the LED #0 state is "blink" or "blinkalt", then this field
+        * represents the requested time in milliseconds to keep LED on
+        * between cycles.
         */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID0_SERVICE_PROFILE_UNKNOWN \
-               UINT32_C(0xff)
-       uint8_t queue_id1;
+       uint16_t led0_blink_off;
        /*
-        * ID of CoS Queue 1. FF - Invalid id # This ID can be used on
-        * any subsequent call to an hwrm command that takes a queue id.
-        * # IDs must always be queried by this command before any use
-        * by the driver or software. # Any driver or software should
-        * not make any assumptions about queue IDs. # A value of 0xff
-        * indicates that the queue is not available. # Available queues
-        * may not be in sequential order.
+        * If the LED #0 state is "blink" or "blinkalt", then this field
+        * represents the requested time in milliseconds to keep LED off
+        * between cycles.
         */
-       uint8_t queue_id1_service_profile;
-       /* This value is applicable to CoS queues only. */
-       /* Lossy        (best-effort) */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID1_SERVICE_PROFILE_LOSSY \
-               UINT32_C(0x0)
-       /* Lossless */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID1_SERVICE_PROFILE_LOSSLESS \
-               UINT32_C(0x1)
+       uint8_t led0_group_id;
        /*
-        * Set to 0xFF...       (All Fs) if there is no
-        * service profile specified
+        * An identifier for the group of LEDs that LED #0 belongs to.
+        * If set to 0, then the LED #0 shall not be grouped and shall
+        * be treated as an individual resource. For all other non-zero
+        * values of this field, LED #0 shall be grouped together with
+        * the LEDs with the same group ID value.
         */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID1_SERVICE_PROFILE_UNKNOWN \
-               UINT32_C(0xff)
-       uint8_t queue_id2;
+       uint8_t rsvd0;
+       /* Reserved field. */
+       uint8_t led1_id;
+       /* An identifier for the LED #1. */
+       uint8_t led1_state;
+       /* The requested state of the LED #1. */
+       /* Default state of the LED */
+       #define HWRM_PORT_LED_CFG_INPUT_LED1_STATE_DEFAULT      UINT32_C(0x0)
+       /* Off */
+       #define HWRM_PORT_LED_CFG_INPUT_LED1_STATE_OFF  UINT32_C(0x1)
+       /* On */
+       #define HWRM_PORT_LED_CFG_INPUT_LED1_STATE_ON   UINT32_C(0x2)
+       /* Blink */
+       #define HWRM_PORT_LED_CFG_INPUT_LED1_STATE_BLINK        UINT32_C(0x3)
+       /* Blink Alternately */
+       #define HWRM_PORT_LED_CFG_INPUT_LED1_STATE_BLINKALT     UINT32_C(0x4)
+       uint8_t led1_color;
+       /* The requested color of LED #1. */
+       /* Default */
+       #define HWRM_PORT_LED_CFG_INPUT_LED1_COLOR_DEFAULT      UINT32_C(0x0)
+       /* Amber */
+       #define HWRM_PORT_LED_CFG_INPUT_LED1_COLOR_AMBER        UINT32_C(0x1)
+       /* Green */
+       #define HWRM_PORT_LED_CFG_INPUT_LED1_COLOR_GREEN        UINT32_C(0x2)
+       /* Green or Amber */
+       #define HWRM_PORT_LED_CFG_INPUT_LED1_COLOR_GREENAMBER   UINT32_C(0x3)
+       uint8_t unused_1;
+       uint16_t led1_blink_on;
        /*
-        * ID of CoS Queue 2. FF - Invalid id # This ID can be used on
-        * any subsequent call to an hwrm command that takes a queue id.
-        * # IDs must always be queried by this command before any use
-        * by the driver or software. # Any driver or software should
-        * not make any assumptions about queue IDs. # A value of 0xff
-        * indicates that the queue is not available. # Available queues
-        * may not be in sequential order.
+        * If the LED #1 state is "blink" or "blinkalt", then this field
+        * represents the requested time in milliseconds to keep LED on
+        * between cycles.
         */
-       uint8_t queue_id2_service_profile;
-       /* This value is applicable to CoS queues only. */
-       /* Lossy        (best-effort) */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID2_SERVICE_PROFILE_LOSSY \
-               UINT32_C(0x0)
-       /* Lossless */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID2_SERVICE_PROFILE_LOSSLESS \
-               UINT32_C(0x1)
+       uint16_t led1_blink_off;
        /*
-        * Set to 0xFF...       (All Fs) if there is no
-        * service profile specified
+        * If the LED #1 state is "blink" or "blinkalt", then this field
+        * represents the requested time in milliseconds to keep LED off
+        * between cycles.
         */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID2_SERVICE_PROFILE_UNKNOWN \
-               UINT32_C(0xff)
-       uint8_t queue_id3;
+       uint8_t led1_group_id;
        /*
-        * ID of CoS Queue 3. FF - Invalid id # This ID can be used on
-        * any subsequent call to an hwrm command that takes a queue id.
-        * # IDs must always be queried by this command before any use
-        * by the driver or software. # Any driver or software should
-        * not make any assumptions about queue IDs. # A value of 0xff
-        * indicates that the queue is not available. # Available queues
-        * may not be in sequential order.
+        * An identifier for the group of LEDs that LED #1 belongs to.
+        * If set to 0, then the LED #1 shall not be grouped and shall
+        * be treated as an individual resource. For all other non-zero
+        * values of this field, LED #1 shall be grouped together with
+        * the LEDs with the same group ID value.
         */
-       uint8_t queue_id3_service_profile;
-       /* This value is applicable to CoS queues only. */
-       /* Lossy        (best-effort) */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID3_SERVICE_PROFILE_LOSSY \
-               UINT32_C(0x0)
-       /* Lossless */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID3_SERVICE_PROFILE_LOSSLESS \
-               UINT32_C(0x1)
+       uint8_t rsvd1;
+       /* Reserved field. */
+       uint8_t led2_id;
+       /* An identifier for the LED #2. */
+       uint8_t led2_state;
+       /* The requested state of the LED #2. */
+       /* Default state of the LED */
+       #define HWRM_PORT_LED_CFG_INPUT_LED2_STATE_DEFAULT      UINT32_C(0x0)
+       /* Off */
+       #define HWRM_PORT_LED_CFG_INPUT_LED2_STATE_OFF  UINT32_C(0x1)
+       /* On */
+       #define HWRM_PORT_LED_CFG_INPUT_LED2_STATE_ON   UINT32_C(0x2)
+       /* Blink */
+       #define HWRM_PORT_LED_CFG_INPUT_LED2_STATE_BLINK        UINT32_C(0x3)
+       /* Blink Alternately */
+       #define HWRM_PORT_LED_CFG_INPUT_LED2_STATE_BLINKALT     UINT32_C(0x4)
+       uint8_t led2_color;
+       /* The requested color of LED #2. */
+       /* Default */
+       #define HWRM_PORT_LED_CFG_INPUT_LED2_COLOR_DEFAULT      UINT32_C(0x0)
+       /* Amber */
+       #define HWRM_PORT_LED_CFG_INPUT_LED2_COLOR_AMBER        UINT32_C(0x1)
+       /* Green */
+       #define HWRM_PORT_LED_CFG_INPUT_LED2_COLOR_GREEN        UINT32_C(0x2)
+       /* Green or Amber */
+       #define HWRM_PORT_LED_CFG_INPUT_LED2_COLOR_GREENAMBER   UINT32_C(0x3)
+       uint8_t unused_2;
+       uint16_t led2_blink_on;
        /*
-        * Set to 0xFF...       (All Fs) if there is no
-        * service profile specified
+        * If the LED #2 state is "blink" or "blinkalt", then this field
+        * represents the requested time in milliseconds to keep LED on
+        * between cycles.
         */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID3_SERVICE_PROFILE_UNKNOWN \
-               UINT32_C(0xff)
-       uint8_t queue_id4;
+       uint16_t led2_blink_off;
        /*
-        * ID of CoS Queue 4. FF - Invalid id # This ID can be used on
-        * any subsequent call to an hwrm command that takes a queue id.
-        * # IDs must always be queried by this command before any use
-        * by the driver or software. # Any driver or software should
-        * not make any assumptions about queue IDs. # A value of 0xff
-        * indicates that the queue is not available. # Available queues
-        * may not be in sequential order.
+        * If the LED #2 state is "blink" or "blinkalt", then this field
+        * represents the requested time in milliseconds to keep LED off
+        * between cycles.
         */
-       uint8_t queue_id4_service_profile;
-       /* This value is applicable to CoS queues only. */
-       /* Lossy        (best-effort) */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID4_SERVICE_PROFILE_LOSSY \
-               UINT32_C(0x0)
-       /* Lossless */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID4_SERVICE_PROFILE_LOSSLESS \
-               UINT32_C(0x1)
+       uint8_t led2_group_id;
        /*
-        * Set to 0xFF...       (All Fs) if there is no
-        * service profile specified
+        * An identifier for the group of LEDs that LED #2 belongs to.
+        * If set to 0, then the LED #2 shall not be grouped and shall
+        * be treated as an individual resource. For all other non-zero
+        * values of this field, LED #2 shall be grouped together with
+        * the LEDs with the same group ID value.
         */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID4_SERVICE_PROFILE_UNKNOWN \
-               UINT32_C(0xff)
-       uint8_t queue_id5;
+       uint8_t rsvd2;
+       /* Reserved field. */
+       uint8_t led3_id;
+       /* An identifier for the LED #3. */
+       uint8_t led3_state;
+       /* The requested state of the LED #3. */
+       /* Default state of the LED */
+       #define HWRM_PORT_LED_CFG_INPUT_LED3_STATE_DEFAULT      UINT32_C(0x0)
+       /* Off */
+       #define HWRM_PORT_LED_CFG_INPUT_LED3_STATE_OFF  UINT32_C(0x1)
+       /* On */
+       #define HWRM_PORT_LED_CFG_INPUT_LED3_STATE_ON   UINT32_C(0x2)
+       /* Blink */
+       #define HWRM_PORT_LED_CFG_INPUT_LED3_STATE_BLINK        UINT32_C(0x3)
+       /* Blink Alternately */
+       #define HWRM_PORT_LED_CFG_INPUT_LED3_STATE_BLINKALT     UINT32_C(0x4)
+       uint8_t led3_color;
+       /* The requested color of LED #3. */
+       /* Default */
+       #define HWRM_PORT_LED_CFG_INPUT_LED3_COLOR_DEFAULT      UINT32_C(0x0)
+       /* Amber */
+       #define HWRM_PORT_LED_CFG_INPUT_LED3_COLOR_AMBER        UINT32_C(0x1)
+       /* Green */
+       #define HWRM_PORT_LED_CFG_INPUT_LED3_COLOR_GREEN        UINT32_C(0x2)
+       /* Green or Amber */
+       #define HWRM_PORT_LED_CFG_INPUT_LED3_COLOR_GREENAMBER   UINT32_C(0x3)
+       uint8_t unused_3;
+       uint16_t led3_blink_on;
        /*
-        * ID of CoS Queue 5. FF - Invalid id # This ID can be used on
-        * any subsequent call to an hwrm command that takes a queue id.
-        * # IDs must always be queried by this command before any use
-        * by the driver or software. # Any driver or software should
-        * not make any assumptions about queue IDs. # A value of 0xff
-        * indicates that the queue is not available. # Available queues
-        * may not be in sequential order.
+        * If the LED #3 state is "blink" or "blinkalt", then this field
+        * represents the requested time in milliseconds to keep LED on
+        * between cycles.
         */
-       uint8_t queue_id5_service_profile;
-       /* This value is applicable to CoS queues only. */
-       /* Lossy        (best-effort) */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID5_SERVICE_PROFILE_LOSSY \
-               UINT32_C(0x0)
-       /* Lossless */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID5_SERVICE_PROFILE_LOSSLESS \
-               UINT32_C(0x1)
+       uint16_t led3_blink_off;
        /*
-        * Set to 0xFF...       (All Fs) if there is no
-        * service profile specified
+        * If the LED #3 state is "blink" or "blinkalt", then this field
+        * represents the requested time in milliseconds to keep LED off
+        * between cycles.
         */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID5_SERVICE_PROFILE_UNKNOWN \
-               UINT32_C(0xff)
-       uint8_t queue_id6;
+       uint8_t led3_group_id;
        /*
-        * ID of CoS Queue 6. FF - Invalid id # This ID can be used on
-        * any subsequent call to an hwrm command that takes a queue id.
-        * # IDs must always be queried by this command before any use
-        * by the driver or software. # Any driver or software should
-        * not make any assumptions about queue IDs. # A value of 0xff
-        * indicates that the queue is not available. # Available queues
-        * may not be in sequential order.
+        * An identifier for the group of LEDs that LED #3 belongs to.
+        * If set to 0, then the LED #3 shall not be grouped and shall
+        * be treated as an individual resource. For all other non-zero
+        * values of this field, LED #3 shall be grouped together with
+        * the LEDs with the same group ID value.
         */
-       uint8_t queue_id6_service_profile;
-       /* This value is applicable to CoS queues only. */
-       /* Lossy        (best-effort) */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID6_SERVICE_PROFILE_LOSSY \
-               UINT32_C(0x0)
-       /* Lossless */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID6_SERVICE_PROFILE_LOSSLESS \
-               UINT32_C(0x1)
-       /*
-        * Set to 0xFF...       (All Fs) if there is no
-        * service profile specified
-        */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID6_SERVICE_PROFILE_UNKNOWN \
-               UINT32_C(0xff)
-       uint8_t queue_id7;
+       uint8_t rsvd3;
+       /* Reserved field. */
+} __attribute__((packed));
+
+/* Output      (16 bytes) */
+struct hwrm_port_led_cfg_output {
+       uint16_t error_code;
        /*
-        * ID of CoS Queue 7. FF - Invalid id # This ID can be used on
-        * any subsequent call to an hwrm command that takes a queue id.
-        * # IDs must always be queried by this command before any use
-        * by the driver or software. # Any driver or software should
-        * not make any assumptions about queue IDs. # A value of 0xff
-        * indicates that the queue is not available. # Available queues
-        * may not be in sequential order.
+        * Pass/Fail or error type Note: receiver to verify the in
+        * parameters, and fail the call with an error when appropriate
         */
-       uint8_t queue_id7_service_profile;
-       /* This value is applicable to CoS queues only. */
-       /* Lossy        (best-effort) */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID7_SERVICE_PROFILE_LOSSY \
-               UINT32_C(0x0)
-       /* Lossless */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID7_SERVICE_PROFILE_LOSSLESS \
-               UINT32_C(0x1)
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
        /*
-        * Set to 0xFF...       (All Fs) if there is no
-        * service profile specified
+        * This field is the length of the response in bytes. The last
+        * byte of the response is a valid flag that will read as '1'
+        * when the command has been completely written to memory.
         */
-       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID7_SERVICE_PROFILE_UNKNOWN \
-               UINT32_C(0xff)
+       uint32_t unused_0;
+       uint8_t unused_1;
+       uint8_t unused_2;
+       uint8_t unused_3;
        uint8_t valid;
        /*
         * This field is used in Output records to indicate that the
@@ -6090,25 +6149,16 @@ struct hwrm_queue_qportcfg_output {
         */
 } __attribute__((packed));
 
-/* hwrm_vnic_alloc */
+/* hwrm_port_led_qcfg */
 /*
- * Description: This VNIC is a resource in the RX side of the chip that is used
- * to represent a virtual host "interface". # At the time of VNIC allocation or
- * configuration, the function can specify whether it wants the requested VNIC
- * to be the default VNIC for the function or not. # If a function requests
- * allocation of a VNIC for the first time and a VNIC is successfully allocated
- * by the HWRM, then the HWRM shall make the allocated VNIC as the default VNIC
- * for that function. # The default VNIC shall be used for the default action
- * for a partition or function. # For each VNIC allocated on a function, a
- * mapping on the RX side to map the allocated VNIC to source virtual interface
- * shall be performed by the HWRM. This should be hidden to the function driver
- * requesting the VNIC allocation. This enables broadcast/multicast replication
- * with source knockout. # If multicast replication with source knockout is
- * enabled, then the internal VNIC to SVIF mapping data structures shall be
- * programmed at the time of VNIC allocation.
+ * Description: This function is used to query configuration of LEDs on a given
+ * port. Each port has individual set of LEDs associated with it. These LEDs are
+ * used for speed/link configuration as well as activity indicator
+ * configuration. Up to three LEDs can be configured, one for activity and two
+ * for speeds.
  */
 /* Input       (24 bytes) */
-struct hwrm_vnic_alloc_input {
+struct hwrm_port_led_qcfg_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -6135,17 +6185,13 @@ struct hwrm_vnic_alloc_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint32_t flags;
-       /*
-        * When this bit is '1', this VNIC is requested to be the
-        * default VNIC for this function.
-        */
-       #define HWRM_VNIC_ALLOC_INPUT_FLAGS_DEFAULT     UINT32_C(0x1)
-       uint32_t unused_0;
+       uint16_t port_id;
+       /* Port ID of port whose LED configuration is being queried. */
+       uint16_t unused_0[3];
 } __attribute__((packed));
 
-/* Output      (16 bytes) */
-struct hwrm_vnic_alloc_output {
+/* Output      (56 bytes) */
+struct hwrm_port_led_qcfg_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -6161,11 +6207,224 @@ struct hwrm_vnic_alloc_output {
         * byte of the response is a valid flag that will read as '1'
         * when the command has been completely written to memory.
         */
-       uint32_t vnic_id;
-       /* Logical vnic ID */
+       uint8_t num_leds;
+       /*
+        * The number of LEDs that are configured on this port. Up to 4
+        * LEDs can be returned in the response.
+        */
+       uint8_t led0_id;
+       /* An identifier for the LED #0. */
+       uint8_t led0_type;
+       /* The type of LED #0. */
+       /* Speed LED */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED0_TYPE_SPEED       UINT32_C(0x0)
+       /* Activity LED */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED0_TYPE_ACTIVITY    UINT32_C(0x1)
+       /* Invalid */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED0_TYPE_INVALID     UINT32_C(0xff)
+       uint8_t led0_state;
+       /* The current state of the LED #0. */
+       /* Default state of the LED */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED0_STATE_DEFAULT    UINT32_C(0x0)
+       /* Off */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED0_STATE_OFF        UINT32_C(0x1)
+       /* On */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED0_STATE_ON UINT32_C(0x2)
+       /* Blink */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED0_STATE_BLINK      UINT32_C(0x3)
+       /* Blink Alternately */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED0_STATE_BLINKALT   UINT32_C(0x4)
+       uint8_t led0_color;
+       /* The color of LED #0. */
+       /* Default */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED0_COLOR_DEFAULT    UINT32_C(0x0)
+       /* Amber */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED0_COLOR_AMBER      UINT32_C(0x1)
+       /* Green */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED0_COLOR_GREEN      UINT32_C(0x2)
+       /* Green or Amber */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED0_COLOR_GREENAMBER UINT32_C(0x3)
        uint8_t unused_0;
+       uint16_t led0_blink_on;
+       /*
+        * If the LED #0 state is "blink" or "blinkalt", then this field
+        * represents the requested time in milliseconds to keep LED on
+        * between cycles.
+        */
+       uint16_t led0_blink_off;
+       /*
+        * If the LED #0 state is "blink" or "blinkalt", then this field
+        * represents the requested time in milliseconds to keep LED off
+        * between cycles.
+        */
+       uint8_t led0_group_id;
+       /*
+        * An identifier for the group of LEDs that LED #0 belongs to.
+        * If set to 0, then the LED #0 is not grouped. For all other
+        * non-zero values of this field, LED #0 is grouped together
+        * with the LEDs with the same group ID value.
+        */
+       uint8_t led1_id;
+       /* An identifier for the LED #1. */
+       uint8_t led1_type;
+       /* The type of LED #1. */
+       /* Speed LED */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED1_TYPE_SPEED       UINT32_C(0x0)
+       /* Activity LED */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED1_TYPE_ACTIVITY    UINT32_C(0x1)
+       /* Invalid */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED1_TYPE_INVALID     UINT32_C(0xff)
+       uint8_t led1_state;
+       /* The current state of the LED #1. */
+       /* Default state of the LED */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED1_STATE_DEFAULT    UINT32_C(0x0)
+       /* Off */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED1_STATE_OFF        UINT32_C(0x1)
+       /* On */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED1_STATE_ON UINT32_C(0x2)
+       /* Blink */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED1_STATE_BLINK      UINT32_C(0x3)
+       /* Blink Alternately */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED1_STATE_BLINKALT   UINT32_C(0x4)
+       uint8_t led1_color;
+       /* The color of LED #1. */
+       /* Default */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED1_COLOR_DEFAULT    UINT32_C(0x0)
+       /* Amber */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED1_COLOR_AMBER      UINT32_C(0x1)
+       /* Green */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED1_COLOR_GREEN      UINT32_C(0x2)
+       /* Green or Amber */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED1_COLOR_GREENAMBER UINT32_C(0x3)
        uint8_t unused_1;
+       uint16_t led1_blink_on;
+       /*
+        * If the LED #1 state is "blink" or "blinkalt", then this field
+        * represents the requested time in milliseconds to keep LED on
+        * between cycles.
+        */
+       uint16_t led1_blink_off;
+       /*
+        * If the LED #1 state is "blink" or "blinkalt", then this field
+        * represents the requested time in milliseconds to keep LED off
+        * between cycles.
+        */
+       uint8_t led1_group_id;
+       /*
+        * An identifier for the group of LEDs that LED #1 belongs to.
+        * If set to 0, then the LED #1 is not grouped. For all other
+        * non-zero values of this field, LED #1 is grouped together
+        * with the LEDs with the same group ID value.
+        */
+       uint8_t led2_id;
+       /* An identifier for the LED #2. */
+       uint8_t led2_type;
+       /* The type of LED #2. */
+       /* Speed LED */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED2_TYPE_SPEED       UINT32_C(0x0)
+       /* Activity LED */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED2_TYPE_ACTIVITY    UINT32_C(0x1)
+       /* Invalid */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED2_TYPE_INVALID     UINT32_C(0xff)
+       uint8_t led2_state;
+       /* The current state of the LED #2. */
+       /* Default state of the LED */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED2_STATE_DEFAULT    UINT32_C(0x0)
+       /* Off */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED2_STATE_OFF        UINT32_C(0x1)
+       /* On */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED2_STATE_ON UINT32_C(0x2)
+       /* Blink */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED2_STATE_BLINK      UINT32_C(0x3)
+       /* Blink Alternately */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED2_STATE_BLINKALT   UINT32_C(0x4)
+       uint8_t led2_color;
+       /* The color of LED #2. */
+       /* Default */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED2_COLOR_DEFAULT    UINT32_C(0x0)
+       /* Amber */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED2_COLOR_AMBER      UINT32_C(0x1)
+       /* Green */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED2_COLOR_GREEN      UINT32_C(0x2)
+       /* Green or Amber */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED2_COLOR_GREENAMBER UINT32_C(0x3)
        uint8_t unused_2;
+       uint16_t led2_blink_on;
+       /*
+        * If the LED #2 state is "blink" or "blinkalt", then this field
+        * represents the requested time in milliseconds to keep LED on
+        * between cycles.
+        */
+       uint16_t led2_blink_off;
+       /*
+        * If the LED #2 state is "blink" or "blinkalt", then this field
+        * represents the requested time in milliseconds to keep LED off
+        * between cycles.
+        */
+       uint8_t led2_group_id;
+       /*
+        * An identifier for the group of LEDs that LED #2 belongs to.
+        * If set to 0, then the LED #2 is not grouped. For all other
+        * non-zero values of this field, LED #2 is grouped together
+        * with the LEDs with the same group ID value.
+        */
+       uint8_t led3_id;
+       /* An identifier for the LED #3. */
+       uint8_t led3_type;
+       /* The type of LED #3. */
+       /* Speed LED */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED3_TYPE_SPEED       UINT32_C(0x0)
+       /* Activity LED */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED3_TYPE_ACTIVITY    UINT32_C(0x1)
+       /* Invalid */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED3_TYPE_INVALID     UINT32_C(0xff)
+       uint8_t led3_state;
+       /* The current state of the LED #3. */
+       /* Default state of the LED */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED3_STATE_DEFAULT    UINT32_C(0x0)
+       /* Off */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED3_STATE_OFF        UINT32_C(0x1)
+       /* On */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED3_STATE_ON UINT32_C(0x2)
+       /* Blink */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED3_STATE_BLINK      UINT32_C(0x3)
+       /* Blink Alternately */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED3_STATE_BLINKALT   UINT32_C(0x4)
+       uint8_t led3_color;
+       /* The color of LED #3. */
+       /* Default */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED3_COLOR_DEFAULT    UINT32_C(0x0)
+       /* Amber */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED3_COLOR_AMBER      UINT32_C(0x1)
+       /* Green */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED3_COLOR_GREEN      UINT32_C(0x2)
+       /* Green or Amber */
+       #define HWRM_PORT_LED_QCFG_OUTPUT_LED3_COLOR_GREENAMBER UINT32_C(0x3)
+       uint8_t unused_3;
+       uint16_t led3_blink_on;
+       /*
+        * If the LED #3 state is "blink" or "blinkalt", then this field
+        * represents the requested time in milliseconds to keep LED on
+        * between cycles.
+        */
+       uint16_t led3_blink_off;
+       /*
+        * If the LED #3 state is "blink" or "blinkalt", then this field
+        * represents the requested time in milliseconds to keep LED off
+        * between cycles.
+        */
+       uint8_t led3_group_id;
+       /*
+        * An identifier for the group of LEDs that LED #3 belongs to.
+        * If set to 0, then the LED #3 is not grouped. For all other
+        * non-zero values of this field, LED #3 is grouped together
+        * with the LEDs with the same group ID value.
+        */
+       uint8_t unused_4;
+       uint16_t unused_5;
+       uint8_t unused_6;
+       uint8_t unused_7;
+       uint8_t unused_8;
        uint8_t valid;
        /*
         * This field is used in Output records to indicate that the
@@ -6177,14 +6436,15 @@ struct hwrm_vnic_alloc_output {
         */
 } __attribute__((packed));
 
-/* hwrm_vnic_free */
+/* hwrm_port_led_qcaps */
 /*
- * Description: Free a VNIC resource. Idle any resources associated with the
- * VNIC as well as the VNIC. Reset and release all resources associated with the
- * VNIC.
+ * Description: This function is used to query capabilities of LEDs on a given
+ * port. Each port has individual set of LEDs associated with it. These LEDs are
+ * used for speed/link configuration as well as activity indicator
+ * configuration.
  */
 /* Input       (24 bytes) */
-struct hwrm_vnic_free_input {
+struct hwrm_port_led_qcaps_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -6211,13 +6471,13 @@ struct hwrm_vnic_free_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint32_t vnic_id;
-       /* Logical vnic ID */
-       uint32_t unused_0;
+       uint16_t port_id;
+       /* Port ID of port whose LED configuration is being queried. */
+       uint16_t unused_0[3];
 } __attribute__((packed));
 
-/* Output      (16 bytes) */
-struct hwrm_vnic_free_output {
+/* Output      (48 bytes) */
+struct hwrm_port_led_qcaps_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -6233,10 +6493,276 @@ struct hwrm_vnic_free_output {
         * byte of the response is a valid flag that will read as '1'
         * when the command has been completely written to memory.
         */
-       uint32_t unused_0;
+       uint8_t num_leds;
+       /*
+        * The number of LEDs that are configured on this port. Up to 4
+        * LEDs can be returned in the response.
+        */
+       uint8_t unused_0[3];
+       /* Reserved for future use. */
+       uint8_t led0_id;
+       /* An identifier for the LED #0. */
+       uint8_t led0_type;
+       /* The type of LED #0. */
+       /* Speed LED */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED0_TYPE_SPEED      UINT32_C(0x0)
+       /* Activity LED */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED0_TYPE_ACTIVITY   UINT32_C(0x1)
+       /* Invalid */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED0_TYPE_INVALID    UINT32_C(0xff)
+       uint8_t led0_group_id;
+       /*
+        * An identifier for the group of LEDs that LED #0 belongs to.
+        * If set to 0, then the LED #0 cannot be grouped. For all other
+        * non-zero values of this field, LED #0 is grouped together
+        * with the LEDs with the same group ID value.
+        */
        uint8_t unused_1;
+       uint16_t led0_state_caps;
+       /* The states supported by LED #0. */
+       /*
+        * If set to 1, this LED is enabled. If set to 0, this LED is
+        * disabled.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED0_STATE_CAPS_ENABLED UINT32_C(0x1)
+       /*
+        * If set to 1, off state is supported on this LED. If set to 0,
+        * off state is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED0_STATE_CAPS_OFF_SUPPORTED  \
+               UINT32_C(0x2)
+       /*
+        * If set to 1, on state is supported on this LED. If set to 0,
+        * on state is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED0_STATE_CAPS_ON_SUPPORTED   \
+               UINT32_C(0x4)
+       /*
+        * If set to 1, blink state is supported on this LED. If set to
+        * 0, blink state is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED0_STATE_CAPS_BLINK_SUPPORTED \
+               UINT32_C(0x8)
+       /*
+        * If set to 1, blink_alt state is supported on this LED. If set
+        * to 0, blink_alt state is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED0_STATE_CAPS_BLINK_ALT_SUPPORTED \
+               UINT32_C(0x10)
+       uint16_t led0_color_caps;
+       /* The colors supported by LED #0. */
+       /* reserved */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED0_COLOR_CAPS_RSVD UINT32_C(0x1)
+       /*
+        * If set to 1, Amber color is supported on this LED. If set to
+        * 0, Amber color is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED0_COLOR_CAPS_AMBER_SUPPORTED \
+               UINT32_C(0x2)
+       /*
+        * If set to 1, Green color is supported on this LED. If set to
+        * 0, Green color is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED0_COLOR_CAPS_GREEN_SUPPORTED \
+               UINT32_C(0x4)
+       uint8_t led1_id;
+       /* An identifier for the LED #1. */
+       uint8_t led1_type;
+       /* The type of LED #1. */
+       /* Speed LED */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED1_TYPE_SPEED      UINT32_C(0x0)
+       /* Activity LED */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED1_TYPE_ACTIVITY   UINT32_C(0x1)
+       /* Invalid */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED1_TYPE_INVALID    UINT32_C(0xff)
+       uint8_t led1_group_id;
+       /*
+        * An identifier for the group of LEDs that LED #1 belongs to.
+        * If set to 0, then the LED #0 cannot be grouped. For all other
+        * non-zero values of this field, LED #0 is grouped together
+        * with the LEDs with the same group ID value.
+        */
        uint8_t unused_2;
+       uint16_t led1_state_caps;
+       /* The states supported by LED #1. */
+       /*
+        * If set to 1, this LED is enabled. If set to 0, this LED is
+        * disabled.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED1_STATE_CAPS_ENABLED UINT32_C(0x1)
+       /*
+        * If set to 1, off state is supported on this LED. If set to 0,
+        * off state is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED1_STATE_CAPS_OFF_SUPPORTED  \
+               UINT32_C(0x2)
+       /*
+        * If set to 1, on state is supported on this LED. If set to 0,
+        * on state is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED1_STATE_CAPS_ON_SUPPORTED   \
+               UINT32_C(0x4)
+       /*
+        * If set to 1, blink state is supported on this LED. If set to
+        * 0, blink state is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED1_STATE_CAPS_BLINK_SUPPORTED \
+               UINT32_C(0x8)
+       /*
+        * If set to 1, blink_alt state is supported on this LED. If set
+        * to 0, blink_alt state is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED1_STATE_CAPS_BLINK_ALT_SUPPORTED \
+               UINT32_C(0x10)
+       uint16_t led1_color_caps;
+       /* The colors supported by LED #1. */
+       /* reserved */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED1_COLOR_CAPS_RSVD UINT32_C(0x1)
+       /*
+        * If set to 1, Amber color is supported on this LED. If set to
+        * 0, Amber color is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED1_COLOR_CAPS_AMBER_SUPPORTED \
+               UINT32_C(0x2)
+       /*
+        * If set to 1, Green color is supported on this LED. If set to
+        * 0, Green color is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED1_COLOR_CAPS_GREEN_SUPPORTED \
+               UINT32_C(0x4)
+       uint8_t led2_id;
+       /* An identifier for the LED #2. */
+       uint8_t led2_type;
+       /* The type of LED #2. */
+       /* Speed LED */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED2_TYPE_SPEED      UINT32_C(0x0)
+       /* Activity LED */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED2_TYPE_ACTIVITY   UINT32_C(0x1)
+       /* Invalid */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED2_TYPE_INVALID    UINT32_C(0xff)
+       uint8_t led2_group_id;
+       /*
+        * An identifier for the group of LEDs that LED #0 belongs to.
+        * If set to 0, then the LED #0 cannot be grouped. For all other
+        * non-zero values of this field, LED #0 is grouped together
+        * with the LEDs with the same group ID value.
+        */
        uint8_t unused_3;
+       uint16_t led2_state_caps;
+       /* The states supported by LED #2. */
+       /*
+        * If set to 1, this LED is enabled. If set to 0, this LED is
+        * disabled.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED2_STATE_CAPS_ENABLED UINT32_C(0x1)
+       /*
+        * If set to 1, off state is supported on this LED. If set to 0,
+        * off state is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED2_STATE_CAPS_OFF_SUPPORTED  \
+               UINT32_C(0x2)
+       /*
+        * If set to 1, on state is supported on this LED. If set to 0,
+        * on state is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED2_STATE_CAPS_ON_SUPPORTED   \
+               UINT32_C(0x4)
+       /*
+        * If set to 1, blink state is supported on this LED. If set to
+        * 0, blink state is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED2_STATE_CAPS_BLINK_SUPPORTED \
+               UINT32_C(0x8)
+       /*
+        * If set to 1, blink_alt state is supported on this LED. If set
+        * to 0, blink_alt state is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED2_STATE_CAPS_BLINK_ALT_SUPPORTED \
+               UINT32_C(0x10)
+       uint16_t led2_color_caps;
+       /* The colors supported by LED #2. */
+       /* reserved */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED2_COLOR_CAPS_RSVD UINT32_C(0x1)
+       /*
+        * If set to 1, Amber color is supported on this LED. If set to
+        * 0, Amber color is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED2_COLOR_CAPS_AMBER_SUPPORTED \
+               UINT32_C(0x2)
+       /*
+        * If set to 1, Green color is supported on this LED. If set to
+        * 0, Green color is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED2_COLOR_CAPS_GREEN_SUPPORTED \
+               UINT32_C(0x4)
+       uint8_t led3_id;
+       /* An identifier for the LED #3. */
+       uint8_t led3_type;
+       /* The type of LED #3. */
+       /* Speed LED */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED3_TYPE_SPEED      UINT32_C(0x0)
+       /* Activity LED */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED3_TYPE_ACTIVITY   UINT32_C(0x1)
+       /* Invalid */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED3_TYPE_INVALID    UINT32_C(0xff)
+       uint8_t led3_group_id;
+       /*
+        * An identifier for the group of LEDs that LED #3 belongs to.
+        * If set to 0, then the LED #0 cannot be grouped. For all other
+        * non-zero values of this field, LED #0 is grouped together
+        * with the LEDs with the same group ID value.
+        */
+       uint8_t unused_4;
+       uint16_t led3_state_caps;
+       /* The states supported by LED #3. */
+       /*
+        * If set to 1, this LED is enabled. If set to 0, this LED is
+        * disabled.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED3_STATE_CAPS_ENABLED UINT32_C(0x1)
+       /*
+        * If set to 1, off state is supported on this LED. If set to 0,
+        * off state is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED3_STATE_CAPS_OFF_SUPPORTED  \
+               UINT32_C(0x2)
+       /*
+        * If set to 1, on state is supported on this LED. If set to 0,
+        * on state is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED3_STATE_CAPS_ON_SUPPORTED   \
+               UINT32_C(0x4)
+       /*
+        * If set to 1, blink state is supported on this LED. If set to
+        * 0, blink state is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED3_STATE_CAPS_BLINK_SUPPORTED \
+               UINT32_C(0x8)
+       /*
+        * If set to 1, blink_alt state is supported on this LED. If set
+        * to 0, blink_alt state is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED3_STATE_CAPS_BLINK_ALT_SUPPORTED \
+               UINT32_C(0x10)
+       uint16_t led3_color_caps;
+       /* The colors supported by LED #3. */
+       /* reserved */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED3_COLOR_CAPS_RSVD UINT32_C(0x1)
+       /*
+        * If set to 1, Amber color is supported on this LED. If set to
+        * 0, Amber color is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED3_COLOR_CAPS_AMBER_SUPPORTED \
+               UINT32_C(0x2)
+       /*
+        * If set to 1, Green color is supported on this LED. If set to
+        * 0, Green color is not supported on this LED.
+        */
+       #define HWRM_PORT_LED_QCAPS_OUTPUT_LED3_COLOR_CAPS_GREEN_SUPPORTED \
+               UINT32_C(0x4)
+       uint8_t unused_5;
+       uint8_t unused_6;
+       uint8_t unused_7;
        uint8_t valid;
        /*
         * This field is used in Output records to indicate that the
@@ -6248,10 +6774,19 @@ struct hwrm_vnic_free_output {
         */
 } __attribute__((packed));
 
-/* hwrm_vnic_cfg */
-/* Description: Configure the RX VNIC structure. */
-/* Input       (40 bytes) */
-struct hwrm_vnic_cfg_input {
+/* hwrm_queue_qportcfg */
+/*
+ * Description: This function is called by a driver to query queue configuration
+ * of a port. # The HWRM shall at least advertise one queue with lossy service
+ * profile. # The driver shall use this command to query queue ids before
+ * configuring or using any queues. # If a service profile is not set for a
+ * queue, then the driver shall not use that queue without configuring a service
+ * profile for it. # If the driver is not allowed to configure service profiles,
+ * then the driver shall only use queues for which service profiles are pre-
+ * configured.
+ */
+/* Input       (24 bytes) */
+struct hwrm_queue_qportcfg_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -6280,101 +6815,1713 @@ struct hwrm_vnic_cfg_input {
         */
        uint32_t flags;
        /*
-        * When this bit is '1', the VNIC is requested to be the default
-        * VNIC for the function.
+        * Enumeration denoting the RX, TX type of the resource. This
+        * enumeration is used for resources that are similar for both
+        * TX and RX paths of the chip.
         */
-       #define HWRM_VNIC_CFG_INPUT_FLAGS_DEFAULT       UINT32_C(0x1)
+       #define HWRM_QUEUE_QPORTCFG_INPUT_FLAGS_PATH    UINT32_C(0x1)
+       /* tx path */
+       #define HWRM_QUEUE_QPORTCFG_INPUT_FLAGS_PATH_TX UINT32_C(0x0)
+       /* rx path */
+       #define HWRM_QUEUE_QPORTCFG_INPUT_FLAGS_PATH_RX UINT32_C(0x1)
+       #define HWRM_QUEUE_QPORTCFG_INPUT_FLAGS_PATH_LAST \
+               QUEUE_QPORTCFG_INPUT_FLAGS_PATH_RX
+       uint16_t port_id;
        /*
-        * When this bit is '1', the VNIC is being configured to strip
-        * VLAN in the RX path. If set to '0', then VLAN stripping is
-        * disabled on this VNIC.
+        * Port ID of port for which the queue configuration is being
+        * queried. This field is only required when sent by IPC.
         */
-       #define HWRM_VNIC_CFG_INPUT_FLAGS_VLAN_STRIP_MODE       UINT32_C(0x2)
+       uint16_t unused_0;
+} __attribute__((packed));
+
+/* Output      (32 bytes) */
+struct hwrm_queue_qportcfg_output {
+       uint16_t error_code;
        /*
-        * When this bit is '1', the VNIC is being configured to buffer
-        * receive packets in the hardware until the host posts new
-        * receive buffers. If set to '0', then bd_stall is being
-        * configured to be disabled on this VNIC.
+        * Pass/Fail or error type Note: receiver to verify the in
+        * parameters, and fail the call with an error when appropriate
         */
-       #define HWRM_VNIC_CFG_INPUT_FLAGS_BD_STALL_MODE UINT32_C(0x4)
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
        /*
-        * When this bit is '1', the VNIC is being configured to receive
+        * This field is the length of the response in bytes. The last
+        * byte of the response is a valid flag that will read as '1'
+        * when the command has been completely written to memory.
+        */
+       uint8_t max_configurable_queues;
+       /*
+        * The maximum number of queues that can be configured on this
+        * port. Valid values range from 1 through 8.
+        */
+       uint8_t max_configurable_lossless_queues;
+       /*
+        * The maximum number of lossless queues that can be configured
+        * on this port. Valid values range from 0 through 8.
+        */
+       uint8_t queue_cfg_allowed;
+       /*
+        * Bitmask indicating which queues can be configured by the
+        * hwrm_queue_cfg command. Each bit represents a specific queue
+        * where bit 0 represents queue 0 and bit 7 represents queue 7.
+        * # A value of 0 indicates that the queue is not configurable
+        * by the hwrm_queue_cfg command. # A value of 1 indicates that
+        * the queue is configurable. # A hwrm_queue_cfg command shall
+        * return error when trying to configure a queue not
+        * configurable.
+        */
+       uint8_t queue_cfg_info;
+       /* Information about queue configuration. */
+       /*
+        * If this flag is set to '1', then the queues are configured
+        * asymmetrically on TX and RX sides. If this flag is set to
+        * '0', then the queues are configured symmetrically on TX and
+        * RX sides. For symmetric configuration, the queue
+        * configuration including queue ids and service profiles on the
+        * TX side is the same as the corresponding queue configuration
+        * on the RX side.
+        */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_CFG_INFO_ASYM_CFG UINT32_C(0x1)
+       uint8_t queue_pfcenable_cfg_allowed;
+       /*
+        * Bitmask indicating which queues can be configured by the
+        * hwrm_queue_pfcenable_cfg command. Each bit represents a
+        * specific priority where bit 0 represents priority 0 and bit 7
+        * represents priority 7. # A value of 0 indicates that the
+        * priority is not configurable by the hwrm_queue_pfcenable_cfg
+        * command. # A value of 1 indicates that the priority is
+        * configurable. # A hwrm_queue_pfcenable_cfg command shall
+        * return error when trying to configure a priority that is not
+        * configurable.
+        */
+       uint8_t queue_pri2cos_cfg_allowed;
+       /*
+        * Bitmask indicating which queues can be configured by the
+        * hwrm_queue_pri2cos_cfg command. Each bit represents a
+        * specific queue where bit 0 represents queue 0 and bit 7
+        * represents queue 7. # A value of 0 indicates that the queue
+        * is not configurable by the hwrm_queue_pri2cos_cfg command. #
+        * A value of 1 indicates that the queue is configurable. # A
+        * hwrm_queue_pri2cos_cfg command shall return error when trying
+        * to configure a queue that is not configurable.
+        */
+       uint8_t queue_cos2bw_cfg_allowed;
+       /*
+        * Bitmask indicating which queues can be configured by the
+        * hwrm_queue_pri2cos_cfg command. Each bit represents a
+        * specific queue where bit 0 represents queue 0 and bit 7
+        * represents queue 7. # A value of 0 indicates that the queue
+        * is not configurable by the hwrm_queue_pri2cos_cfg command. #
+        * A value of 1 indicates that the queue is configurable. # A
+        * hwrm_queue_pri2cos_cfg command shall return error when trying
+        * to configure a queue not configurable.
+        */
+       uint8_t queue_id0;
+       /*
+        * ID of CoS Queue 0. FF - Invalid id # This ID can be used on
+        * any subsequent call to an hwrm command that takes a queue id.
+        * # IDs must always be queried by this command before any use
+        * by the driver or software. # Any driver or software should
+        * not make any assumptions about queue IDs. # A value of 0xff
+        * indicates that the queue is not available. # Available queues
+        * may not be in sequential order.
+        */
+       uint8_t queue_id0_service_profile;
+       /* This value is applicable to CoS queues only. */
+       /* Lossy        (best-effort) */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID0_SERVICE_PROFILE_LOSSY \
+               UINT32_C(0x0)
+       /* Lossless */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID0_SERVICE_PROFILE_LOSSLESS \
+               UINT32_C(0x1)
+       /*
+        * Set to 0xFF...       (All Fs) if there is no
+        * service profile specified
+        */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID0_SERVICE_PROFILE_UNKNOWN \
+               UINT32_C(0xff)
+       uint8_t queue_id1;
+       /*
+        * ID of CoS Queue 1. FF - Invalid id # This ID can be used on
+        * any subsequent call to an hwrm command that takes a queue id.
+        * # IDs must always be queried by this command before any use
+        * by the driver or software. # Any driver or software should
+        * not make any assumptions about queue IDs. # A value of 0xff
+        * indicates that the queue is not available. # Available queues
+        * may not be in sequential order.
+        */
+       uint8_t queue_id1_service_profile;
+       /* This value is applicable to CoS queues only. */
+       /* Lossy        (best-effort) */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID1_SERVICE_PROFILE_LOSSY \
+               UINT32_C(0x0)
+       /* Lossless */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID1_SERVICE_PROFILE_LOSSLESS \
+               UINT32_C(0x1)
+       /*
+        * Set to 0xFF...       (All Fs) if there is no
+        * service profile specified
+        */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID1_SERVICE_PROFILE_UNKNOWN \
+               UINT32_C(0xff)
+       uint8_t queue_id2;
+       /*
+        * ID of CoS Queue 2. FF - Invalid id # This ID can be used on
+        * any subsequent call to an hwrm command that takes a queue id.
+        * # IDs must always be queried by this command before any use
+        * by the driver or software. # Any driver or software should
+        * not make any assumptions about queue IDs. # A value of 0xff
+        * indicates that the queue is not available. # Available queues
+        * may not be in sequential order.
+        */
+       uint8_t queue_id2_service_profile;
+       /* This value is applicable to CoS queues only. */
+       /* Lossy        (best-effort) */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID2_SERVICE_PROFILE_LOSSY \
+               UINT32_C(0x0)
+       /* Lossless */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID2_SERVICE_PROFILE_LOSSLESS \
+               UINT32_C(0x1)
+       /*
+        * Set to 0xFF...       (All Fs) if there is no
+        * service profile specified
+        */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID2_SERVICE_PROFILE_UNKNOWN \
+               UINT32_C(0xff)
+       uint8_t queue_id3;
+       /*
+        * ID of CoS Queue 3. FF - Invalid id # This ID can be used on
+        * any subsequent call to an hwrm command that takes a queue id.
+        * # IDs must always be queried by this command before any use
+        * by the driver or software. # Any driver or software should
+        * not make any assumptions about queue IDs. # A value of 0xff
+        * indicates that the queue is not available. # Available queues
+        * may not be in sequential order.
+        */
+       uint8_t queue_id3_service_profile;
+       /* This value is applicable to CoS queues only. */
+       /* Lossy        (best-effort) */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID3_SERVICE_PROFILE_LOSSY \
+               UINT32_C(0x0)
+       /* Lossless */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID3_SERVICE_PROFILE_LOSSLESS \
+               UINT32_C(0x1)
+       /*
+        * Set to 0xFF...       (All Fs) if there is no
+        * service profile specified
+        */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID3_SERVICE_PROFILE_UNKNOWN \
+               UINT32_C(0xff)
+       uint8_t queue_id4;
+       /*
+        * ID of CoS Queue 4. FF - Invalid id # This ID can be used on
+        * any subsequent call to an hwrm command that takes a queue id.
+        * # IDs must always be queried by this command before any use
+        * by the driver or software. # Any driver or software should
+        * not make any assumptions about queue IDs. # A value of 0xff
+        * indicates that the queue is not available. # Available queues
+        * may not be in sequential order.
+        */
+       uint8_t queue_id4_service_profile;
+       /* This value is applicable to CoS queues only. */
+       /* Lossy        (best-effort) */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID4_SERVICE_PROFILE_LOSSY \
+               UINT32_C(0x0)
+       /* Lossless */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID4_SERVICE_PROFILE_LOSSLESS \
+               UINT32_C(0x1)
+       /*
+        * Set to 0xFF...       (All Fs) if there is no
+        * service profile specified
+        */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID4_SERVICE_PROFILE_UNKNOWN \
+               UINT32_C(0xff)
+       uint8_t queue_id5;
+       /*
+        * ID of CoS Queue 5. FF - Invalid id # This ID can be used on
+        * any subsequent call to an hwrm command that takes a queue id.
+        * # IDs must always be queried by this command before any use
+        * by the driver or software. # Any driver or software should
+        * not make any assumptions about queue IDs. # A value of 0xff
+        * indicates that the queue is not available. # Available queues
+        * may not be in sequential order.
+        */
+       uint8_t queue_id5_service_profile;
+       /* This value is applicable to CoS queues only. */
+       /* Lossy        (best-effort) */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID5_SERVICE_PROFILE_LOSSY \
+               UINT32_C(0x0)
+       /* Lossless */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID5_SERVICE_PROFILE_LOSSLESS \
+               UINT32_C(0x1)
+       /*
+        * Set to 0xFF...       (All Fs) if there is no
+        * service profile specified
+        */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID5_SERVICE_PROFILE_UNKNOWN \
+               UINT32_C(0xff)
+       uint8_t queue_id6;
+       /*
+        * ID of CoS Queue 6. FF - Invalid id # This ID can be used on
+        * any subsequent call to an hwrm command that takes a queue id.
+        * # IDs must always be queried by this command before any use
+        * by the driver or software. # Any driver or software should
+        * not make any assumptions about queue IDs. # A value of 0xff
+        * indicates that the queue is not available. # Available queues
+        * may not be in sequential order.
+        */
+       uint8_t queue_id6_service_profile;
+       /* This value is applicable to CoS queues only. */
+       /* Lossy        (best-effort) */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID6_SERVICE_PROFILE_LOSSY \
+               UINT32_C(0x0)
+       /* Lossless */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID6_SERVICE_PROFILE_LOSSLESS \
+               UINT32_C(0x1)
+       /*
+        * Set to 0xFF...       (All Fs) if there is no
+        * service profile specified
+        */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID6_SERVICE_PROFILE_UNKNOWN \
+               UINT32_C(0xff)
+       uint8_t queue_id7;
+       /*
+        * ID of CoS Queue 7. FF - Invalid id # This ID can be used on
+        * any subsequent call to an hwrm command that takes a queue id.
+        * # IDs must always be queried by this command before any use
+        * by the driver or software. # Any driver or software should
+        * not make any assumptions about queue IDs. # A value of 0xff
+        * indicates that the queue is not available. # Available queues
+        * may not be in sequential order.
+        */
+       uint8_t queue_id7_service_profile;
+       /* This value is applicable to CoS queues only. */
+       /* Lossy        (best-effort) */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID7_SERVICE_PROFILE_LOSSY \
+               UINT32_C(0x0)
+       /* Lossless */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID7_SERVICE_PROFILE_LOSSLESS \
+               UINT32_C(0x1)
+       /*
+        * Set to 0xFF...       (All Fs) if there is no
+        * service profile specified
+        */
+       #define HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID7_SERVICE_PROFILE_UNKNOWN \
+               UINT32_C(0xff)
+       uint8_t valid;
+       /*
+        * This field is used in Output records to indicate that the
+        * output is completely written to RAM. This field should be
+        * read as '1' to indicate that the output has been completely
+        * written. When writing a command completion or response to an
+        * internal processor, the order of writes has to be such that
+        * this field is written last.
+        */
+} __attribute__((packed));
+
+/* hwrm_vnic_alloc */
+/*
+ * Description: This VNIC is a resource in the RX side of the chip that is used
+ * to represent a virtual host "interface". # At the time of VNIC allocation or
+ * configuration, the function can specify whether it wants the requested VNIC
+ * to be the default VNIC for the function or not. # If a function requests
+ * allocation of a VNIC for the first time and a VNIC is successfully allocated
+ * by the HWRM, then the HWRM shall make the allocated VNIC as the default VNIC
+ * for that function. # The default VNIC shall be used for the default action
+ * for a partition or function. # For each VNIC allocated on a function, a
+ * mapping on the RX side to map the allocated VNIC to source virtual interface
+ * shall be performed by the HWRM. This should be hidden to the function driver
+ * requesting the VNIC allocation. This enables broadcast/multicast replication
+ * with source knockout. # If multicast replication with source knockout is
+ * enabled, then the internal VNIC to SVIF mapping data structures shall be
+ * programmed at the time of VNIC allocation.
+ */
+/* Input       (24 bytes) */
+struct hwrm_vnic_alloc_input {
+       uint16_t req_type;
+       /*
+        * This value indicates what type of request this is. The format
+        * for the rest of the command is determined by this field.
+        */
+       uint16_t cmpl_ring;
+       /*
+        * This value indicates the what completion ring the request
+        * will be optionally completed on. If the value is -1, then no
+        * CR completion will be generated. Any other value must be a
+        * valid CR ring_id value for this function.
+        */
+       uint16_t seq_id;
+       /* This value indicates the command sequence number. */
+       uint16_t target_id;
+       /*
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function
+        * ids 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF
+        * - HWRM
+        */
+       uint64_t resp_addr;
+       /*
+        * This is the host address where the response will be written
+        * when the request is complete. This area must be 16B aligned
+        * and must be cleared to zero before the request is made.
+        */
+       uint32_t flags;
+       /*
+        * When this bit is '1', this VNIC is requested to be the
+        * default VNIC for this function.
+        */
+       #define HWRM_VNIC_ALLOC_INPUT_FLAGS_DEFAULT     UINT32_C(0x1)
+       uint32_t unused_0;
+} __attribute__((packed));
+
+/* Output      (16 bytes) */
+struct hwrm_vnic_alloc_output {
+       uint16_t error_code;
+       /*
+        * Pass/Fail or error type Note: receiver to verify the in
+        * parameters, and fail the call with an error when appropriate
+        */
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
+       /*
+        * This field is the length of the response in bytes. The last
+        * byte of the response is a valid flag that will read as '1'
+        * when the command has been completely written to memory.
+        */
+       uint32_t vnic_id;
+       /* Logical vnic ID */
+       uint8_t unused_0;
+       uint8_t unused_1;
+       uint8_t unused_2;
+       uint8_t valid;
+       /*
+        * This field is used in Output records to indicate that the
+        * output is completely written to RAM. This field should be
+        * read as '1' to indicate that the output has been completely
+        * written. When writing a command completion or response to an
+        * internal processor, the order of writes has to be such that
+        * this field is written last.
+        */
+} __attribute__((packed));
+
+/* hwrm_vnic_free */
+/*
+ * Description: Free a VNIC resource. Idle any resources associated with the
+ * VNIC as well as the VNIC. Reset and release all resources associated with the
+ * VNIC.
+ */
+/* Input       (24 bytes) */
+struct hwrm_vnic_free_input {
+       uint16_t req_type;
+       /*
+        * This value indicates what type of request this is. The format
+        * for the rest of the command is determined by this field.
+        */
+       uint16_t cmpl_ring;
+       /*
+        * This value indicates the what completion ring the request
+        * will be optionally completed on. If the value is -1, then no
+        * CR completion will be generated. Any other value must be a
+        * valid CR ring_id value for this function.
+        */
+       uint16_t seq_id;
+       /* This value indicates the command sequence number. */
+       uint16_t target_id;
+       /*
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function
+        * ids 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF
+        * - HWRM
+        */
+       uint64_t resp_addr;
+       /*
+        * This is the host address where the response will be written
+        * when the request is complete. This area must be 16B aligned
+        * and must be cleared to zero before the request is made.
+        */
+       uint32_t vnic_id;
+       /* Logical vnic ID */
+       uint32_t unused_0;
+} __attribute__((packed));
+
+/* Output      (16 bytes) */
+struct hwrm_vnic_free_output {
+       uint16_t error_code;
+       /*
+        * Pass/Fail or error type Note: receiver to verify the in
+        * parameters, and fail the call with an error when appropriate
+        */
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
+       /*
+        * This field is the length of the response in bytes. The last
+        * byte of the response is a valid flag that will read as '1'
+        * when the command has been completely written to memory.
+        */
+       uint32_t unused_0;
+       uint8_t unused_1;
+       uint8_t unused_2;
+       uint8_t unused_3;
+       uint8_t valid;
+       /*
+        * This field is used in Output records to indicate that the
+        * output is completely written to RAM. This field should be
+        * read as '1' to indicate that the output has been completely
+        * written. When writing a command completion or response to an
+        * internal processor, the order of writes has to be such that
+        * this field is written last.
+        */
+} __attribute__((packed));
+
+/* hwrm_vnic_cfg */
+/* Description: Configure the RX VNIC structure. */
+/* Input       (40 bytes) */
+struct hwrm_vnic_cfg_input {
+       uint16_t req_type;
+       /*
+        * This value indicates what type of request this is. The format
+        * for the rest of the command is determined by this field.
+        */
+       uint16_t cmpl_ring;
+       /*
+        * This value indicates the what completion ring the request
+        * will be optionally completed on. If the value is -1, then no
+        * CR completion will be generated. Any other value must be a
+        * valid CR ring_id value for this function.
+        */
+       uint16_t seq_id;
+       /* This value indicates the command sequence number. */
+       uint16_t target_id;
+       /*
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function
+        * ids 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF
+        * - HWRM
+        */
+       uint64_t resp_addr;
+       /*
+        * This is the host address where the response will be written
+        * when the request is complete. This area must be 16B aligned
+        * and must be cleared to zero before the request is made.
+        */
+       uint32_t flags;
+       /*
+        * When this bit is '1', the VNIC is requested to be the default
+        * VNIC for the function.
+        */
+       #define HWRM_VNIC_CFG_INPUT_FLAGS_DEFAULT       UINT32_C(0x1)
+       /*
+        * When this bit is '1', the VNIC is being configured to strip
+        * VLAN in the RX path. If set to '0', then VLAN stripping is
+        * disabled on this VNIC.
+        */
+       #define HWRM_VNIC_CFG_INPUT_FLAGS_VLAN_STRIP_MODE       UINT32_C(0x2)
+       /*
+        * When this bit is '1', the VNIC is being configured to buffer
+        * receive packets in the hardware until the host posts new
+        * receive buffers. If set to '0', then bd_stall is being
+        * configured to be disabled on this VNIC.
+        */
+       #define HWRM_VNIC_CFG_INPUT_FLAGS_BD_STALL_MODE UINT32_C(0x4)
+       /*
+        * When this bit is '1', the VNIC is being configured to receive
         * both RoCE and non-RoCE traffic. If set to '0', then this VNIC
         * is not configured to be operating in dual VNIC mode.
         */
-       #define HWRM_VNIC_CFG_INPUT_FLAGS_ROCE_DUAL_VNIC_MODE   UINT32_C(0x8)
+       #define HWRM_VNIC_CFG_INPUT_FLAGS_ROCE_DUAL_VNIC_MODE   UINT32_C(0x8)
+       /*
+        * When this flag is set to '1', the VNIC is requested to be
+        * configured to receive only RoCE traffic. If this flag is set
+        * to '0', then this flag shall be ignored by the HWRM. If
+        * roce_dual_vnic_mode flag is set to '1', then the HWRM client
+        * shall not set this flag to '1'.
+        */
+       #define HWRM_VNIC_CFG_INPUT_FLAGS_ROCE_ONLY_VNIC_MODE UINT32_C(0x10)
+       /*
+        * When a VNIC uses one destination ring group for certain
+        * application  (e.g. Receive Flow Steering) where exact match is
+        * used to direct packets to a VNIC with one destination ring
+        * group only, there is no need to configure RSS indirection
+        * table for that VNIC as only one destination ring group is
+        * used. This flag is used to enable a mode where RSS is enabled
+        * in the VNIC using a RSS context for computing RSS hash but
+        * the RSS indirection table is not configured using
+        * hwrm_vnic_rss_cfg. If this mode is enabled, then the driver
+        * should not program RSS indirection table for the RSS context
+        * that is used for computing RSS hash only.
+        */
+       #define HWRM_VNIC_CFG_INPUT_FLAGS_RSS_DFLT_CR_MODE      UINT32_C(0x20)
+       /*
+        * When this bit is '1', the VNIC is being configured to receive
+        * both RoCE and non-RoCE traffic, but forward only the RoCE
+        * traffic further. Also, RoCE traffic can be mirrored to L2
+        * driver.
+        */
+       #define HWRM_VNIC_CFG_INPUT_FLAGS_ROCE_MIRRORING_CAPABLE_VNIC_MODE \
+       UINT32_C(0x40)
+       uint32_t enables;
+       /*
+        * This bit must be '1' for the dflt_ring_grp field to be
+        * configured.
+        */
+       #define HWRM_VNIC_CFG_INPUT_ENABLES_DFLT_RING_GRP       UINT32_C(0x1)
+       /* This bit must be '1' for the rss_rule field to be configured. */
+       #define HWRM_VNIC_CFG_INPUT_ENABLES_RSS_RULE    UINT32_C(0x2)
+       /* This bit must be '1' for the cos_rule field to be configured. */
+       #define HWRM_VNIC_CFG_INPUT_ENABLES_COS_RULE    UINT32_C(0x4)
+       /* This bit must be '1' for the lb_rule field to be configured. */
+       #define HWRM_VNIC_CFG_INPUT_ENABLES_LB_RULE     UINT32_C(0x8)
+       /* This bit must be '1' for the mru field to be configured. */
+       #define HWRM_VNIC_CFG_INPUT_ENABLES_MRU UINT32_C(0x10)
+       uint16_t vnic_id;
+       /* Logical vnic ID */
+       uint16_t dflt_ring_grp;
+       /*
+        * Default Completion ring for the VNIC. This ring will be
+        * chosen if packet does not match any RSS rules and if there is
+        * no COS rule.
+        */
+       uint16_t rss_rule;
+       /*
+        * RSS ID for RSS rule/table structure. 0xFF... (All Fs) if
+        * there is no RSS rule.
+        */
+       uint16_t cos_rule;
+       /*
+        * RSS ID for COS rule/table structure. 0xFF... (All Fs) if
+        * there is no COS rule.
+        */
+       uint16_t lb_rule;
+       /*
+        * RSS ID for load balancing rule/table structure. 0xFF...      (All
+        * Fs) if there is no LB rule.
+        */
+       uint16_t mru;
+       /*
+        * The maximum receive unit of the vnic. Each vnic is associated
+        * with a function. The vnic mru value overwrites the mru
+        * setting of the associated function. The HWRM shall make sure
+        * that vnic mru does not exceed the mru of the port the
+        * function is associated with.
+        */
+       uint32_t unused_0;
+} __attribute__((packed));
+
+/* Output      (16 bytes) */
+struct hwrm_vnic_cfg_output {
+       uint16_t error_code;
+       /*
+        * Pass/Fail or error type Note: receiver to verify the in
+        * parameters, and fail the call with an error when appropriate
+        */
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
+       /*
+        * This field is the length of the response in bytes. The last
+        * byte of the response is a valid flag that will read as '1'
+        * when the command has been completely written to memory.
+        */
+       uint32_t unused_0;
+       uint8_t unused_1;
+       uint8_t unused_2;
+       uint8_t unused_3;
+       uint8_t valid;
+       /*
+        * This field is used in Output records to indicate that the
+        * output is completely written to RAM. This field should be
+        * read as '1' to indicate that the output has been completely
+        * written. When writing a command completion or response to an
+        * internal processor, the order of writes has to be such that
+        * this field is written last.
+        */
+} __attribute__((packed));
+
+/* hwrm_vnic_qcfg */
+/*
+ * Description: Query the RX VNIC structure. This function can be used by a PF
+ * driver to query its own VNIC resource or VNIC resource of its child VF. This
+ * function can also be used by a VF driver to query its own VNIC resource.
+ */
+/* Input       (32 bytes) */
+struct hwrm_vnic_qcfg_input {
+       uint16_t req_type;
+       /*
+        * This value indicates what type of request this is. The format
+        * for the rest of the command is determined by this field.
+        */
+       uint16_t cmpl_ring;
+       /*
+        * This value indicates the what completion ring the request
+        * will be optionally completed on. If the value is -1, then no
+        * CR completion will be generated. Any other value must be a
+        * valid CR ring_id value for this function.
+        */
+       uint16_t seq_id;
+       /* This value indicates the command sequence number. */
+       uint16_t target_id;
+       /*
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function
+        * ids 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF
+        * - HWRM
+        */
+       uint64_t resp_addr;
+       /*
+        * This is the host address where the response will be written
+        * when the request is complete. This area must be 16B aligned
+        * and must be cleared to zero before the request is made.
+        */
+       uint32_t enables;
+       /* This bit must be '1' for the vf_id_valid field to be configured. */
+       #define HWRM_VNIC_QCFG_INPUT_ENABLES_VF_ID_VALID        UINT32_C(0x1)
+       uint32_t vnic_id;
+       /* Logical vnic ID */
+       uint16_t vf_id;
+       /* ID of Virtual Function whose VNIC resource is being queried. */
+       uint16_t unused_0[3];
+} __attribute__((packed));
+
+/* Output      (32 bytes) */
+struct hwrm_vnic_qcfg_output {
+       uint16_t error_code;
+       /*
+        * Pass/Fail or error type Note: receiver to verify the in
+        * parameters, and fail the call with an error when appropriate
+        */
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
+       /*
+        * This field is the length of the response in bytes. The last
+        * byte of the response is a valid flag that will read as '1'
+        * when the command has been completely written to memory.
+        */
+       uint16_t dflt_ring_grp;
+       /* Default Completion ring for the VNIC. */
+       uint16_t rss_rule;
+       /*
+        * RSS ID for RSS rule/table structure. 0xFF... (All Fs) if
+        * there is no RSS rule.
+        */
+       uint16_t cos_rule;
+       /*
+        * RSS ID for COS rule/table structure. 0xFF... (All Fs) if
+        * there is no COS rule.
+        */
+       uint16_t lb_rule;
+       /*
+        * RSS ID for load balancing rule/table structure. 0xFF...      (All
+        * Fs) if there is no LB rule.
+        */
+       uint16_t mru;
+       /* The maximum receive unit of the vnic. */
+       uint8_t unused_0;
+       uint8_t unused_1;
+       uint32_t flags;
+       /*
+        * When this bit is '1', the VNIC is the default VNIC for the
+        * function.
+        */
+       #define HWRM_VNIC_QCFG_OUTPUT_FLAGS_DEFAULT     UINT32_C(0x1)
+       /*
+        * When this bit is '1', the VNIC is configured to strip VLAN in
+        * the RX path. If set to '0', then VLAN stripping is disabled
+        * on this VNIC.
+        */
+       #define HWRM_VNIC_QCFG_OUTPUT_FLAGS_VLAN_STRIP_MODE     UINT32_C(0x2)
+       /*
+        * When this bit is '1', the VNIC is configured to buffer
+        * receive packets in the hardware until the host posts new
+        * receive buffers. If set to '0', then bd_stall is disabled on
+        * this VNIC.
+        */
+       #define HWRM_VNIC_QCFG_OUTPUT_FLAGS_BD_STALL_MODE       UINT32_C(0x4)
+       /*
+        * When this bit is '1', the VNIC is configured to receive both
+        * RoCE and non-RoCE traffic. If set to '0', then this VNIC is
+        * not configured to operate in dual VNIC mode.
+        */
+       #define HWRM_VNIC_QCFG_OUTPUT_FLAGS_ROCE_DUAL_VNIC_MODE UINT32_C(0x8)
+       /*
+        * When this flag is set to '1', the VNIC is configured to
+        * receive only RoCE traffic. When this flag is set to '0', the
+        * VNIC is not configured to receive only RoCE traffic. If
+        * roce_dual_vnic_mode flag and this flag both are set to '1',
+        * then it is an invalid configuration of the VNIC. The HWRM
+        * should not allow that type of mis-configuration by HWRM
+        * clients.
+        */
+       #define HWRM_VNIC_QCFG_OUTPUT_FLAGS_ROCE_ONLY_VNIC_MODE UINT32_C(0x10)
+       /*
+        * When a VNIC uses one destination ring group for certain
+        * application  (e.g. Receive Flow Steering) where exact match is
+        * used to direct packets to a VNIC with one destination ring
+        * group only, there is no need to configure RSS indirection
+        * table for that VNIC as only one destination ring group is
+        * used. When this bit is set to '1', then the VNIC is enabled
+        * in a mode where RSS is enabled in the VNIC using a RSS
+        * context for computing RSS hash but the RSS indirection table
+        * is not configured.
+        */
+       #define HWRM_VNIC_QCFG_OUTPUT_FLAGS_RSS_DFLT_CR_MODE    UINT32_C(0x20)
+       /*
+        * When this bit is '1', the VNIC is configured to receive both
+        * RoCE and non-RoCE traffic, but forward only RoCE traffic
+        * further. Also RoCE traffic can be mirrored to L2 driver.
+        */
+       #define HWRM_VNIC_QCFG_OUTPUT_FLAGS_ROCE_MIRRORING_CAPABLE_VNIC_MODE \
+       UINT32_C(0x40)
+       uint32_t unused_2;
+       uint8_t unused_3;
+       uint8_t unused_4;
+       uint8_t unused_5;
+       uint8_t valid;
+       /*
+        * This field is used in Output records to indicate that the
+        * output is completely written to RAM. This field should be
+        * read as '1' to indicate that the output has been completely
+        * written. When writing a command completion or response to an
+        * internal processor, the order of writes has to be such that
+        * this field is written last.
+        */
+} __attribute__((packed));
+
+
+/* hwrm_vnic_tpa_cfg */
+/* Description: This function is used to enable/configure TPA on the VNIC. */
+/* Input       (40 bytes) */
+struct hwrm_vnic_tpa_cfg_input {
+       uint16_t req_type;
+       /*
+        * This value indicates what type of request this is. The format
+        * for the rest of the command is determined by this field.
+        */
+       uint16_t cmpl_ring;
+       /*
+        * This value indicates the what completion ring the request
+        * will be optionally completed on. If the value is -1, then no
+        * CR completion will be generated. Any other value must be a
+        * valid CR ring_id value for this function.
+        */
+       uint16_t seq_id;
+       /* This value indicates the command sequence number. */
+       uint16_t target_id;
+       /*
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function
+        * ids 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF
+        * - HWRM
+        */
+       uint64_t resp_addr;
+       /*
+        * This is the host address where the response will be written
+        * when the request is complete. This area must be 16B aligned
+        * and must be cleared to zero before the request is made.
+        */
+       uint32_t flags;
+       /*
+        * When this bit is '1', the VNIC shall be configured to perform
+        * transparent packet aggregation       (TPA) of non-tunneled TCP
+        * packets.
+        */
+       #define HWRM_VNIC_TPA_CFG_INPUT_FLAGS_TPA       UINT32_C(0x1)
+       /*
+        * When this bit is '1', the VNIC shall be configured to perform
+        * transparent packet aggregation       (TPA) of tunneled TCP packets.
+        */
+       #define HWRM_VNIC_TPA_CFG_INPUT_FLAGS_ENCAP_TPA UINT32_C(0x2)
+       /*
+        * When this bit is '1', the VNIC shall be configured to perform
+        * transparent packet aggregation       (TPA) according to Windows
+        * Receive Segment Coalescing   (RSC) rules.
+        */
+       #define HWRM_VNIC_TPA_CFG_INPUT_FLAGS_RSC_WND_UPDATE    UINT32_C(0x4)
+       /*
+        * When this bit is '1', the VNIC shall be configured to perform
+        * transparent packet aggregation       (TPA) according to Linux
+        * Generic Receive Offload      (GRO) rules.
+        */
+       #define HWRM_VNIC_TPA_CFG_INPUT_FLAGS_GRO       UINT32_C(0x8)
+       /*
+        * When this bit is '1', the VNIC shall be configured to perform
+        * transparent packet aggregation       (TPA) for TCP packets with IP
+        * ECN set to non-zero.
+        */
+       #define HWRM_VNIC_TPA_CFG_INPUT_FLAGS_AGG_WITH_ECN      UINT32_C(0x10)
+       /*
+        * When this bit is '1', the VNIC shall be configured to perform
+        * transparent packet aggregation       (TPA) for GRE tunneled TCP
+        * packets only if all packets have the same GRE sequence.
+        */
+       #define HWRM_VNIC_TPA_CFG_INPUT_FLAGS_AGG_WITH_SAME_GRE_SEQ     \
+               UINT32_C(0x20)
+       /*
+        * When this bit is '1' and the GRO mode is enabled, the VNIC
+        * shall be configured to perform transparent packet aggregation
+        *      (TPA) for TCP/IPv4 packets with consecutively increasing
+        * IPIDs. In other words, the last packet that is being
+        * aggregated to an already existing aggregation context shall
+        * have IPID 1 more than the IPID of the last packet that was
+        * aggregated in that aggregation context.
+        */
+       #define HWRM_VNIC_TPA_CFG_INPUT_FLAGS_GRO_IPID_CHECK    UINT32_C(0x40)
+       /*
+        * When this bit is '1' and the GRO mode is enabled, the VNIC
+        * shall be configured to perform transparent packet aggregation
+        *      (TPA) for TCP packets with the same TTL (IPv4) or Hop limit
+        *      (IPv6) value.
+        */
+       #define HWRM_VNIC_TPA_CFG_INPUT_FLAGS_GRO_TTL_CHECK     UINT32_C(0x80)
+       uint32_t enables;
+       /* This bit must be '1' for the max_agg_segs field to be configured. */
+       #define HWRM_VNIC_TPA_CFG_INPUT_ENABLES_MAX_AGG_SEGS    UINT32_C(0x1)
+       /* This bit must be '1' for the max_aggs field to be configured. */
+       #define HWRM_VNIC_TPA_CFG_INPUT_ENABLES_MAX_AGGS        UINT32_C(0x2)
+       /*
+        * This bit must be '1' for the max_agg_timer field to be
+        * configured.
+        */
+       #define HWRM_VNIC_TPA_CFG_INPUT_ENABLES_MAX_AGG_TIMER   UINT32_C(0x4)
+       /* This bit must be '1' for the min_agg_len field to be configured. */
+       #define HWRM_VNIC_TPA_CFG_INPUT_ENABLES_MIN_AGG_LEN     UINT32_C(0x8)
+       uint16_t vnic_id;
+       /* Logical vnic ID */
+       uint16_t max_agg_segs;
+       /*
+        * This is the maximum number of TCP segments that can be
+        * aggregated   (unit is Log2). Max value is 31.
+        */
+       /* 1 segment */
+       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGG_SEGS_1  UINT32_C(0x0)
+       /* 2 segments */
+       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGG_SEGS_2  UINT32_C(0x1)
+       /* 4 segments */
+       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGG_SEGS_4  UINT32_C(0x2)
+       /* 8 segments */
+       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGG_SEGS_8  UINT32_C(0x3)
+       /* Any segment size larger than this is not valid */
+       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGG_SEGS_MAX        UINT32_C(0x1f)
+       uint16_t max_aggs;
+       /*
+        * This is the maximum number of aggregations this VNIC is
+        * allowed      (unit is Log2). Max value is 7
+        */
+       /* 1 aggregation */
+       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGGS_1      UINT32_C(0x0)
+       /* 2 aggregations */
+       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGGS_2      UINT32_C(0x1)
+       /* 4 aggregations */
+       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGGS_4      UINT32_C(0x2)
+       /* 8 aggregations */
+       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGGS_8      UINT32_C(0x3)
+       /* 16 aggregations */
+       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGGS_16     UINT32_C(0x4)
+       /* Any aggregation size larger than this is not valid */
+       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGGS_MAX    UINT32_C(0x7)
+       uint8_t unused_0;
+       uint8_t unused_1;
+       uint32_t max_agg_timer;
+       /*
+        * This is the maximum amount of time allowed for an aggregation
+        * context to complete after it was initiated.
+        */
+       uint32_t min_agg_len;
+       /*
+        * This is the minimum amount of payload length required to
+        * start an aggregation context.
+        */
+} __attribute__((packed));
+
+/* Output      (16 bytes) */
+struct hwrm_vnic_tpa_cfg_output {
+       uint16_t error_code;
+       /*
+        * Pass/Fail or error type Note: receiver to verify the in
+        * parameters, and fail the call with an error when appropriate
+        */
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
+       /*
+        * This field is the length of the response in bytes. The last
+        * byte of the response is a valid flag that will read as '1'
+        * when the command has been completely written to memory.
+        */
+       uint32_t unused_0;
+       uint8_t unused_1;
+       uint8_t unused_2;
+       uint8_t unused_3;
+       uint8_t valid;
+       /*
+        * This field is used in Output records to indicate that the
+        * output is completely written to RAM. This field should be
+        * read as '1' to indicate that the output has been completely
+        * written. When writing a command completion or response to an
+        * internal processor, the order of writes has to be such that
+        * this field is written last.
+        */
+} __attribute__((packed));
+
+/* hwrm_vnic_rss_cfg */
+/* Description: This function is used to enable RSS configuration. */
+/* Input       (48 bytes) */
+struct hwrm_vnic_rss_cfg_input {
+       uint16_t req_type;
+       /*
+        * This value indicates what type of request this is. The format
+        * for the rest of the command is determined by this field.
+        */
+       uint16_t cmpl_ring;
+       /*
+        * This value indicates the what completion ring the request
+        * will be optionally completed on. If the value is -1, then no
+        * CR completion will be generated. Any other value must be a
+        * valid CR ring_id value for this function.
+        */
+       uint16_t seq_id;
+       /* This value indicates the command sequence number. */
+       uint16_t target_id;
+       /*
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function
+        * ids 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF
+        * - HWRM
+        */
+       uint64_t resp_addr;
+       /*
+        * This is the host address where the response will be written
+        * when the request is complete. This area must be 16B aligned
+        * and must be cleared to zero before the request is made.
+        */
+       uint32_t hash_type;
+       /*
+        * When this bit is '1', the RSS hash shall be computed over
+        * source and destination IPv4 addresses of IPv4 packets.
+        */
+       #define HWRM_VNIC_RSS_CFG_INPUT_HASH_TYPE_IPV4  UINT32_C(0x1)
+       /*
+        * When this bit is '1', the RSS hash shall be computed over
+        * source/destination IPv4 addresses and source/destination
+        * ports of TCP/IPv4 packets.
+        */
+       #define HWRM_VNIC_RSS_CFG_INPUT_HASH_TYPE_TCP_IPV4      UINT32_C(0x2)
+       /*
+        * When this bit is '1', the RSS hash shall be computed over
+        * source/destination IPv4 addresses and source/destination
+        * ports of UDP/IPv4 packets.
+        */
+       #define HWRM_VNIC_RSS_CFG_INPUT_HASH_TYPE_UDP_IPV4      UINT32_C(0x4)
+       /*
+        * When this bit is '1', the RSS hash shall be computed over
+        * source and destination IPv4 addresses of IPv6 packets.
+        */
+       #define HWRM_VNIC_RSS_CFG_INPUT_HASH_TYPE_IPV6  UINT32_C(0x8)
+       /*
+        * When this bit is '1', the RSS hash shall be computed over
+        * source/destination IPv6 addresses and source/destination
+        * ports of TCP/IPv6 packets.
+        */
+       #define HWRM_VNIC_RSS_CFG_INPUT_HASH_TYPE_TCP_IPV6      UINT32_C(0x10)
+       /*
+        * When this bit is '1', the RSS hash shall be computed over
+        * source/destination IPv6 addresses and source/destination
+        * ports of UDP/IPv6 packets.
+        */
+       #define HWRM_VNIC_RSS_CFG_INPUT_HASH_TYPE_UDP_IPV6      UINT32_C(0x20)
+       uint32_t unused_0;
+       uint64_t ring_grp_tbl_addr;
+       /* This is the address for rss ring group table */
+       uint64_t hash_key_tbl_addr;
+       /* This is the address for rss hash key table */
+       uint16_t rss_ctx_idx;
+       /* Index to the rss indirection table. */
+       uint16_t unused_1[3];
+} __attribute__((packed));
+
+/* Output      (16 bytes) */
+struct hwrm_vnic_rss_cfg_output {
+       uint16_t error_code;
+       /*
+        * Pass/Fail or error type Note: receiver to verify the in
+        * parameters, and fail the call with an error when appropriate
+        */
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
+       /*
+        * This field is the length of the response in bytes. The last
+        * byte of the response is a valid flag that will read as '1'
+        * when the command has been completely written to memory.
+        */
+       uint32_t unused_0;
+       uint8_t unused_1;
+       uint8_t unused_2;
+       uint8_t unused_3;
+       uint8_t valid;
+       /*
+        * This field is used in Output records to indicate that the
+        * output is completely written to RAM. This field should be
+        * read as '1' to indicate that the output has been completely
+        * written. When writing a command completion or response to an
+        * internal processor, the order of writes has to be such that
+        * this field is written last.
+        */
+} __attribute__((packed));
+
+/* hwrm_vnic_plcmodes_cfg */
+/*
+ * Description: This function can be used to set placement mode configuration of
+ * the VNIC.
+ */
+/* Input (40 bytes) */
+struct hwrm_vnic_plcmodes_cfg_input {
+       uint16_t req_type;
+       /*
+        * This value indicates what type of request this is. The format for the
+        * rest of the command is determined by this field.
+        */
+       uint16_t cmpl_ring;
+       /*
+        * This value indicates the what completion ring the request will be
+        * optionally completed on. If the value is -1, then no CR completion
+        * will be generated. Any other value must be a valid CR ring_id value
+        * for this function.
+        */
+       uint16_t seq_id;
+       /* This value indicates the command sequence number. */
+       uint16_t target_id;
+       /*
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function ids
+        * 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF - HWRM
+        */
+       uint64_t resp_addr;
+       /*
+        * This is the host address where the response will be written when the
+        * request is complete. This area must be 16B aligned and must be
+        * cleared to zero before the request is made.
+        */
+       uint32_t flags;
+       /*
+        * When this bit is '1', the VNIC shall be configured to use regular
+        * placement algorithm. By default, the regular placement algorithm
+        * shall be enabled on the VNIC.
+        */
+       #define HWRM_VNIC_PLCMODES_CFG_INPUT_FLAGS_REGULAR_PLACEMENT \
+               UINT32_C(0x1)
+       /*
+        * When this bit is '1', the VNIC shall be configured use the jumbo
+        * placement algorithm.
+        */
+       #define HWRM_VNIC_PLCMODES_CFG_INPUT_FLAGS_JUMBO_PLACEMENT \
+               UINT32_C(0x2)
+       /*
+        * When this bit is '1', the VNIC shall be configured to enable Header-
+        * Data split for IPv4 packets according to the following rules: # If
+        * the packet is identified as TCP/IPv4, then the packet is split at the
+        * beginning of the TCP payload. # If the packet is identified as
+        * UDP/IPv4, then the packet is split at the beginning of UDP payload. #
+        * If the packet is identified as non-TCP and non-UDP IPv4 packet, then
+        * the packet is split at the beginning of the upper layer protocol
+        * header carried in the IPv4 packet.
+        */
+       #define HWRM_VNIC_PLCMODES_CFG_INPUT_FLAGS_HDS_IPV4        UINT32_C(0x4)
+       /*
+        * When this bit is '1', the VNIC shall be configured to enable Header-
+        * Data split for IPv6 packets according to the following rules: # If
+        * the packet is identified as TCP/IPv6, then the packet is split at the
+        * beginning of the TCP payload. # If the packet is identified as
+        * UDP/IPv6, then the packet is split at the beginning of UDP payload. #
+        * If the packet is identified as non-TCP and non-UDP IPv6 packet, then
+        * the packet is split at the beginning of the upper layer protocol
+        * header carried in the IPv6 packet.
+        */
+       #define HWRM_VNIC_PLCMODES_CFG_INPUT_FLAGS_HDS_IPV6        UINT32_C(0x8)
+       /*
+        * When this bit is '1', the VNIC shall be configured to enable Header-
+        * Data split for FCoE packets at the beginning of FC payload.
+        */
+       #define HWRM_VNIC_PLCMODES_CFG_INPUT_FLAGS_HDS_FCOE       UINT32_C(0x10)
+       /*
+        * When this bit is '1', the VNIC shall be configured to enable Header-
+        * Data split for RoCE packets at the beginning of RoCE payload (after
+        * BTH/GRH headers).
+        */
+       #define HWRM_VNIC_PLCMODES_CFG_INPUT_FLAGS_HDS_ROCE       UINT32_C(0x20)
+       uint32_t enables;
+       /*
+        * This bit must be '1' for the jumbo_thresh_valid field to be
+        * configured.
+        */
+       #define HWRM_VNIC_PLCMODES_CFG_INPUT_ENABLES_JUMBO_THRESH_VALID \
+               UINT32_C(0x1)
+       /*
+        * This bit must be '1' for the hds_offset_valid field to be configured.
+        */
+       #define HWRM_VNIC_PLCMODES_CFG_INPUT_ENABLES_HDS_OFFSET_VALID \
+               UINT32_C(0x2)
+       /*
+        * This bit must be '1' for the hds_threshold_valid field to be
+        * configured.
+        */
+       #define HWRM_VNIC_PLCMODES_CFG_INPUT_ENABLES_HDS_THRESHOLD_VALID \
+               UINT32_C(0x4)
+       uint32_t vnic_id;
+       /* Logical vnic ID */
+       uint16_t jumbo_thresh;
+       /*
+        * When jumbo placement algorithm is enabled, this value is used to
+        * determine the threshold for jumbo placement. Packets with length
+        * larger than this value will be placed according to the jumbo
+        * placement algorithm.
+        */
+       uint16_t hds_offset;
+       /*
+        * This value is used to determine the offset into packet buffer where
+        * the split data (payload) will be placed according to one of of HDS
+        * placement algorithm. The lengths of packet buffers provided for split
+        * data shall be larger than this value.
+        */
+       uint16_t hds_threshold;
+       /*
+        * When one of the HDS placement algorithm is enabled, this value is
+        * used to determine the threshold for HDS placement. Packets with
+        * length larger than this value will be placed according to the HDS
+        * placement algorithm. This value shall be in multiple of 4 bytes.
+        */
+       uint16_t unused_0[3];
+} __attribute__((packed));
+
+/* Output (16 bytes) */
+struct hwrm_vnic_plcmodes_cfg_output {
+       uint16_t error_code;
+       /*
+        * Pass/Fail or error type Note: receiver to verify the in parameters,
+        * and fail the call with an error when appropriate
+        */
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
+       /*
+        * This field is the length of the response in bytes. The last byte of
+        * the response is a valid flag that will read as '1' when the command
+        * has been completely written to memory.
+        */
+       uint32_t unused_0;
+       uint8_t unused_1;
+       uint8_t unused_2;
+       uint8_t unused_3;
+       uint8_t valid;
+       /*
+        * This field is used in Output records to indicate that the output is
+        * completely written to RAM. This field should be read as '1' to
+        * indicate that the output has been completely written. When writing a
+        * command completion or response to an internal processor, the order of
+        * writes has to be such that this field is written last.
+        */
+} __attribute__((packed));
+
+/* hwrm_vnic_plcmodes_qcfg */
+/*
+ * Description: This function can be used to query placement mode configuration
+ * of the VNIC.
+ */
+/* Input (24 bytes) */
+struct hwrm_vnic_plcmodes_qcfg_input {
+       uint16_t req_type;
+       /*
+        * This value indicates what type of request this is. The format for the
+        * rest of the command is determined by this field.
+        */
+       uint16_t cmpl_ring;
+       /*
+        * This value indicates the what completion ring the request will be
+        * optionally completed on. If the value is -1, then no CR completion
+        * will be generated. Any other value must be a valid CR ring_id value
+        * for this function.
+        */
+       uint16_t seq_id;
+       /* This value indicates the command sequence number. */
+       uint16_t target_id;
+       /*
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function ids
+        * 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF - HWRM
+        */
+       uint64_t resp_addr;
+       /*
+        * This is the host address where the response will be written when the
+        * request is complete. This area must be 16B aligned and must be
+        * cleared to zero before the request is made.
+        */
+       uint32_t vnic_id;
+       /* Logical vnic ID */
+       uint32_t unused_0;
+} __attribute__((packed));
+
+/* Output (24 bytes) */
+struct hwrm_vnic_plcmodes_qcfg_output {
+       uint16_t error_code;
+       /*
+        * Pass/Fail or error type Note: receiver to verify the in parameters,
+        * and fail the call with an error when appropriate
+        */
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
+       /*
+        * This field is the length of the response in bytes. The last byte of
+        * the response is a valid flag that will read as '1' when the command
+        * has been completely written to memory.
+        */
+       uint32_t flags;
+       /*
+        * When this bit is '1', the VNIC is configured to use regular placement
+        * algorithm.
+        */
+       #define HWRM_VNIC_PLCMODES_QCFG_OUTPUT_FLAGS_REGULAR_PLACEMENT \
+               UINT32_C(0x1)
+       /*
+        * When this bit is '1', the VNIC is configured to use the jumbo
+        * placement algorithm.
+        */
+       #define HWRM_VNIC_PLCMODES_QCFG_OUTPUT_FLAGS_JUMBO_PLACEMENT \
+               UINT32_C(0x2)
+       /*
+        * When this bit is '1', the VNIC is configured to enable Header-Data
+        * split for IPv4 packets.
+        */
+       #define HWRM_VNIC_PLCMODES_QCFG_OUTPUT_FLAGS_HDS_IPV4      UINT32_C(0x4)
+       /*
+        * When this bit is '1', the VNIC is configured to enable Header-Data
+        * split for IPv6 packets.
+        */
+       #define HWRM_VNIC_PLCMODES_QCFG_OUTPUT_FLAGS_HDS_IPV6      UINT32_C(0x8)
+       /*
+        * When this bit is '1', the VNIC is configured to enable Header-Data
+        * split for FCoE packets.
+        */
+       #define HWRM_VNIC_PLCMODES_QCFG_OUTPUT_FLAGS_HDS_FCOE     UINT32_C(0x10)
+       /*
+        * When this bit is '1', the VNIC is configured to enable Header-Data
+        * split for RoCE packets.
+        */
+       #define HWRM_VNIC_PLCMODES_QCFG_OUTPUT_FLAGS_HDS_ROCE     UINT32_C(0x20)
+       /*
+        * When this bit is '1', the VNIC is configured to be the default VNIC
+        * of the requesting function.
+        */
+       #define HWRM_VNIC_PLCMODES_QCFG_OUTPUT_FLAGS_DFLT_VNIC    UINT32_C(0x40)
+       uint16_t jumbo_thresh;
+       /*
+        * When jumbo placement algorithm is enabled, this value is used to
+        * determine the threshold for jumbo placement. Packets with length
+        * larger than this value will be placed according to the jumbo
+        * placement algorithm.
+        */
+       uint16_t hds_offset;
+       /*
+        * This value is used to determine the offset into packet buffer where
+        * the split data (payload) will be placed according to one of of HDS
+        * placement algorithm. The lengths of packet buffers provided for split
+        * data shall be larger than this value.
+        */
+       uint16_t hds_threshold;
+       /*
+        * When one of the HDS placement algorithm is enabled, this value is
+        * used to determine the threshold for HDS placement. Packets with
+        * length larger than this value will be placed according to the HDS
+        * placement algorithm. This value shall be in multiple of 4 bytes.
+        */
+       uint8_t unused_0;
+       uint8_t unused_1;
+       uint8_t unused_2;
+       uint8_t unused_3;
+       uint8_t unused_4;
+       uint8_t valid;
+       /*
+        * This field is used in Output records to indicate that the output is
+        * completely written to RAM. This field should be read as '1' to
+        * indicate that the output has been completely written. When writing a
+        * command completion or response to an internal processor, the order of
+        * writes has to be such that this field is written last.
+        */
+} __attribute__((packed));
+
+/* hwrm_vnic_rss_cos_lb_ctx_alloc */
+/* Description: This function is used to allocate COS/Load Balance context. */
+/* Input       (16 bytes) */
+struct hwrm_vnic_rss_cos_lb_ctx_alloc_input {
+       uint16_t req_type;
+       /*
+        * This value indicates what type of request this is. The format
+        * for the rest of the command is determined by this field.
+        */
+       uint16_t cmpl_ring;
+       /*
+        * This value indicates the what completion ring the request
+        * will be optionally completed on. If the value is -1, then no
+        * CR completion will be generated. Any other value must be a
+        * valid CR ring_id value for this function.
+        */
+       uint16_t seq_id;
+       /* This value indicates the command sequence number. */
+       uint16_t target_id;
+       /*
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function
+        * ids 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF
+        * - HWRM
+        */
+       uint64_t resp_addr;
+       /*
+        * This is the host address where the response will be written
+        * when the request is complete. This area must be 16B aligned
+        * and must be cleared to zero before the request is made.
+        */
+} __attribute__((packed));
+
+/* Output      (16 bytes) */
+struct hwrm_vnic_rss_cos_lb_ctx_alloc_output {
+       uint16_t error_code;
+       /*
+        * Pass/Fail or error type Note: receiver to verify the in
+        * parameters, and fail the call with an error when appropriate
+        */
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
+       /*
+        * This field is the length of the response in bytes. The last
+        * byte of the response is a valid flag that will read as '1'
+        * when the command has been completely written to memory.
+        */
+       uint16_t rss_cos_lb_ctx_id;
+       /* rss_cos_lb_ctx_id is 16 b */
+       uint8_t unused_0;
+       uint8_t unused_1;
+       uint8_t unused_2;
+       uint8_t unused_3;
+       uint8_t unused_4;
+       uint8_t valid;
+       /*
+        * This field is used in Output records to indicate that the
+        * output is completely written to RAM. This field should be
+        * read as '1' to indicate that the output has been completely
+        * written. When writing a command completion or response to an
+        * internal processor, the order of writes has to be such that
+        * this field is written last.
+        */
+} __attribute__((packed));
+
+/* hwrm_vnic_rss_cos_lb_ctx_free */
+/* Description: This function can be used to free COS/Load Balance context. */
+/* Input       (24 bytes) */
+struct hwrm_vnic_rss_cos_lb_ctx_free_input {
+       uint16_t req_type;
+       /*
+        * This value indicates what type of request this is. The format
+        * for the rest of the command is determined by this field.
+        */
+       uint16_t cmpl_ring;
        /*
-        * When this flag is set to '1', the VNIC is requested to be
-        * configured to receive only RoCE traffic. If this flag is set
-        * to '0', then this flag shall be ignored by the HWRM. If
-        * roce_dual_vnic_mode flag is set to '1', then the HWRM client
-        * shall not set this flag to '1'.
+        * This value indicates the what completion ring the request
+        * will be optionally completed on. If the value is -1, then no
+        * CR completion will be generated. Any other value must be a
+        * valid CR ring_id value for this function.
         */
-       #define HWRM_VNIC_CFG_INPUT_FLAGS_ROCE_ONLY_VNIC_MODE UINT32_C(0x10)
+       uint16_t seq_id;
+       /* This value indicates the command sequence number. */
+       uint16_t target_id;
        /*
-        * When a VNIC uses one destination ring group for certain
-        * application  (e.g. Receive Flow Steering) where exact match is
-        * used to direct packets to a VNIC with one destination ring
-        * group only, there is no need to configure RSS indirection
-        * table for that VNIC as only one destination ring group is
-        * used. This flag is used to enable a mode where RSS is enabled
-        * in the VNIC using a RSS context for computing RSS hash but
-        * the RSS indirection table is not configured using
-        * hwrm_vnic_rss_cfg. If this mode is enabled, then the driver
-        * should not program RSS indirection table for the RSS context
-        * that is used for computing RSS hash only.
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function
+        * ids 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF
+        * - HWRM
+        */
+       uint64_t resp_addr;
+       /*
+        * This is the host address where the response will be written
+        * when the request is complete. This area must be 16B aligned
+        * and must be cleared to zero before the request is made.
+        */
+       uint16_t rss_cos_lb_ctx_id;
+       /* rss_cos_lb_ctx_id is 16 b */
+       uint16_t unused_0[3];
+} __attribute__((packed));
+
+/* Output      (16 bytes) */
+struct hwrm_vnic_rss_cos_lb_ctx_free_output {
+       uint16_t error_code;
+       /*
+        * Pass/Fail or error type Note: receiver to verify the in
+        * parameters, and fail the call with an error when appropriate
+        */
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
+       /*
+        * This field is the length of the response in bytes. The last
+        * byte of the response is a valid flag that will read as '1'
+        * when the command has been completely written to memory.
+        */
+       uint32_t unused_0;
+       uint8_t unused_1;
+       uint8_t unused_2;
+       uint8_t unused_3;
+       uint8_t valid;
+       /*
+        * This field is used in Output records to indicate that the
+        * output is completely written to RAM. This field should be
+        * read as '1' to indicate that the output has been completely
+        * written. When writing a command completion or response to an
+        * internal processor, the order of writes has to be such that
+        * this field is written last.
+        */
+} __attribute__((packed));
+
+/* hwrm_ring_alloc */
+/*
+ * Description: This command allocates and does basic preparation for a ring.
+ */
+/* Input       (80 bytes) */
+struct hwrm_ring_alloc_input {
+       uint16_t req_type;
+       /*
+        * This value indicates what type of request this is. The format
+        * for the rest of the command is determined by this field.
+        */
+       uint16_t cmpl_ring;
+       /*
+        * This value indicates the what completion ring the request
+        * will be optionally completed on. If the value is -1, then no
+        * CR completion will be generated. Any other value must be a
+        * valid CR ring_id value for this function.
+        */
+       uint16_t seq_id;
+       /* This value indicates the command sequence number. */
+       uint16_t target_id;
+       /*
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function
+        * ids 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF
+        * - HWRM
+        */
+       uint64_t resp_addr;
+       /*
+        * This is the host address where the response will be written
+        * when the request is complete. This area must be 16B aligned
+        * and must be cleared to zero before the request is made.
         */
-       #define HWRM_VNIC_CFG_INPUT_FLAGS_RSS_DFLT_CR_MODE      UINT32_C(0x20)
        uint32_t enables;
+       /* This bit must be '1' for the Reserved1 field to be configured. */
+       #define HWRM_RING_ALLOC_INPUT_ENABLES_RESERVED1 UINT32_C(0x1)
+       /* This bit must be '1' for the ring_arb_cfg field to be configured. */
+       #define HWRM_RING_ALLOC_INPUT_ENABLES_RING_ARB_CFG      UINT32_C(0x2)
+       /* This bit must be '1' for the Reserved3 field to be configured. */
+       #define HWRM_RING_ALLOC_INPUT_ENABLES_RESERVED3 UINT32_C(0x4)
        /*
-        * This bit must be '1' for the dflt_ring_grp field to be
+        * This bit must be '1' for the stat_ctx_id_valid field to be
         * configured.
         */
-       #define HWRM_VNIC_CFG_INPUT_ENABLES_DFLT_RING_GRP       UINT32_C(0x1)
-       /* This bit must be '1' for the rss_rule field to be configured. */
-       #define HWRM_VNIC_CFG_INPUT_ENABLES_RSS_RULE    UINT32_C(0x2)
-       /* This bit must be '1' for the cos_rule field to be configured. */
-       #define HWRM_VNIC_CFG_INPUT_ENABLES_COS_RULE    UINT32_C(0x4)
-       /* This bit must be '1' for the lb_rule field to be configured. */
-       #define HWRM_VNIC_CFG_INPUT_ENABLES_LB_RULE     UINT32_C(0x8)
-       /* This bit must be '1' for the mru field to be configured. */
-       #define HWRM_VNIC_CFG_INPUT_ENABLES_MRU UINT32_C(0x10)
-       uint16_t vnic_id;
-       /* Logical vnic ID */
-       uint16_t dflt_ring_grp;
+       #define HWRM_RING_ALLOC_INPUT_ENABLES_STAT_CTX_ID_VALID UINT32_C(0x8)
+       /* This bit must be '1' for the Reserved4 field to be configured. */
+       #define HWRM_RING_ALLOC_INPUT_ENABLES_RESERVED4 UINT32_C(0x10)
+       /* This bit must be '1' for the max_bw_valid field to be configured. */
+       #define HWRM_RING_ALLOC_INPUT_ENABLES_MAX_BW_VALID      UINT32_C(0x20)
+       uint8_t ring_type;
+       /* Ring Type. */
+       /* L2 Completion Ring   (CR) */
+       #define HWRM_RING_ALLOC_INPUT_RING_TYPE_L2_CMPL UINT32_C(0x0)
+       /* TX Ring      (TR) */
+       #define HWRM_RING_ALLOC_INPUT_RING_TYPE_TX      UINT32_C(0x1)
+       /* RX Ring      (RR) */
+       #define HWRM_RING_ALLOC_INPUT_RING_TYPE_RX      UINT32_C(0x2)
+       /* RoCE Notification Completion Ring    (ROCE_CR) */
+       #define HWRM_RING_ALLOC_INPUT_RING_TYPE_ROCE_CMPL       UINT32_C(0x3)
+       uint8_t unused_0;
+       uint16_t unused_1;
+       uint64_t page_tbl_addr;
+       /* This value is a pointer to the page table for the Ring. */
+       uint32_t fbo;
+       /* First Byte Offset of the first entry in the first page. */
+       uint8_t page_size;
        /*
-        * Default Completion ring for the VNIC. This ring will be
-        * chosen if packet does not match any RSS rules and if there is
-        * no COS rule.
+        * Actual page size in 2^page_size. The supported range is
+        * increments in powers of 2 from 16 bytes to 1GB. - 4 = 16 B
+        * Page size is 16 B. - 12 = 4 KB Page size is 4 KB. - 13 = 8 KB
+        * Page size is 8 KB. - 16 = 64 KB Page size is 64 KB. - 21 = 2
+        * MB Page size is 2 MB. - 22 = 4 MB Page size is 4 MB. - 30 = 1
+        * GB Page size is 1 GB.
         */
-       uint16_t rss_rule;
+       uint8_t page_tbl_depth;
        /*
-        * RSS ID for RSS rule/table structure. 0xFF... (All Fs) if
-        * there is no RSS rule.
+        * This value indicates the depth of page table. For this
+        * version of the specification, value other than 0 or 1 shall
+        * be considered as an invalid value. When the page_tbl_depth =
+        * 0, then it is treated as a special case with the following.
+        * 1. FBO and page size fields are not valid. 2. page_tbl_addr
+        * is the physical address of the first element of the ring.
         */
-       uint16_t cos_rule;
+       uint8_t unused_2;
+       uint8_t unused_3;
+       uint32_t length;
        /*
-        * RSS ID for COS rule/table structure. 0xFF... (All Fs) if
-        * there is no COS rule.
+        * Number of 16B units in the ring. Minimum size for a ring is
+        * 16 16B entries.
+        */
+       uint16_t logical_id;
+       /*
+        * Logical ring number for the ring to be allocated. This value
+        * determines the position in the doorbell area where the update
+        * to the ring will be made. For completion rings, this value is
+        * also the MSI-X vector number for the function the completion
+        * ring is associated with.
+        */
+       uint16_t cmpl_ring_id;
+       /*
+        * This field is used only when ring_type is a TX ring. This
+        * value indicates what completion ring the TX ring is
+        * associated with.
+        */
+       uint16_t queue_id;
+       /*
+        * This field is used only when ring_type is a TX ring. This
+        * value indicates what CoS queue the TX ring is associated
+        * with.
+        */
+       uint8_t unused_4;
+       uint8_t unused_5;
+       uint32_t reserved1;
+       /* This field is reserved for the future use. It shall be set to 0. */
+       uint16_t ring_arb_cfg;
+       /*
+        * This field is used only when ring_type is a TX ring. This
+        * field is used to configure arbitration related parameters for
+        * a TX ring.
+        */
+       /* Arbitration policy used for the ring. */
+       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_ARB_POLICY_MASK UINT32_C(0xf)
+       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_ARB_POLICY_SFT       0
+       /*
+        * Use strict priority for the TX ring. Priority
+        * value is specified in arb_policy_param
+        */
+       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_ARB_POLICY_SP \
+               (UINT32_C(0x1) << 0)
+       /*
+        * Use weighted fair queue arbitration for the
+        * TX ring. Weight is specified in
+        * arb_policy_param
+        */
+       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_ARB_POLICY_WFQ \
+               (UINT32_C(0x2) << 0)
+       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_ARB_POLICY_LAST \
+               RING_ALLOC_INPUT_RING_ARB_CFG_ARB_POLICY_WFQ
+       /* Reserved field. */
+       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_RSVD_MASK    UINT32_C(0xf0)
+       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_RSVD_SFT     4
+       /*
+        * Arbitration policy specific parameter. # For strict priority
+        * arbitration policy, this field represents a priority value.
+        * If set to 0, then the priority is not specified and the HWRM
+        * is allowed to select any priority for this TX ring. # For
+        * weighted fair queue arbitration policy, this field represents
+        * a weight value. If set to 0, then the weight is not specified
+        * and the HWRM is allowed to select any weight for this TX
+        * ring.
+        */
+       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_ARB_POLICY_PARAM_MASK  \
+               UINT32_C(0xff00)
+       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_ARB_POLICY_PARAM_SFT 8
+       uint8_t unused_6;
+       uint8_t unused_7;
+       uint32_t reserved3;
+       /* This field is reserved for the future use. It shall be set to 0. */
+       uint32_t stat_ctx_id;
+       /*
+        * This field is used only when ring_type is a TX ring. This
+        * input indicates what statistics context this ring should be
+        * associated with.
         */
-       uint16_t lb_rule;
+       uint32_t reserved4;
+       /* This field is reserved for the future use. It shall be set to 0. */
+       uint32_t max_bw;
        /*
-        * RSS ID for load balancing rule/table structure. 0xFF...      (All
-        * Fs) if there is no LB rule.
+        * This field is used only when ring_type is a TX ring to
+        * specify maximum BW allocated to the TX ring. The HWRM will
+        * translate this value into byte counter and time interval used
+        * for this ring inside the device.
         */
-       uint16_t mru;
+       /* The bandwidth value. */
+       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_MASK UINT32_C(0xfffffff)
+       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_SFT       0
+       /* The granularity of the value (bits or bytes). */
+       #define HWRM_RING_ALLOC_INPUT_MAX_BW_SCALE      UINT32_C(0x10000000)
+       /* Value is in bits. */
+       #define HWRM_RING_ALLOC_INPUT_MAX_BW_SCALE_BITS (UINT32_C(0x0) << 28)
+       /* Value is in bytes. */
+       #define HWRM_RING_ALLOC_INPUT_MAX_BW_SCALE_BYTES (UINT32_C(0x1) << 28)
+       #define HWRM_RING_ALLOC_INPUT_MAX_BW_SCALE_LAST \
+               RING_ALLOC_INPUT_MAX_BW_SCALE_BYTES
+       /* bw_value_unit is 3 b */
+       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_MASK \
+               UINT32_C(0xe0000000)
+       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_SFT  29
+       /* Value is in Mb or MB (base 10). */
+       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_MEGA \
+               (UINT32_C(0x0) << 29)
+       /* Value is in Kb or KB (base 10). */
+       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_KILO \
+               (UINT32_C(0x2) << 29)
+       /* Value is in bits or bytes. */
+       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_BASE \
+               (UINT32_C(0x4) << 29)
+       /* Value is in Gb or GB (base 10). */
+       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_GIGA \
+               (UINT32_C(0x6) << 29)
+       /* Value is in 1/100th of a percentage of total bandwidth. */
+       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_PERCENT1_100 \
+               (UINT32_C(0x1) << 29)
+       /* Invalid unit */
+       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_INVALID \
+               (UINT32_C(0x7) << 29)
+       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_LAST \
+               RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_INVALID
+       uint8_t int_mode;
        /*
-        * The maximum receive unit of the vnic. Each vnic is associated
-        * with a function. The vnic mru value overwrites the mru
-        * setting of the associated function. The HWRM shall make sure
-        * that vnic mru does not exceed the mru of the port the
-        * function is associated with.
+        * This field is used only when ring_type is a Completion ring.
+        * This value indicates what interrupt mode should be used on
+        * this completion ring. Note: In the legacy interrupt mode, no
+        * more than 16 completion rings are allowed.
         */
-       uint32_t unused_0;
+       /* Legacy INTA */
+       #define HWRM_RING_ALLOC_INPUT_INT_MODE_LEGACY   UINT32_C(0x0)
+       /* Reserved */
+       #define HWRM_RING_ALLOC_INPUT_INT_MODE_RSVD     UINT32_C(0x1)
+       /* MSI-X */
+       #define HWRM_RING_ALLOC_INPUT_INT_MODE_MSIX     UINT32_C(0x2)
+       /* No Interrupt - Polled mode */
+       #define HWRM_RING_ALLOC_INPUT_INT_MODE_POLL     UINT32_C(0x3)
+       uint8_t unused_8[3];
 } __attribute__((packed));
 
 /* Output      (16 bytes) */
-struct hwrm_vnic_cfg_output {
+struct hwrm_ring_alloc_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -6390,10 +8537,16 @@ struct hwrm_vnic_cfg_output {
         * byte of the response is a valid flag that will read as '1'
         * when the command has been completely written to memory.
         */
-       uint32_t unused_0;
+       uint16_t ring_id;
+       /*
+        * Physical number of ring allocated. This value shall be unique
+        * for a ring type.
+        */
+       uint16_t logical_ring_id;
+       /* Logical number of ring allocated. */
+       uint8_t unused_0;
        uint8_t unused_1;
        uint8_t unused_2;
-       uint8_t unused_3;
        uint8_t valid;
        /*
         * This field is used in Output records to indicate that the
@@ -6405,14 +8558,20 @@ struct hwrm_vnic_cfg_output {
         */
 } __attribute__((packed));
 
-/* hwrm_vnic_qcfg */
+/* hwrm_ring_free */
 /*
- * Description: Query the RX VNIC structure. This function can be used by a PF
- * driver to query its own VNIC resource or VNIC resource of its child VF. This
- * function can also be used by a VF driver to query its own VNIC resource.
+ * Description: This command is used to free a ring and associated resources.
+ * With QoS and DCBx agents, it is possible the traffic classes will be moved
+ * from one CoS queue to another. When this occurs, the driver shall call
+ * 'hwrm_ring_free' to free the allocated rings and then call 'hwrm_ring_alloc'
+ * to re-allocate each ring and assign it to a new CoS queue. hwrm_ring_free
+ * shall be called on a ring only after it has been idle for 500ms or more and
+ * no frames have been posted to the ring during this time. All frames queued
+ * for transmission shall be completed and at least 500ms time elapsed from the
+ * last completion before calling this command.
  */
-/* Input       (32 bytes) */
-struct hwrm_vnic_qcfg_input {
+/* Input       (24 bytes) */
+struct hwrm_ring_free_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -6439,18 +8598,24 @@ struct hwrm_vnic_qcfg_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint32_t enables;
-       /* This bit must be '1' for the vf_id_valid field to be configured. */
-       #define HWRM_VNIC_QCFG_INPUT_ENABLES_VF_ID_VALID        UINT32_C(0x1)
-       uint32_t vnic_id;
-       /* Logical vnic ID */
-       uint16_t vf_id;
-       /* ID of Virtual Function whose VNIC resource is being queried. */
-       uint16_t unused_0[3];
+       uint8_t ring_type;
+       /* Ring Type. */
+       /* L2 Completion Ring   (CR) */
+       #define HWRM_RING_FREE_INPUT_RING_TYPE_L2_CMPL  UINT32_C(0x0)
+       /* TX Ring      (TR) */
+       #define HWRM_RING_FREE_INPUT_RING_TYPE_TX       UINT32_C(0x1)
+       /* RX Ring      (RR) */
+       #define HWRM_RING_FREE_INPUT_RING_TYPE_RX       UINT32_C(0x2)
+       /* RoCE Notification Completion Ring    (ROCE_CR) */
+       #define HWRM_RING_FREE_INPUT_RING_TYPE_ROCE_CMPL        UINT32_C(0x3)
+       uint8_t unused_0;
+       uint16_t ring_id;
+       /* Physical number of ring allocated. */
+       uint32_t unused_1;
 } __attribute__((packed));
 
-/* Output      (32 bytes) */
-struct hwrm_vnic_qcfg_output {
+/* Output      (16 bytes) */
+struct hwrm_ring_free_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -6466,78 +8631,96 @@ struct hwrm_vnic_qcfg_output {
         * byte of the response is a valid flag that will read as '1'
         * when the command has been completely written to memory.
         */
-       uint16_t dflt_ring_grp;
-       /* Default Completion ring for the VNIC. */
-       uint16_t rss_rule;
+       uint32_t unused_0;
+       uint8_t unused_1;
+       uint8_t unused_2;
+       uint8_t unused_3;
+       uint8_t valid;
        /*
-        * RSS ID for RSS rule/table structure. 0xFF... (All Fs) if
-        * there is no RSS rule.
+        * This field is used in Output records to indicate that the
+        * output is completely written to RAM. This field should be
+        * read as '1' to indicate that the output has been completely
+        * written. When writing a command completion or response to an
+        * internal processor, the order of writes has to be such that
+        * this field is written last.
         */
-       uint16_t cos_rule;
+} __attribute__((packed));
+
+/* hwrm_ring_grp_alloc */
+/*
+ * Description: This API allocates and does basic preparation for a ring group.
+ */
+/* Input       (24 bytes) */
+struct hwrm_ring_grp_alloc_input {
+       uint16_t req_type;
        /*
-        * RSS ID for COS rule/table structure. 0xFF... (All Fs) if
-        * there is no COS rule.
+        * This value indicates what type of request this is. The format
+        * for the rest of the command is determined by this field.
         */
-       uint16_t lb_rule;
+       uint16_t cmpl_ring;
        /*
-        * RSS ID for load balancing rule/table structure. 0xFF...      (All
-        * Fs) if there is no LB rule.
+        * This value indicates the what completion ring the request
+        * will be optionally completed on. If the value is -1, then no
+        * CR completion will be generated. Any other value must be a
+        * valid CR ring_id value for this function.
         */
-       uint16_t mru;
-       /* The maximum receive unit of the vnic. */
-       uint8_t unused_0;
-       uint8_t unused_1;
-       uint32_t flags;
+       uint16_t seq_id;
+       /* This value indicates the command sequence number. */
+       uint16_t target_id;
        /*
-        * When this bit is '1', the VNIC is the default VNIC for the
-        * function.
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function
+        * ids 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF
+        * - HWRM
         */
-       #define HWRM_VNIC_QCFG_OUTPUT_FLAGS_DEFAULT     UINT32_C(0x1)
+       uint64_t resp_addr;
        /*
-        * When this bit is '1', the VNIC is configured to strip VLAN in
-        * the RX path. If set to '0', then VLAN stripping is disabled
-        * on this VNIC.
+        * This is the host address where the response will be written
+        * when the request is complete. This area must be 16B aligned
+        * and must be cleared to zero before the request is made.
         */
-       #define HWRM_VNIC_QCFG_OUTPUT_FLAGS_VLAN_STRIP_MODE     UINT32_C(0x2)
+       uint16_t cr;
+       /* This value identifies the CR associated with the ring group. */
+       uint16_t rr;
+       /* This value identifies the main RR associated with the ring group. */
+       uint16_t ar;
        /*
-        * When this bit is '1', the VNIC is configured to buffer
-        * receive packets in the hardware until the host posts new
-        * receive buffers. If set to '0', then bd_stall is disabled on
-        * this VNIC.
+        * This value identifies the aggregation RR associated with the
+        * ring group. If this value is 0xFF... (All Fs), then no
+        * Aggregation ring will be set.
         */
-       #define HWRM_VNIC_QCFG_OUTPUT_FLAGS_BD_STALL_MODE       UINT32_C(0x4)
+       uint16_t sc;
        /*
-        * When this bit is '1', the VNIC is configured to receive both
-        * RoCE and non-RoCE traffic. If set to '0', then this VNIC is
-        * not configured to operate in dual VNIC mode.
+        * This value identifies the statistics context associated with
+        * the ring group.
         */
-       #define HWRM_VNIC_QCFG_OUTPUT_FLAGS_ROCE_DUAL_VNIC_MODE UINT32_C(0x8)
+} __attribute__((packed));
+
+/* Output      (16 bytes) */
+struct hwrm_ring_grp_alloc_output {
+       uint16_t error_code;
        /*
-        * When this flag is set to '1', the VNIC is configured to
-        * receive only RoCE traffic. When this flag is set to '0', the
-        * VNIC is not configured to receive only RoCE traffic. If
-        * roce_dual_vnic_mode flag and this flag both are set to '1',
-        * then it is an invalid configuration of the VNIC. The HWRM
-        * should not allow that type of mis-configuration by HWRM
-        * clients.
+        * Pass/Fail or error type Note: receiver to verify the in
+        * parameters, and fail the call with an error when appropriate
         */
-       #define HWRM_VNIC_QCFG_OUTPUT_FLAGS_ROCE_ONLY_VNIC_MODE UINT32_C(0x10)
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
        /*
-        * When a VNIC uses one destination ring group for certain
-        * application  (e.g. Receive Flow Steering) where exact match is
-        * used to direct packets to a VNIC with one destination ring
-        * group only, there is no need to configure RSS indirection
-        * table for that VNIC as only one destination ring group is
-        * used. When this bit is set to '1', then the VNIC is enabled
-        * in a mode where RSS is enabled in the VNIC using a RSS
-        * context for computing RSS hash but the RSS indirection table
-        * is not configured.
+        * This field is the length of the response in bytes. The last
+        * byte of the response is a valid flag that will read as '1'
+        * when the command has been completely written to memory.
         */
-       #define HWRM_VNIC_QCFG_OUTPUT_FLAGS_RSS_DFLT_CR_MODE    UINT32_C(0x20)
-       uint32_t unused_2;
-       uint8_t unused_3;
-       uint8_t unused_4;
-       uint8_t unused_5;
+       uint32_t ring_group_id;
+       /*
+        * This is the ring group ID value. Use this value to program
+        * the default ring group for the VNIC or as table entries in an
+        * RSS/COS context.
+        */
+       uint8_t unused_0;
+       uint8_t unused_1;
+       uint8_t unused_2;
        uint8_t valid;
        /*
         * This field is used in Output records to indicate that the
@@ -6549,10 +8732,17 @@ struct hwrm_vnic_qcfg_output {
         */
 } __attribute__((packed));
 
-/* hwrm_vnic_rss_cfg */
-/* Description: This function is used to enable RSS configuration. */
-/* Input       (48 bytes) */
-struct hwrm_vnic_rss_cfg_input {
+/* hwrm_ring_grp_free */
+/*
+ * Description: This API frees a ring group and associated resources. # If a
+ * ring in the ring group is reset or free, then the associated rings in the
+ * ring group shall also be reset/free using hwrm_ring_free. # A function driver
+ * shall always use hwrm_ring_grp_free after freeing all rings in a group. # As
+ * a part of executing this command, the HWRM shall reset all associated ring
+ * group resources.
+ */
+/* Input       (24 bytes) */
+struct hwrm_ring_grp_free_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -6579,53 +8769,13 @@ struct hwrm_vnic_rss_cfg_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint32_t hash_type;
-       /*
-        * When this bit is '1', the RSS hash shall be computed over
-        * source and destination IPv4 addresses of IPv4 packets.
-        */
-       #define HWRM_VNIC_RSS_CFG_INPUT_HASH_TYPE_IPV4  UINT32_C(0x1)
-       /*
-        * When this bit is '1', the RSS hash shall be computed over
-        * source/destination IPv4 addresses and source/destination
-        * ports of TCP/IPv4 packets.
-        */
-       #define HWRM_VNIC_RSS_CFG_INPUT_HASH_TYPE_TCP_IPV4      UINT32_C(0x2)
-       /*
-        * When this bit is '1', the RSS hash shall be computed over
-        * source/destination IPv4 addresses and source/destination
-        * ports of UDP/IPv4 packets.
-        */
-       #define HWRM_VNIC_RSS_CFG_INPUT_HASH_TYPE_UDP_IPV4      UINT32_C(0x4)
-       /*
-        * When this bit is '1', the RSS hash shall be computed over
-        * source and destination IPv4 addresses of IPv6 packets.
-        */
-       #define HWRM_VNIC_RSS_CFG_INPUT_HASH_TYPE_IPV6  UINT32_C(0x8)
-       /*
-        * When this bit is '1', the RSS hash shall be computed over
-        * source/destination IPv6 addresses and source/destination
-        * ports of TCP/IPv6 packets.
-        */
-       #define HWRM_VNIC_RSS_CFG_INPUT_HASH_TYPE_TCP_IPV6      UINT32_C(0x10)
-       /*
-        * When this bit is '1', the RSS hash shall be computed over
-        * source/destination IPv6 addresses and source/destination
-        * ports of UDP/IPv6 packets.
-        */
-       #define HWRM_VNIC_RSS_CFG_INPUT_HASH_TYPE_UDP_IPV6      UINT32_C(0x20)
+       uint32_t ring_group_id;
+       /* This is the ring group ID value. */
        uint32_t unused_0;
-       uint64_t ring_grp_tbl_addr;
-       /* This is the address for rss ring group table */
-       uint64_t hash_key_tbl_addr;
-       /* This is the address for rss hash key table */
-       uint16_t rss_ctx_idx;
-       /* Index to the rss indirection table. */
-       uint16_t unused_1[3];
 } __attribute__((packed));
 
 /* Output      (16 bytes) */
-struct hwrm_vnic_rss_cfg_output {
+struct hwrm_ring_grp_free_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -6656,296 +8806,396 @@ struct hwrm_vnic_rss_cfg_output {
         */
 } __attribute__((packed));
 
-/* hwrm_vnic_plcmodes_cfg */
+/* hwrm_cfa_l2_filter_alloc */
 /*
- * Description: This function can be used to set placement mode configuration of
- * the VNIC.
+ * Description: An L2 filter is a filter resource that is used to identify a
+ * vnic or ring for a packet based on layer 2 fields. Layer 2 fields for
+ * encapsulated packets include both outer L2 header and/or inner l2 header of
+ * encapsulated packet. The L2 filter resource covers the following OS specific
+ * L2 filters. Linux/FreeBSD (per function): # Broadcast enable/disable # List
+ * of individual multicast filters # All multicast enable/disable filter #
+ * Unicast filters # Promiscuous mode VMware: # Broadcast enable/disable (per
+ * physical function) # All multicast enable/disable   (per function) # Unicast
+ * filters per ring or vnic # Promiscuous mode per PF Windows: # Broadcast
+ * enable/disable (per physical function) # List of individual multicast filters
+ * (Driver needs to advertise the maximum number of filters supported) # All
+ * multicast enable/disable per physical function # Unicast filters per vnic #
+ * Promiscuous mode per PF Implementation notes on the use of VNIC in this
+ * command: # By default, these filters belong to default vnic for the function.
+ * # Once these filters are set up, only destination VNIC can be modified. # If
+ * the destination VNIC is not specified in this command, then the HWRM shall
+ * only create an l2 context id. HWRM Implementation notes for multicast
+ * filters: # The hwrm_filter_alloc command can be used to set up multicast
+ * filters (perfect match or partial match). Each individual function driver can
+ * set up multicast filters independently. # The HWRM needs to keep track of
+ * multicast filters set up by function drivers and maintain multicast group
+ * replication records to enable a subset of functions to receive traffic for a
+ * specific multicast address. # When a specific multicast filter cannot be set,
+ * the HWRM shall return an error. In this error case, the driver should fall
+ * back to using one general filter    (rather than specific) for all multicast
+ * traffic. # When the SR-IOV is enabled, the HWRM needs to additionally track
+ * source knockout per multicast group record. Examples of setting unicast
+ * filters: For a unicast MAC based filter, one can use a combination of the
+ * fields and masks provided in this command to set up the filter. Below are
+ * some examples: # MAC + no VLAN filter: This filter is used to identify
+ * traffic that does not contain any VLAN tags and matches destination (or
+ * source) MAC address. This filter can be set up by setting only l2_addr field
+ * to be a valid field. All other fields are not valid. The following value is
+ * set for l2_addr. l2_addr = MAC # MAC + Any VLAN filter: This filter is used
+ * to identify traffic that carries single VLAN tag and matches        (destination or
+ * source) MAC address. This filter can be set up by setting only l2_addr and
+ * l2_ovlan_mask fields to be valid fields. All other fields are not valid. The
+ * following values are set for those two valid fields. l2_addr = MAC,
+ * l2_ovlan_mask = 0xFFFF # MAC + no VLAN or VLAN ID=0: This filter is used to
+ * identify untagged traffic that does not contain any VLAN tags or a VLAN tag
+ * with VLAN ID = 0 and matches destination (or source) MAC address. This filter
+ * can be set up by setting only l2_addr and l2_ovlan fields to be valid fields.
+ * All other fields are not valid. The following value are set for l2_addr and
+ * l2_ovlan. l2_addr = MAC, l2_ovlan = 0x0 # MAC + no VLAN or any VLAN: This
+ * filter is used to identify traffic that contains zero or 1 VLAN tag and
+ * matches destination (or source) MAC address. This filter can be set up by
+ * setting only l2_addr, l2_ovlan, and l2_mask fields to be valid fields. All
+ * other fields are not valid. The following value are set for l2_addr,
+ * l2_ovlan, and l2_mask fields. l2_addr = MAC, l2_ovlan = 0x0, l2_ovlan_mask =
+ * 0xFFFF # MAC + VLAN ID filter: This filter can be set up by setting only
+ * l2_addr, l2_ovlan, and l2_ovlan_mask fields to be valid fields. All other
+ * fields are not valid. The following values are set for those three valid
+ * fields. l2_addr = MAC, l2_ovlan = VLAN ID, l2_ovlan_mask = 0xF000
  */
-/* Input (40 bytes) */
-
-struct hwrm_vnic_plcmodes_cfg_input {
+/* Input       (96 bytes) */
+struct hwrm_cfa_l2_filter_alloc_input {
        uint16_t req_type;
        /*
-        * This value indicates what type of request this is. The format for the
-        * rest of the command is determined by this field.
+        * This value indicates what type of request this is. The format
+        * for the rest of the command is determined by this field.
         */
        uint16_t cmpl_ring;
        /*
-        * This value indicates the what completion ring the request will be
-        * optionally completed on. If the value is -1, then no CR completion
-        * will be generated. Any other value must be a valid CR ring_id value
-        * for this function.
+        * This value indicates the what completion ring the request
+        * will be optionally completed on. If the value is -1, then no
+        * CR completion will be generated. Any other value must be a
+        * valid CR ring_id value for this function.
         */
        uint16_t seq_id;
        /* This value indicates the command sequence number. */
        uint16_t target_id;
        /*
-        * Target ID of this command. 0x0 - 0xFFF8 - Used for function ids
-        * 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF - HWRM
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function
+        * ids 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF
+        * - HWRM
         */
        uint64_t resp_addr;
        /*
-        * This is the host address where the response will be written when the
-        * request is complete. This area must be 16B aligned and must be
-        * cleared to zero before the request is made.
+        * This is the host address where the response will be written
+        * when the request is complete. This area must be 16B aligned
+        * and must be cleared to zero before the request is made.
         */
        uint32_t flags;
        /*
-        * When this bit is '1', the VNIC shall be configured to use regular
-        * placement algorithm. By default, the regular placement algorithm
-        * shall be enabled on the VNIC.
+        * Enumeration denoting the RX, TX type of the resource. This
+        * enumeration is used for resources that are similar for both
+        * TX and RX paths of the chip.
         */
-       #define HWRM_VNIC_PLCMODES_CFG_INPUT_FLAGS_REGULAR_PLACEMENT \
-               UINT32_C(0x1)
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_PATH       UINT32_C(0x1)
+       /* tx path */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_PATH_TX    \
+               (UINT32_C(0x0) << 0)
+       /* rx path */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_PATH_RX    \
+               (UINT32_C(0x1) << 0)
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_PATH_LAST \
+               CFA_L2_FILTER_ALLOC_INPUT_FLAGS_PATH_RX
        /*
-        * When this bit is '1', the VNIC shall be configured use the jumbo
-        * placement algorithm.
+        * Setting of this flag indicates the applicability to the
+        * loopback path.
         */
-       #define HWRM_VNIC_PLCMODES_CFG_INPUT_FLAGS_JUMBO_PLACEMENT \
-               UINT32_C(0x2)
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_LOOPBACK   UINT32_C(0x2)
        /*
-        * When this bit is '1', the VNIC shall be configured to enable Header-
-        * Data split for IPv4 packets according to the following rules: # If
-        * the packet is identified as TCP/IPv4, then the packet is split at the
-        * beginning of the TCP payload. # If the packet is identified as
-        * UDP/IPv4, then the packet is split at the beginning of UDP payload. #
-        * If the packet is identified as non-TCP and non-UDP IPv4 packet, then
-        * the packet is split at the beginning of the upper layer protocol
-        * header carried in the IPv4 packet.
+        * Setting of this flag indicates drop action. If this flag is
+        * not set, then it should be considered accept action.
         */
-       #define HWRM_VNIC_PLCMODES_CFG_INPUT_FLAGS_HDS_IPV4        UINT32_C(0x4)
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_DROP       UINT32_C(0x4)
        /*
-        * When this bit is '1', the VNIC shall be configured to enable Header-
-        * Data split for IPv6 packets according to the following rules: # If
-        * the packet is identified as TCP/IPv6, then the packet is split at the
-        * beginning of the TCP payload. # If the packet is identified as
-        * UDP/IPv6, then the packet is split at the beginning of UDP payload. #
-        * If the packet is identified as non-TCP and non-UDP IPv6 packet, then
-        * the packet is split at the beginning of the upper layer protocol
-        * header carried in the IPv6 packet.
+        * If this flag is set, all t_l2_* fields are invalid and they
+        * should not be specified. If this flag is set, then l2_*
+        * fields refer to fields of outermost L2 header.
         */
-       #define HWRM_VNIC_PLCMODES_CFG_INPUT_FLAGS_HDS_IPV6        UINT32_C(0x8)
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_OUTERMOST UINT32_C(0x8)
+       uint32_t enables;
+       /* This bit must be '1' for the l2_addr field to be configured. */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_L2_ADDR UINT32_C(0x1)
+       /* This bit must be '1' for the l2_addr_mask field to be configured. */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_L2_ADDR_MASK     \
+               UINT32_C(0x2)
+       /* This bit must be '1' for the l2_ovlan field to be configured. */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_L2_OVLAN UINT32_C(0x4)
        /*
-        * When this bit is '1', the VNIC shall be configured to enable Header-
-        * Data split for FCoE packets at the beginning of FC payload.
+        * This bit must be '1' for the l2_ovlan_mask field to be
+        * configured.
         */
-       #define HWRM_VNIC_PLCMODES_CFG_INPUT_FLAGS_HDS_FCOE       UINT32_C(0x10)
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_L2_OVLAN_MASK     \
+               UINT32_C(0x8)
+       /* This bit must be '1' for the l2_ivlan field to be configured. */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_L2_IVLAN UINT32_C(0x10)
        /*
-        * When this bit is '1', the VNIC shall be configured to enable Header-
-        * Data split for RoCE packets at the beginning of RoCE payload (after
-        * BTH/GRH headers).
+        * This bit must be '1' for the l2_ivlan_mask field to be
+        * configured.
         */
-       #define HWRM_VNIC_PLCMODES_CFG_INPUT_FLAGS_HDS_ROCE       UINT32_C(0x20)
-       uint32_t enables;
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_L2_IVLAN_MASK     \
+               UINT32_C(0x20)
+       /* This bit must be '1' for the t_l2_addr field to be configured. */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_T_L2_ADDR UINT32_C(0x40)
        /*
-        * This bit must be '1' for the jumbo_thresh_valid field to be
+        * This bit must be '1' for the t_l2_addr_mask field to be
         * configured.
         */
-       #define HWRM_VNIC_PLCMODES_CFG_INPUT_ENABLES_JUMBO_THRESH_VALID \
-               UINT32_C(0x1)
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_T_L2_ADDR_MASK   \
+               UINT32_C(0x80)
+       /* This bit must be '1' for the t_l2_ovlan field to be configured. */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_T_L2_OVLAN       \
+               UINT32_C(0x100)
        /*
-        * This bit must be '1' for the hds_offset_valid field to be configured.
+        * This bit must be '1' for the t_l2_ovlan_mask field to be
+        * configured.
         */
-       #define HWRM_VNIC_PLCMODES_CFG_INPUT_ENABLES_HDS_OFFSET_VALID \
-               UINT32_C(0x2)
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_T_L2_OVLAN_MASK  \
+               UINT32_C(0x200)
+       /* This bit must be '1' for the t_l2_ivlan field to be configured. */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_T_L2_IVLAN       \
+               UINT32_C(0x400)
        /*
-        * This bit must be '1' for the hds_threshold_valid field to be
+        * This bit must be '1' for the t_l2_ivlan_mask field to be
         * configured.
         */
-       #define HWRM_VNIC_PLCMODES_CFG_INPUT_ENABLES_HDS_THRESHOLD_VALID \
-               UINT32_C(0x4)
-       uint32_t vnic_id;
-       /* Logical vnic ID */
-       uint16_t jumbo_thresh;
-       /*
-        * When jumbo placement algorithm is enabled, this value is used to
-        * determine the threshold for jumbo placement. Packets with length
-        * larger than this value will be placed according to the jumbo
-        * placement algorithm.
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_T_L2_IVLAN_MASK  \
+               UINT32_C(0x800)
+       /* This bit must be '1' for the src_type field to be configured. */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_SRC_TYPE UINT32_C(0x1000)
+       /* This bit must be '1' for the src_id field to be configured. */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_SRC_ID UINT32_C(0x2000)
+       /* This bit must be '1' for the tunnel_type field to be configured. */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_TUNNEL_TYPE      \
+               UINT32_C(0x4000)
+       /* This bit must be '1' for the dst_id field to be configured. */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_DST_ID UINT32_C(0x8000)
+       /*
+        * This bit must be '1' for the mirror_vnic_id field to be
+        * configured.
         */
-       uint16_t hds_offset;
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_MIRROR_VNIC_ID   \
+               UINT32_C(0x10000)
+       uint8_t l2_addr[6];
        /*
-        * This value is used to determine the offset into packet buffer where
-        * the split data (payload) will be placed according to one of of HDS
-        * placement algorithm. The lengths of packet buffers provided for split
-        * data shall be larger than this value.
+        * This value sets the match value for the L2 MAC address.
+        * Destination MAC address for RX path. Source MAC address for
+        * TX path.
         */
-       uint16_t hds_threshold;
+       uint8_t unused_0;
+       uint8_t unused_1;
+       uint8_t l2_addr_mask[6];
        /*
-        * When one of the HDS placement algorithm is enabled, this value is
-        * used to determine the threshold for HDS placement. Packets with
-        * length larger than this value will be placed according to the HDS
-        * placement algorithm. This value shall be in multiple of 4 bytes.
+        * This value sets the mask value for the L2 address. A value of
+        * 0 will mask the corresponding bit from compare.
         */
-       uint16_t unused_0[3];
-} __attribute__((packed));
-
-/* Output (16 bytes) */
-
-struct hwrm_vnic_plcmodes_cfg_output {
-       uint16_t error_code;
+       uint16_t l2_ovlan;
+       /* This value sets VLAN ID value for outer VLAN. */
+       uint16_t l2_ovlan_mask;
        /*
-        * Pass/Fail or error type Note: receiver to verify the in parameters,
-        * and fail the call with an error when appropriate
+        * This value sets the mask value for the ovlan id. A value of 0
+        * will mask the corresponding bit from compare.
         */
-       uint16_t req_type;
-       /* This field returns the type of original request. */
-       uint16_t seq_id;
-       /* This field provides original sequence number of the command. */
-       uint16_t resp_len;
+       uint16_t l2_ivlan;
+       /* This value sets VLAN ID value for inner VLAN. */
+       uint16_t l2_ivlan_mask;
        /*
-        * This field is the length of the response in bytes. The last byte of
-        * the response is a valid flag that will read as '1' when the command
-        * has been completely written to memory.
+        * This value sets the mask value for the ivlan id. A value of 0
+        * will mask the corresponding bit from compare.
         */
-       uint32_t unused_0;
-       uint8_t unused_1;
        uint8_t unused_2;
        uint8_t unused_3;
-       uint8_t valid;
-       /*
-        * This field is used in Output records to indicate that the output is
-        * completely written to RAM. This field should be read as '1' to
-        * indicate that the output has been completely written. When writing a
-        * command completion or response to an internal processor, the order of
-        * writes has to be such that this field is written last.
-        */
-} __attribute__((packed));
-
-/* hwrm_vnic_plcmodes_qcfg */
-/*
- * Description: This function can be used to query placement mode configuration
- * of the VNIC.
- */
-/* Input (24 bytes) */
-
-struct hwrm_vnic_plcmodes_qcfg_input {
-       uint16_t req_type;
+       uint8_t t_l2_addr[6];
        /*
-        * This value indicates what type of request this is. The format for the
-        * rest of the command is determined by this field.
+        * This value sets the match value for the tunnel L2 MAC
+        * address. Destination MAC address for RX path. Source MAC
+        * address for TX path.
         */
-       uint16_t cmpl_ring;
+       uint8_t unused_4;
+       uint8_t unused_5;
+       uint8_t t_l2_addr_mask[6];
        /*
-        * This value indicates the what completion ring the request will be
-        * optionally completed on. If the value is -1, then no CR completion
-        * will be generated. Any other value must be a valid CR ring_id value
-        * for this function.
+        * This value sets the mask value for the tunnel L2 address. A
+        * value of 0 will mask the corresponding bit from compare.
         */
-       uint16_t seq_id;
-       /* This value indicates the command sequence number. */
-       uint16_t target_id;
+       uint16_t t_l2_ovlan;
+       /* This value sets VLAN ID value for tunnel outer VLAN. */
+       uint16_t t_l2_ovlan_mask;
        /*
-        * Target ID of this command. 0x0 - 0xFFF8 - Used for function ids
-        * 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF - HWRM
+        * This value sets the mask value for the tunnel ovlan id. A
+        * value of 0 will mask the corresponding bit from compare.
         */
-       uint64_t resp_addr;
+       uint16_t t_l2_ivlan;
+       /* This value sets VLAN ID value for tunnel inner VLAN. */
+       uint16_t t_l2_ivlan_mask;
        /*
-        * This is the host address where the response will be written when the
-        * request is complete. This area must be 16B aligned and must be
-        * cleared to zero before the request is made.
+        * This value sets the mask value for the tunnel ivlan id. A
+        * value of 0 will mask the corresponding bit from compare.
         */
-       uint32_t vnic_id;
-       /* Logical vnic ID */
-       uint32_t unused_0;
-} __attribute__((packed));
-
-/* Output (24 bytes) */
-
-struct hwrm_vnic_plcmodes_qcfg_output {
-       uint16_t error_code;
+       uint8_t src_type;
+       /* This value identifies the type of source of the packet. */
+       /* Network port */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_SRC_TYPE_NPORT   UINT32_C(0x0)
+       /* Physical function */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_SRC_TYPE_PF      UINT32_C(0x1)
+       /* Virtual function */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_SRC_TYPE_VF      UINT32_C(0x2)
+       /* Virtual NIC of a function */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_SRC_TYPE_VNIC    UINT32_C(0x3)
+       /* Embedded processor for CFA management */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_SRC_TYPE_KONG    UINT32_C(0x4)
+       /* Embedded processor for OOB management */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_SRC_TYPE_APE     UINT32_C(0x5)
+       /* Embedded processor for RoCE */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_SRC_TYPE_BONO    UINT32_C(0x6)
+       /* Embedded processor for network proxy functions */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_SRC_TYPE_TANG    UINT32_C(0x7)
+       uint8_t unused_6;
+       uint32_t src_id;
        /*
-        * Pass/Fail or error type Note: receiver to verify the in parameters,
-        * and fail the call with an error when appropriate
+        * This value is the id of the source. For a network port, it
+        * represents port_id. For a physical function, it represents
+        * fid. For a virtual function, it represents vf_id. For a vnic,
+        * it represents vnic_id. For embedded processors, this id is
+        * not valid. Notes: 1. The function ID is implied if it src_id
+        * is not provided for a src_type that is either
         */
-       uint16_t req_type;
-       /* This field returns the type of original request. */
-       uint16_t seq_id;
-       /* This field provides original sequence number of the command. */
-       uint16_t resp_len;
+       uint8_t tunnel_type;
+       /* Tunnel Type. */
+       /* Non-tunnel */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_NONTUNNEL \
+               UINT32_C(0x0)
+       /* Virtual eXtensible Local Area Network        (VXLAN) */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_VXLAN \
+               UINT32_C(0x1)
        /*
-        * This field is the length of the response in bytes. The last byte of
-        * the response is a valid flag that will read as '1' when the command
-        * has been completely written to memory.
+        * Network Virtualization Generic Routing
+        * Encapsulation        (NVGRE)
         */
-       uint32_t flags;
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_NVGRE \
+               UINT32_C(0x2)
        /*
-        * When this bit is '1', the VNIC is configured to use regular placement
-        * algorithm.
+        * Generic Routing Encapsulation        (GRE) inside
+        * Ethernet payload
         */
-       #define HWRM_VNIC_PLCMODES_QCFG_OUTPUT_FLAGS_REGULAR_PLACEMENT \
-               UINT32_C(0x1)
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_L2GRE UINT32_C(0x3)
+       /* IP in IP */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_IPIP UINT32_C(0x4)
+       /* Generic Network Virtualization Encapsulation (Geneve) */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_GENEVE UINT32_C(0x5)
+       /* Multi-Protocol Lable Switching       (MPLS) */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_MPLS UINT32_C(0x6)
+       /* Stateless Transport Tunnel   (STT) */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_STT  UINT32_C(0x7)
        /*
-        * When this bit is '1', the VNIC is configured to use the jumbo
-        * placement algorithm.
+        * Generic Routing Encapsulation        (GRE) inside IP
+        * datagram payload
         */
-       #define HWRM_VNIC_PLCMODES_QCFG_OUTPUT_FLAGS_JUMBO_PLACEMENT \
-               UINT32_C(0x2)
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_IPGRE UINT32_C(0x8)
        /*
-        * When this bit is '1', the VNIC is configured to enable Header-Data
-        * split for IPv4 packets.
+        * IPV4 over virtual eXtensible Local Area
+        * Network (IPV4oVXLAN)
         */
-       #define HWRM_VNIC_PLCMODES_QCFG_OUTPUT_FLAGS_HDS_IPV4      UINT32_C(0x4)
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_VXLAN_V4 \
+               UINT32_C(0x9)
+       /* Any tunneled traffic */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_ANYTUNNEL \
+               UINT32_C(0xff)
+       uint8_t unused_7;
+       uint16_t dst_id;
        /*
-        * When this bit is '1', the VNIC is configured to enable Header-Data
-        * split for IPv6 packets.
+        * If set, this value shall represent the Logical VNIC ID of the
+        * destination VNIC for the RX path and network port id of the
+        * destination port for the TX path.
         */
-       #define HWRM_VNIC_PLCMODES_QCFG_OUTPUT_FLAGS_HDS_IPV6      UINT32_C(0x8)
+       uint16_t mirror_vnic_id;
+       /* Logical VNIC ID of the VNIC where traffic is mirrored. */
+       uint8_t pri_hint;
        /*
-        * When this bit is '1', the VNIC is configured to enable Header-Data
-        * split for FCoE packets.
+        * This hint is provided to help in placing the filter in the
+        * filter table.
         */
-       #define HWRM_VNIC_PLCMODES_QCFG_OUTPUT_FLAGS_HDS_FCOE     UINT32_C(0x10)
+       /* No preference */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_PRI_HINT_NO_PREFER \
+               UINT32_C(0x0)
+       /* Above the given filter */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_PRI_HINT_ABOVE_FILTER \
+               UINT32_C(0x1)
+       /* Below the given filter */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_PRI_HINT_BELOW_FILTER \
+               UINT32_C(0x2)
+       /* As high as possible */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_PRI_HINT_MAX     UINT32_C(0x3)
+       /* As low as possible */
+       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_PRI_HINT_MIN     UINT32_C(0x4)
+       uint8_t unused_8;
+       uint32_t unused_9;
+       uint64_t l2_filter_id_hint;
        /*
-        * When this bit is '1', the VNIC is configured to enable Header-Data
-        * split for RoCE packets.
+        * This is the ID of the filter that goes along with the
+        * pri_hint. This field is valid only for the following values.
+        * 1 - Above the given filter 2 - Below the given filter
         */
-       #define HWRM_VNIC_PLCMODES_QCFG_OUTPUT_FLAGS_HDS_ROCE     UINT32_C(0x20)
+} __attribute__((packed));
+
+/* Output      (24 bytes) */
+struct hwrm_cfa_l2_filter_alloc_output {
+       uint16_t error_code;
        /*
-        * When this bit is '1', the VNIC is configured to be the default VNIC
-        * of the requesting function.
+        * Pass/Fail or error type Note: receiver to verify the in
+        * parameters, and fail the call with an error when appropriate
         */
-       #define HWRM_VNIC_PLCMODES_QCFG_OUTPUT_FLAGS_DFLT_VNIC    UINT32_C(0x40)
-       uint16_t jumbo_thresh;
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
        /*
-        * When jumbo placement algorithm is enabled, this value is used to
-        * determine the threshold for jumbo placement. Packets with length
-        * larger than this value will be placed according to the jumbo
-        * placement algorithm.
+        * This field is the length of the response in bytes. The last
+        * byte of the response is a valid flag that will read as '1'
+        * when the command has been completely written to memory.
         */
-       uint16_t hds_offset;
+       uint64_t l2_filter_id;
        /*
-        * This value is used to determine the offset into packet buffer where
-        * the split data (payload) will be placed according to one of of HDS
-        * placement algorithm. The lengths of packet buffers provided for split
-        * data shall be larger than this value.
+        * This value identifies a set of CFA data structures used for
+        * an L2 context.
         */
-       uint16_t hds_threshold;
+       uint32_t flow_id;
        /*
-        * When one of the HDS placement algorithm is enabled, this value is
-        * used to determine the threshold for HDS placement. Packets with
-        * length larger than this value will be placed according to the HDS
-        * placement algorithm. This value shall be in multiple of 4 bytes.
+        * This is the ID of the flow associated with this filter. This
+        * value shall be used to match and associate the flow
+        * identifier returned in completion records. A value of
+        * 0xFFFFFFFF shall indicate no flow id.
         */
        uint8_t unused_0;
        uint8_t unused_1;
        uint8_t unused_2;
-       uint8_t unused_3;
-       uint8_t unused_4;
        uint8_t valid;
        /*
-        * This field is used in Output records to indicate that the output is
-        * completely written to RAM. This field should be read as '1' to
-        * indicate that the output has been completely written. When writing a
-        * command completion or response to an internal processor, the order of
-        * writes has to be such that this field is written last.
+        * This field is used in Output records to indicate that the
+        * output is completely written to RAM. This field should be
+        * read as '1' to indicate that the output has been completely
+        * written. When writing a command completion or response to an
+        * internal processor, the order of writes has to be such that
+        * this field is written last.
         */
 } __attribute__((packed));
 
-/* hwrm_vnic_rss_cos_lb_ctx_alloc */
-/* Description: This function is used to allocate COS/Load Balance context. */
-/* Input       (16 bytes) */
-struct hwrm_vnic_rss_cos_lb_ctx_alloc_input {
+/* hwrm_cfa_l2_filter_free */
+/*
+ * Description: Free a L2 filter. The HWRM shall free all associated filter
+ * resources with the L2 filter.
+ */
+/* Input       (24 bytes) */
+struct hwrm_cfa_l2_filter_free_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -6972,10 +9222,15 @@ struct hwrm_vnic_rss_cos_lb_ctx_alloc_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
+       uint64_t l2_filter_id;
+       /*
+        * This value identifies a set of CFA data structures used for
+        * an L2 context.
+        */
 } __attribute__((packed));
 
 /* Output      (16 bytes) */
-struct hwrm_vnic_rss_cos_lb_ctx_alloc_output {
+struct hwrm_cfa_l2_filter_free_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -6991,13 +9246,10 @@ struct hwrm_vnic_rss_cos_lb_ctx_alloc_output {
         * byte of the response is a valid flag that will read as '1'
         * when the command has been completely written to memory.
         */
-       uint16_t rss_cos_lb_ctx_id;
-       /* rss_cos_lb_ctx_id is 16 b */
-       uint8_t unused_0;
+       uint32_t unused_0;
        uint8_t unused_1;
        uint8_t unused_2;
        uint8_t unused_3;
-       uint8_t unused_4;
        uint8_t valid;
        /*
         * This field is used in Output records to indicate that the
@@ -7009,10 +9261,10 @@ struct hwrm_vnic_rss_cos_lb_ctx_alloc_output {
         */
 } __attribute__((packed));
 
-/* hwrm_vnic_rss_cos_lb_ctx_free */
-/* Description: This function can be used to free COS/Load Balance context. */
-/* Input       (24 bytes) */
-struct hwrm_vnic_rss_cos_lb_ctx_free_input {
+/* hwrm_cfa_l2_filter_cfg */
+/* Description: Change the configuration of an existing L2 filter */
+/* Input       (40 bytes) */
+struct hwrm_cfa_l2_filter_cfg_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -7039,13 +9291,52 @@ struct hwrm_vnic_rss_cos_lb_ctx_free_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint16_t rss_cos_lb_ctx_id;
-       /* rss_cos_lb_ctx_id is 16 b */
-       uint16_t unused_0[3];
+       uint32_t flags;
+       /*
+        * Enumeration denoting the RX, TX type of the resource. This
+        * enumeration is used for resources that are similar for both
+        * TX and RX paths of the chip.
+        */
+       #define HWRM_CFA_L2_FILTER_CFG_INPUT_FLAGS_PATH UINT32_C(0x1)
+       /* tx path */
+       #define HWRM_CFA_L2_FILTER_CFG_INPUT_FLAGS_PATH_TX \
+               (UINT32_C(0x0) << 0)
+       /* rx path */
+       #define HWRM_CFA_L2_FILTER_CFG_INPUT_FLAGS_PATH_RX \
+               (UINT32_C(0x1) << 0)
+       #define HWRM_CFA_L2_FILTER_CFG_INPUT_FLAGS_PATH_LAST \
+               CFA_L2_FILTER_CFG_INPUT_FLAGS_PATH_RX
+       /*
+        * Setting of this flag indicates drop action. If this flag is
+        * not set, then it should be considered accept action.
+        */
+       #define HWRM_CFA_L2_FILTER_CFG_INPUT_FLAGS_DROP UINT32_C(0x2)
+       uint32_t enables;
+       /* This bit must be '1' for the dst_id field to be configured. */
+       #define HWRM_CFA_L2_FILTER_CFG_INPUT_ENABLES_DST_ID     UINT32_C(0x1)
+       /*
+        * This bit must be '1' for the new_mirror_vnic_id field to be
+        * configured.
+        */
+       #define HWRM_CFA_L2_FILTER_CFG_INPUT_ENABLES_NEW_MIRROR_VNIC_ID   \
+               UINT32_C(0x2)
+       uint64_t l2_filter_id;
+       /*
+        * This value identifies a set of CFA data structures used for
+        * an L2 context.
+        */
+       uint32_t dst_id;
+       /*
+        * If set, this value shall represent the Logical VNIC ID of the
+        * destination VNIC for the RX path and network port id of the
+        * destination port for the TX path.
+        */
+       uint32_t new_mirror_vnic_id;
+       /* New Logical VNIC ID of the VNIC where traffic is mirrored. */
 } __attribute__((packed));
 
 /* Output      (16 bytes) */
-struct hwrm_vnic_rss_cos_lb_ctx_free_output {
+struct hwrm_cfa_l2_filter_cfg_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -7076,10 +9367,10 @@ struct hwrm_vnic_rss_cos_lb_ctx_free_output {
         */
 } __attribute__((packed));
 
-/* hwrm_vnic_tpa_cfg */
-/* Description: This function is used to enable/configure TPA on the VNIC. */
-/* Input       (40 bytes) */
-struct hwrm_vnic_tpa_cfg_input {
+/* hwrm_cfa_l2_set_rx_mask */
+/* Description: This command will set rx mask of the function. */
+/* Input       (56 bytes) */
+struct hwrm_cfa_l2_set_rx_mask_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -7106,122 +9397,110 @@ struct hwrm_vnic_tpa_cfg_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint32_t flags;
-       /*
-        * When this bit is '1', the VNIC shall be configured to perform
-        * transparent packet aggregation       (TPA) of non-tunneled TCP
-        * packets.
-        */
-       #define HWRM_VNIC_TPA_CFG_INPUT_FLAGS_TPA       UINT32_C(0x1)
-       /*
-        * When this bit is '1', the VNIC shall be configured to perform
-        * transparent packet aggregation       (TPA) of tunneled TCP packets.
-        */
-       #define HWRM_VNIC_TPA_CFG_INPUT_FLAGS_ENCAP_TPA UINT32_C(0x2)
+       uint32_t vnic_id;
+       /* VNIC ID */
+       uint32_t mask;
+       /* Reserved for future use. */
+       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_RESERVED     UINT32_C(0x1)
        /*
-        * When this bit is '1', the VNIC shall be configured to perform
-        * transparent packet aggregation       (TPA) according to Windows
-        * Receive Segment Coalescing   (RSC) rules.
+        * When this bit is '1', the function is requested to accept
+        * multi-cast packets specified by the multicast addr table.
         */
-       #define HWRM_VNIC_TPA_CFG_INPUT_FLAGS_RSC_WND_UPDATE    UINT32_C(0x4)
+       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_MCAST        UINT32_C(0x2)
        /*
-        * When this bit is '1', the VNIC shall be configured to perform
-        * transparent packet aggregation       (TPA) according to Linux
-        * Generic Receive Offload      (GRO) rules.
+        * When this bit is '1', the function is requested to accept all
+        * multi-cast packets.
         */
-       #define HWRM_VNIC_TPA_CFG_INPUT_FLAGS_GRO       UINT32_C(0x8)
+       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_ALL_MCAST    UINT32_C(0x4)
        /*
-        * When this bit is '1', the VNIC shall be configured to perform
-        * transparent packet aggregation       (TPA) for TCP packets with IP
-        * ECN set to non-zero.
+        * When this bit is '1', the function is requested to accept
+        * broadcast packets.
         */
-       #define HWRM_VNIC_TPA_CFG_INPUT_FLAGS_AGG_WITH_ECN      UINT32_C(0x10)
+       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_BCAST        UINT32_C(0x8)
        /*
-        * When this bit is '1', the VNIC shall be configured to perform
-        * transparent packet aggregation       (TPA) for GRE tunneled TCP
-        * packets only if all packets have the same GRE sequence.
+        * When this bit is '1', the function is requested to be put in
+        * the promiscuous mode. The HWRM should accept any function to
+        * set up promiscuous mode. The HWRM shall follow the semantics
+        * below for the promiscuous mode support. # When partitioning
+        * is not enabled on a port     (i.e. single PF on the port), then
+        * the PF shall be allowed to be in the promiscuous mode. When
+        * the PF is in the promiscuous mode, then it shall receive all
+        * host bound traffic on that port. # When partitioning is
+        * enabled on a port    (i.e. multiple PFs per port) and a PF on
+        * that port is in the promiscuous mode, then the PF receives
+        * all traffic within that partition as identified by a unique
+        * identifier for the PF        (e.g. S-Tag). If a unique outer VLAN
+        * for the PF is specified, then the setting of promiscuous mode
+        * on that PF shall result in the PF receiving all host bound
+        * traffic with matching outer VLAN. # A VF shall can be set in
+        * the promiscuous mode. In the promiscuous mode, the VF does
+        * not receive any traffic unless a unique outer VLAN for the VF
+        * is specified. If a unique outer VLAN for the VF is specified,
+        * then the setting of promiscuous mode on that VF shall result
+        * in the VF receiving all host bound traffic with the matching
+        * outer VLAN. # The HWRM shall allow the setting of promiscuous
+        * mode on a function independently from the promiscuous mode
+        * settings on other functions.
         */
-       #define HWRM_VNIC_TPA_CFG_INPUT_FLAGS_AGG_WITH_SAME_GRE_SEQ     \
-               UINT32_C(0x20)
+       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_PROMISCUOUS UINT32_C(0x10)
        /*
-        * When this bit is '1' and the GRO mode is enabled, the VNIC
-        * shall be configured to perform transparent packet aggregation
-        *      (TPA) for TCP/IPv4 packets with consecutively increasing
-        * IPIDs. In other words, the last packet that is being
-        * aggregated to an already existing aggregation context shall
-        * have IPID 1 more than the IPID of the last packet that was
-        * aggregated in that aggregation context.
+        * If this flag is set, the corresponding RX filters shall be
+        * set up to cover multicast/broadcast filters for the outermost
+        * Layer 2 destination MAC address field.
         */
-       #define HWRM_VNIC_TPA_CFG_INPUT_FLAGS_GRO_IPID_CHECK    UINT32_C(0x40)
+       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_OUTERMOST    UINT32_C(0x20)
        /*
-        * When this bit is '1' and the GRO mode is enabled, the VNIC
-        * shall be configured to perform transparent packet aggregation
-        *      (TPA) for TCP packets with the same TTL (IPv4) or Hop limit
-        *      (IPv6) value.
+        * If this flag is set, the corresponding RX filters shall be
+        * set up to cover multicast/broadcast filters for the VLAN-
+        * tagged packets that match the TPID and VID fields of VLAN
+        * tags in the VLAN tag table specified in this command.
         */
-       #define HWRM_VNIC_TPA_CFG_INPUT_FLAGS_GRO_TTL_CHECK     UINT32_C(0x80)
-       uint32_t enables;
-       /* This bit must be '1' for the max_agg_segs field to be configured. */
-       #define HWRM_VNIC_TPA_CFG_INPUT_ENABLES_MAX_AGG_SEGS    UINT32_C(0x1)
-       /* This bit must be '1' for the max_aggs field to be configured. */
-       #define HWRM_VNIC_TPA_CFG_INPUT_ENABLES_MAX_AGGS        UINT32_C(0x2)
+       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_VLANONLY     UINT32_C(0x40)
        /*
-        * This bit must be '1' for the max_agg_timer field to be
-        * configured.
+        * If this flag is set, the corresponding RX filters shall be
+        * set up to cover multicast/broadcast filters for non-VLAN
+        * tagged packets and VLAN-tagged packets that match the TPID
+        * and VID fields of VLAN tags in the VLAN tag table specified
+        * in this command.
         */
-       #define HWRM_VNIC_TPA_CFG_INPUT_ENABLES_MAX_AGG_TIMER   UINT32_C(0x4)
-       /* This bit must be '1' for the min_agg_len field to be configured. */
-       #define HWRM_VNIC_TPA_CFG_INPUT_ENABLES_MIN_AGG_LEN     UINT32_C(0x8)
-       uint16_t vnic_id;
-       /* Logical vnic ID */
-       uint16_t max_agg_segs;
+       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_VLAN_NONVLAN UINT32_C(0x80)
        /*
-        * This is the maximum number of TCP segments that can be
-        * aggregated   (unit is Log2). Max value is 31.
+        * If this flag is set, the corresponding RX filters shall be
+        * set up to cover multicast/broadcast filters for non-VLAN
+        * tagged packets and VLAN-tagged packets matching any VLAN tag.
+        * If this flag is set, then the HWRM shall ignore VLAN tags
+        * specified in vlan_tag_tbl. If none of vlanonly, vlan_nonvlan,
+        * and anyvlan_nonvlan flags is set, then the HWRM shall ignore
+        * VLAN tags specified in vlan_tag_tbl. The HWRM client shall
+        * set at most one flag out of vlanonly, vlan_nonvlan, and
+        * anyvlan_nonvlan.
         */
-       /* 1 segment */
-       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGG_SEGS_1  UINT32_C(0x0)
-       /* 2 segments */
-       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGG_SEGS_2  UINT32_C(0x1)
-       /* 4 segments */
-       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGG_SEGS_4  UINT32_C(0x2)
-       /* 8 segments */
-       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGG_SEGS_8  UINT32_C(0x3)
-       /* Any segment size larger than this is not valid */
-       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGG_SEGS_MAX        UINT32_C(0x1f)
-       uint16_t max_aggs;
+       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_ANYVLAN_NONVLAN      \
+               UINT32_C(0x100)
+       uint64_t mc_tbl_addr;
+       /* This is the address for mcast address tbl. */
+       uint32_t num_mc_entries;
        /*
-        * This is the maximum number of aggregations this VNIC is
-        * allowed      (unit is Log2). Max value is 7
+        * This value indicates how many entries in mc_tbl are valid.
+        * Each entry is 6 bytes.
         */
-       /* 1 aggregation */
-       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGGS_1      UINT32_C(0x0)
-       /* 2 aggregations */
-       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGGS_2      UINT32_C(0x1)
-       /* 4 aggregations */
-       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGGS_4      UINT32_C(0x2)
-       /* 8 aggregations */
-       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGGS_8      UINT32_C(0x3)
-       /* 16 aggregations */
-       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGGS_16     UINT32_C(0x4)
-       /* Any aggregation size larger than this is not valid */
-       #define HWRM_VNIC_TPA_CFG_INPUT_MAX_AGGS_MAX    UINT32_C(0x7)
-       uint8_t unused_0;
-       uint8_t unused_1;
-       uint32_t max_agg_timer;
+       uint32_t unused_0;
+       uint64_t vlan_tag_tbl_addr;
        /*
-        * This is the maximum amount of time allowed for an aggregation
-        * context to complete after it was initiated.
+        * This is the address for VLAN tag table. Each VLAN entry in
+        * the table is 4 bytes of a VLAN tag including TPID, PCP, DEI,
+        * and VID fields in network byte order.
         */
-       uint32_t min_agg_len;
+       uint32_t num_vlan_tags;
        /*
-        * This is the minimum amount of payload length required to
-        * start an aggregation context.
+        * This value indicates how many entries in vlan_tag_tbl are
+        * valid. Each entry is 4 bytes.
         */
+       uint32_t unused_1;
 } __attribute__((packed));
 
 /* Output      (16 bytes) */
-struct hwrm_vnic_tpa_cfg_output {
+struct hwrm_cfa_l2_set_rx_mask_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -7252,12 +9531,116 @@ struct hwrm_vnic_tpa_cfg_output {
         */
 } __attribute__((packed));
 
-/* hwrm_ring_alloc */
+/* Command specific Error Codes (8 bytes) */
+struct hwrm_cfa_l2_set_rx_mask_cmd_err {
+       uint8_t code;
+       /*
+        * command specific error codes that goes to the cmd_err field
+        * in Common HWRM Error Response.
+        */
+       /* Unknown error */
+       #define HWRM_CFA_L2_SET_RX_MASK_CMD_ERR_CODE_UNKNOWN UINT32_C(0x0)
+       /*
+        * Unable to complete operation due to conflict
+        * with Ntuple Filter
+        */
+       #define \
+       HWRM_CFA_L2_SET_RX_MASK_CMD_ERR_CODE_NTUPLE_FILTER_CONFLICT_ERR \
+       UINT32_C(0x1)
+       uint8_t unused_0[7];
+} __attribute__((packed));
+
+/* hwrm_cfa_vlan_antispoof_cfg */
+/* Description: Configures vlan anti-spoof filters for VF. */
+/* Input (32 bytes) */
+struct hwrm_cfa_vlan_antispoof_cfg_input {
+       uint16_t req_type;
+       /*
+        * This value indicates what type of request this is. The format for the
+        * rest of the command is determined by this field.
+        */
+       uint16_t cmpl_ring;
+       /*
+        * This value indicates the what completion ring the request will be
+        * optionally completed on. If the value is -1, then no CR completion
+        * will be generated. Any other value must be a valid CR ring_id value
+        * for this function.
+        */
+       uint16_t seq_id;
+       /* This value indicates the command sequence number. */
+       uint16_t target_id;
+       /*
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function ids
+        * 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF - HWRM
+        */
+       uint64_t resp_addr;
+       /*
+        * This is the host address where the response will be written when the
+        * request is complete. This area must be 16B aligned and must be
+        * cleared to zero before the request is made.
+        */
+       uint16_t fid;
+       /*
+        * Function ID of the function that is being configured. Only valid for
+        * a VF FID configured by the PF.
+        */
+       uint8_t unused_0;
+       uint8_t unused_1;
+       uint32_t num_vlan_entries;
+       /* Number of VLAN entries in the vlan_tag_mask_tbl. */
+       uint64_t vlan_tag_mask_tbl_addr;
+       /*
+        * The vlan_tag_mask_tbl_addr is the DMA address of the VLAN antispoof
+        * table. Each table entry contains the 16-bit TPID (0x8100 or 0x88a8
+        * only), 16-bit VLAN ID, and a 16-bit mask, all in network order to
+        * match hwrm_cfa_l2_set_rx_mask. For an individual VLAN entry, the mask
+        * value should be 0xfff for the 12-bit VLAN ID.
+        */
+};
+
+/* Output (16 bytes) */
+struct hwrm_cfa_vlan_antispoof_cfg_output {
+       uint16_t error_code;
+       /*
+        * Pass/Fail or error type Note: receiver to verify the in parameters,
+        * and fail the call with an error when appropriate
+        */
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
+       /*
+        * This field is the length of the response in bytes. The last byte of
+        * the response is a valid flag that will read as '1' when the command
+        * has been completely written to memory.
+        */
+       uint32_t unused_0;
+       uint8_t unused_1;
+       uint8_t unused_2;
+       uint8_t unused_3;
+       uint8_t valid;
+       /*
+        * This field is used in Output records to indicate that the output is
+        * completely written to RAM. This field should be read as '1' to
+        * indicate that the output has been completely written. When writing a
+        * command completion or response to an internal processor, the order of
+        * writes has to be such that this field is written last.
+        */
+};
+
+/* hwrm_cfa_ntuple_filter_alloc */
 /*
- * Description: This command allocates and does basic preparation for a ring.
+ * Description: This is a ntuple filter that uses fields from L4/L3 header and
+ * optionally fields from L2. The ntuple filters apply to receive traffic only.
+ * All L2/L3/L4 header fields are specified in network byte order. These filters
+ * can be used for Receive Flow Steering (RFS). # For ethertype value, only
+ * 0x0800 (IPv4) and 0x86dd (IPv6) shall be supported for ntuple filters. # If a
+ * field specified in this command is not enabled as a valid field, then that
+ * field shall not be used in matching packet header fields against this filter.
  */
-/* Input       (80 bytes) */
-struct hwrm_ring_alloc_input {
+/* Input       (128 bytes) */
+struct hwrm_cfa_ntuple_filter_alloc_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -7284,201 +9667,258 @@ struct hwrm_ring_alloc_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
+       uint32_t flags;
+       /*
+        * Setting of this flag indicates the applicability to the
+        * loopback path.
+        */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_FLAGS_LOOPBACK       \
+               UINT32_C(0x1)
+       /*
+        * Setting of this flag indicates drop action. If this flag is
+        * not set, then it should be considered accept action.
+        */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_FLAGS_DROP   UINT32_C(0x2)
+       /*
+        * Setting of this flag indicates that a meter is expected to be
+        * attached to this flow. This hint can be used when choosing
+        * the action record format required for the flow.
+        */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_FLAGS_METER UINT32_C(0x4)
        uint32_t enables;
-       /* This bit must be '1' for the Reserved1 field to be configured. */
-       #define HWRM_RING_ALLOC_INPUT_ENABLES_RESERVED1 UINT32_C(0x1)
-       /* This bit must be '1' for the ring_arb_cfg field to be configured. */
-       #define HWRM_RING_ALLOC_INPUT_ENABLES_RING_ARB_CFG      UINT32_C(0x2)
-       /* This bit must be '1' for the Reserved3 field to be configured. */
-       #define HWRM_RING_ALLOC_INPUT_ENABLES_RESERVED3 UINT32_C(0x4)
+       /* This bit must be '1' for the l2_filter_id field to be configured. */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_L2_FILTER_ID   \
+               UINT32_C(0x1)
+       /* This bit must be '1' for the ethertype field to be configured. */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_ETHERTYPE     \
+               UINT32_C(0x2)
+       /* This bit must be '1' for the tunnel_type field to be configured. */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_TUNNEL_TYPE  \
+               UINT32_C(0x4)
+       /* This bit must be '1' for the src_macaddr field to be configured. */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_SRC_MACADDR  \
+               UINT32_C(0x8)
+       /* This bit must be '1' for the ipaddr_type field to be configured. */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_IPADDR_TYPE  \
+               UINT32_C(0x10)
+       /* This bit must be '1' for the src_ipaddr field to be configured. */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_SRC_IPADDR   \
+               UINT32_C(0x20)
        /*
-        * This bit must be '1' for the stat_ctx_id_valid field to be
+        * This bit must be '1' for the src_ipaddr_mask field to be
         * configured.
         */
-       #define HWRM_RING_ALLOC_INPUT_ENABLES_STAT_CTX_ID_VALID UINT32_C(0x8)
-       /* This bit must be '1' for the Reserved4 field to be configured. */
-       #define HWRM_RING_ALLOC_INPUT_ENABLES_RESERVED4 UINT32_C(0x10)
-       /* This bit must be '1' for the max_bw_valid field to be configured. */
-       #define HWRM_RING_ALLOC_INPUT_ENABLES_MAX_BW_VALID      UINT32_C(0x20)
-       uint8_t ring_type;
-       /* Ring Type. */
-       /* L2 Completion Ring   (CR) */
-       #define HWRM_RING_ALLOC_INPUT_RING_TYPE_L2_CMPL UINT32_C(0x0)
-       /* TX Ring      (TR) */
-       #define HWRM_RING_ALLOC_INPUT_RING_TYPE_TX      UINT32_C(0x1)
-       /* RX Ring      (RR) */
-       #define HWRM_RING_ALLOC_INPUT_RING_TYPE_RX      UINT32_C(0x2)
-       /* RoCE Notification Completion Ring    (ROCE_CR) */
-       #define HWRM_RING_ALLOC_INPUT_RING_TYPE_ROCE_CMPL       UINT32_C(0x3)
-       uint8_t unused_0;
-       uint16_t unused_1;
-       uint64_t page_tbl_addr;
-       /* This value is a pointer to the page table for the Ring. */
-       uint32_t fbo;
-       /* First Byte Offset of the first entry in the first page. */
-       uint8_t page_size;
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_SRC_IPADDR_MASK \
+               UINT32_C(0x40)
+       /* This bit must be '1' for the dst_ipaddr field to be configured. */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_DST_IPADDR   \
+               UINT32_C(0x80)
        /*
-        * Actual page size in 2^page_size. The supported range is
-        * increments in powers of 2 from 16 bytes to 1GB. - 4 = 16 B
-        * Page size is 16 B. - 12 = 4 KB Page size is 4 KB. - 13 = 8 KB
-        * Page size is 8 KB. - 16 = 64 KB Page size is 64 KB. - 21 = 2
-        * MB Page size is 2 MB. - 22 = 4 MB Page size is 4 MB. - 30 = 1
-        * GB Page size is 1 GB.
+        * This bit must be '1' for the dst_ipaddr_mask field to be
+        * configured.
         */
-       uint8_t page_tbl_depth;
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_DST_IPADDR_MASK \
+               UINT32_C(0x100)
+       /* This bit must be '1' for the ip_protocol field to be configured. */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_IP_PROTOCOL  \
+               UINT32_C(0x200)
+       /* This bit must be '1' for the src_port field to be configured. */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_SRC_PORT     \
+               UINT32_C(0x400)
        /*
-        * This value indicates the depth of page table. For this
-        * version of the specification, value other than 0 or 1 shall
-        * be considered as an invalid value. When the page_tbl_depth =
-        * 0, then it is treated as a special case with the following.
-        * 1. FBO and page size fields are not valid. 2. page_tbl_addr
-        * is the physical address of the first element of the ring.
+        * This bit must be '1' for the src_port_mask field to be
+        * configured.
         */
-       uint8_t unused_2;
-       uint8_t unused_3;
-       uint32_t length;
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_SRC_PORT_MASK  \
+               UINT32_C(0x800)
+       /* This bit must be '1' for the dst_port field to be configured. */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_DST_PORT     \
+               UINT32_C(0x1000)
        /*
-        * Number of 16B units in the ring. Minimum size for a ring is
-        * 16 16B entries.
+        * This bit must be '1' for the dst_port_mask field to be
+        * configured.
         */
-       uint16_t logical_id;
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_DST_PORT_MASK  \
+               UINT32_C(0x2000)
+       /* This bit must be '1' for the pri_hint field to be configured. */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_PRI_HINT     \
+               UINT32_C(0x4000)
        /*
-        * Logical ring number for the ring to be allocated. This value
-        * determines the position in the doorbell area where the update
-        * to the ring will be made. For completion rings, this value is
-        * also the MSI-X vector number for the function the completion
-        * ring is associated with.
+        * This bit must be '1' for the ntuple_filter_id field to be
+        * configured.
         */
-       uint16_t cmpl_ring_id;
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_NTUPLE_FILTER_ID \
+               UINT32_C(0x8000)
+       /* This bit must be '1' for the dst_id field to be configured. */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_DST_ID       \
+               UINT32_C(0x10000)
        /*
-        * This field is used only when ring_type is a TX ring. This
-        * value indicates what completion ring the TX ring is
-        * associated with.
+        * This bit must be '1' for the mirror_vnic_id field to be
+        * configured.
+        */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_MIRROR_VNIC_ID \
+               UINT32_C(0x20000)
+       /* This bit must be '1' for the dst_macaddr field to be configured. */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_DST_MACADDR  \
+               UINT32_C(0x40000)
+       uint64_t l2_filter_id;
+       /*
+        * This value identifies a set of CFA data structures used for
+        * an L2 context.
+        */
+       uint8_t src_macaddr[6];
+       /*
+        * This value indicates the source MAC address in the Ethernet
+        * header.
+        */
+       uint16_t ethertype;
+       /* This value indicates the ethertype in the Ethernet header. */
+       uint8_t ip_addr_type;
+       /*
+        * This value indicates the type of IP address. 4 - IPv4 6 -
+        * IPv6 All others are invalid.
+        */
+       /* invalid */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_IP_ADDR_TYPE_UNKNOWN \
+               UINT32_C(0x0)
+       /* IPv4 */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_IP_ADDR_TYPE_IPV4 \
+               UINT32_C(0x4)
+       /* IPv6 */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_IP_ADDR_TYPE_IPV6 \
+               UINT32_C(0x6)
+       uint8_t ip_protocol;
+       /*
+        * The value of protocol filed in IP header. Applies to UDP and
+        * TCP traffic. 6 - TCP 17 - UDP
+        */
+       /* invalid */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_IP_PROTOCOL_UNKNOWN \
+               UINT32_C(0x0)
+       /* TCP */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_IP_PROTOCOL_TCP \
+               UINT32_C(0x6)
+       /* UDP */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_IP_PROTOCOL_UDP \
+               UINT32_C(0x11)
+       uint16_t dst_id;
+       /*
+        * If set, this value shall represent the Logical VNIC ID of the
+        * destination VNIC for the RX path and network port id of the
+        * destination port for the TX path.
+        */
+       uint16_t mirror_vnic_id;
+       /* Logical VNIC ID of the VNIC where traffic is mirrored. */
+       uint8_t tunnel_type;
+       /*
+        * This value indicates the tunnel type for this filter. If this
+        * field is not specified, then the filter shall apply to both
+        * non-tunneled and tunneled packets. If this field conflicts
+        * with the tunnel_type specified in the l2_filter_id, then the
+        * HWRM shall return an error for this command.
+        */
+       /* Non-tunnel */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_TUNNEL_TYPE_NONTUNNEL \
+               UINT32_C(0x0)
+       /* Virtual eXtensible Local Area Network        (VXLAN) */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_TUNNEL_TYPE_VXLAN \
+               UINT32_C(0x1)
+       /*
+        * Network Virtualization Generic Routing
+        * Encapsulation        (NVGRE)
+        */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_TUNNEL_TYPE_NVGRE \
+               UINT32_C(0x2)
+       /*
+        * Generic Routing Encapsulation        (GRE) inside
+        * Ethernet payload
+        */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_TUNNEL_TYPE_L2GRE \
+               UINT32_C(0x3)
+       /* IP in IP */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_TUNNEL_TYPE_IPIP \
+               UINT32_C(0x4)
+       /* Generic Network Virtualization Encapsulation (Geneve) */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_TUNNEL_TYPE_GENEVE \
+               UINT32_C(0x5)
+       /* Multi-Protocol Lable Switching       (MPLS) */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_TUNNEL_TYPE_MPLS \
+               UINT32_C(0x6)
+       /* Stateless Transport Tunnel   (STT) */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_TUNNEL_TYPE_STT UINT32_C(0x7)
+       /*
+        * Generic Routing Encapsulation        (GRE) inside IP
+        * datagram payload
+        */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_TUNNEL_TYPE_IPGRE \
+               UINT32_C(0x8)
+       /* Any tunneled traffic */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_TUNNEL_TYPE_ANYTUNNEL \
+               UINT32_C(0xff)
+       uint8_t pri_hint;
+       /*
+        * This hint is provided to help in placing the filter in the
+        * filter table.
         */
-       uint16_t queue_id;
+       /* No preference */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_PRI_HINT_NO_PREFER \
+               UINT32_C(0x0)
+       /* Above the given filter */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_PRI_HINT_ABOVE UINT32_C(0x1)
+       /* Below the given filter */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_PRI_HINT_BELOW UINT32_C(0x2)
+       /* As high as possible */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_PRI_HINT_HIGHEST \
+               UINT32_C(0x3)
+       /* As low as possible */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_PRI_HINT_LOWEST UINT32_C(0x4)
+       uint32_t src_ipaddr[4];
        /*
-        * This field is used only when ring_type is a TX ring. This
-        * value indicates what CoS queue the TX ring is associated
-        * with.
+        * The value of source IP address to be used in filtering. For
+        * IPv4, first four bytes represent the IP address.
         */
-       uint8_t unused_4;
-       uint8_t unused_5;
-       uint32_t reserved1;
-       /* This field is reserved for the future use. It shall be set to 0. */
-       uint16_t ring_arb_cfg;
+       uint32_t src_ipaddr_mask[4];
        /*
-        * This field is used only when ring_type is a TX ring. This
-        * field is used to configure arbitration related parameters for
-        * a TX ring.
+        * The value of source IP address mask to be used in filtering.
+        * For IPv4, first four bytes represent the IP address mask.
         */
-       /* Arbitration policy used for the ring. */
-       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_ARB_POLICY_MASK UINT32_C(0xf)
-       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_ARB_POLICY_SFT       0
+       uint32_t dst_ipaddr[4];
        /*
-        * Use strict priority for the TX ring. Priority
-        * value is specified in arb_policy_param
+        * The value of destination IP address to be used in filtering.
+        * For IPv4, first four bytes represent the IP address.
         */
-       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_ARB_POLICY_SP \
-               (UINT32_C(0x1) << 0)
+       uint32_t dst_ipaddr_mask[4];
        /*
-        * Use weighted fair queue arbitration for the
-        * TX ring. Weight is specified in
-        * arb_policy_param
+        * The value of destination IP address mask to be used in
+        * filtering. For IPv4, first four bytes represent the IP
+        * address mask.
         */
-       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_ARB_POLICY_WFQ \
-               (UINT32_C(0x2) << 0)
-       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_ARB_POLICY_LAST \
-               RING_ALLOC_INPUT_RING_ARB_CFG_ARB_POLICY_WFQ
-       /* Reserved field. */
-       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_RSVD_MASK    UINT32_C(0xf0)
-       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_RSVD_SFT     4
+       uint16_t src_port;
        /*
-        * Arbitration policy specific parameter. # For strict priority
-        * arbitration policy, this field represents a priority value.
-        * If set to 0, then the priority is not specified and the HWRM
-        * is allowed to select any priority for this TX ring. # For
-        * weighted fair queue arbitration policy, this field represents
-        * a weight value. If set to 0, then the weight is not specified
-        * and the HWRM is allowed to select any weight for this TX
-        * ring.
+        * The value of source port to be used in filtering. Applies to
+        * UDP and TCP traffic.
         */
-       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_ARB_POLICY_PARAM_MASK  \
-               UINT32_C(0xff00)
-       #define HWRM_RING_ALLOC_INPUT_RING_ARB_CFG_ARB_POLICY_PARAM_SFT 8
-       uint8_t unused_6;
-       uint8_t unused_7;
-       uint32_t reserved3;
-       /* This field is reserved for the future use. It shall be set to 0. */
-       uint32_t stat_ctx_id;
+       uint16_t src_port_mask;
        /*
-        * This field is used only when ring_type is a TX ring. This
-        * input indicates what statistics context this ring should be
-        * associated with.
+        * The value of source port mask to be used in filtering.
+        * Applies to UDP and TCP traffic.
         */
-       uint32_t reserved4;
-       /* This field is reserved for the future use. It shall be set to 0. */
-       uint32_t max_bw;
+       uint16_t dst_port;
        /*
-        * This field is used only when ring_type is a TX ring to
-        * specify maximum BW allocated to the TX ring. The HWRM will
-        * translate this value into byte counter and time interval used
-        * for this ring inside the device.
+        * The value of destination port to be used in filtering.
+        * Applies to UDP and TCP traffic.
         */
-       /* The bandwidth value. */
-       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_MASK UINT32_C(0xfffffff)
-       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_SFT       0
-       /* The granularity of the value (bits or bytes). */
-       #define HWRM_RING_ALLOC_INPUT_MAX_BW_SCALE      UINT32_C(0x10000000)
-       /* Value is in bits. */
-       #define HWRM_RING_ALLOC_INPUT_MAX_BW_SCALE_BITS (UINT32_C(0x0) << 28)
-       /* Value is in bytes. */
-       #define HWRM_RING_ALLOC_INPUT_MAX_BW_SCALE_BYTES (UINT32_C(0x1) << 28)
-       #define HWRM_RING_ALLOC_INPUT_MAX_BW_SCALE_LAST \
-               RING_ALLOC_INPUT_MAX_BW_SCALE_BYTES
-       /* bw_value_unit is 3 b */
-       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_MASK \
-               UINT32_C(0xe0000000)
-       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_SFT  29
-       /* Value is in Mb or MB (base 10). */
-       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_MEGA \
-               (UINT32_C(0x0) << 29)
-       /* Value is in Kb or KB (base 10). */
-       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_KILO \
-               (UINT32_C(0x2) << 29)
-       /* Value is in bits or bytes. */
-       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_BASE \
-               (UINT32_C(0x4) << 29)
-       /* Value is in Gb or GB (base 10). */
-       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_GIGA \
-               (UINT32_C(0x6) << 29)
-       /* Value is in 1/100th of a percentage of total bandwidth. */
-       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_PERCENT1_100 \
-               (UINT32_C(0x1) << 29)
-       /* Invalid unit */
-       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_INVALID \
-               (UINT32_C(0x7) << 29)
-       #define HWRM_RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_LAST \
-               RING_ALLOC_INPUT_MAX_BW_BW_VALUE_UNIT_INVALID
-       uint8_t int_mode;
+       uint16_t dst_port_mask;
        /*
-        * This field is used only when ring_type is a Completion ring.
-        * This value indicates what interrupt mode should be used on
-        * this completion ring. Note: In the legacy interrupt mode, no
-        * more than 16 completion rings are allowed.
+        * The value of destination port mask to be used in filtering.
+        * Applies to UDP and TCP traffic.
         */
-       /* Legacy INTA */
-       #define HWRM_RING_ALLOC_INPUT_INT_MODE_LEGACY   UINT32_C(0x0)
-       /* Reserved */
-       #define HWRM_RING_ALLOC_INPUT_INT_MODE_RSVD     UINT32_C(0x1)
-       /* MSI-X */
-       #define HWRM_RING_ALLOC_INPUT_INT_MODE_MSIX     UINT32_C(0x2)
-       /* No Interrupt - Polled mode */
-       #define HWRM_RING_ALLOC_INPUT_INT_MODE_POLL     UINT32_C(0x3)
-       uint8_t unused_8[3];
+       uint64_t ntuple_filter_id_hint;
+       /* This is the ID of the filter that goes along with the pri_hint. */
 } __attribute__((packed));
 
-/* Output      (16 bytes) */
-struct hwrm_ring_alloc_output {
+/* Output      (24 bytes) */
+struct hwrm_cfa_ntuple_filter_alloc_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -7494,13 +9934,15 @@ struct hwrm_ring_alloc_output {
         * byte of the response is a valid flag that will read as '1'
         * when the command has been completely written to memory.
         */
-       uint16_t ring_id;
+       uint64_t ntuple_filter_id;
+       /* This value is an opaque id into CFA data structures. */
+       uint32_t flow_id;
        /*
-        * Physical number of ring allocated. This value shall be unique
-        * for a ring type.
+        * This is the ID of the flow associated with this filter. This
+        * value shall be used to match and associate the flow
+        * identifier returned in completion records. A value of
+        * 0xFFFFFFFF shall indicate no flow id.
         */
-       uint16_t logical_ring_id;
-       /* Logical number of ring allocated. */
        uint8_t unused_0;
        uint8_t unused_1;
        uint8_t unused_2;
@@ -7515,20 +9957,29 @@ struct hwrm_ring_alloc_output {
         */
 } __attribute__((packed));
 
-/* hwrm_ring_free */
-/*
- * Description: This command is used to free a ring and associated resources.
- * With QoS and DCBx agents, it is possible the traffic classes will be moved
- * from one CoS queue to another. When this occurs, the driver shall call
- * 'hwrm_ring_free' to free the allocated rings and then call 'hwrm_ring_alloc'
- * to re-allocate each ring and assign it to a new CoS queue. hwrm_ring_free
- * shall be called on a ring only after it has been idle for 500ms or more and
- * no frames have been posted to the ring during this time. All frames queued
- * for transmission shall be completed and at least 500ms time elapsed from the
- * last completion before calling this command.
- */
+/* Command specific Error Codes (8 bytes) */
+struct hwrm_cfa_ntuple_filter_alloc_cmd_err {
+       uint8_t code;
+       /*
+        * command specific error codes that goes to the cmd_err field
+        * in Common HWRM Error Response.
+        */
+       /* Unknown error */
+       #define HWRM_CFA_NTUPLE_FILTER_ALLOC_CMD_ERR_CODE_UNKNOWN UINT32_C(0x0)
+       /*
+        * Unable to complete operation due to conflict
+        * with Rx Mask VLAN
+        */
+       #define \
+       HWRM_CFA_NTUPLE_FILTER_ALLOC_CMD_ERR_CODE_RX_MASK_VLAN_CONFLICT_ERR \
+       UINT32_C(0x1)
+       uint8_t unused_0[7];
+} __attribute__((packed));
+
+/* hwrm_cfa_ntuple_filter_free */
+/* Description: Free an ntuple filter */
 /* Input       (24 bytes) */
-struct hwrm_ring_free_input {
+struct hwrm_cfa_ntuple_filter_free_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -7555,24 +10006,12 @@ struct hwrm_ring_free_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint8_t ring_type;
-       /* Ring Type. */
-       /* L2 Completion Ring   (CR) */
-       #define HWRM_RING_FREE_INPUT_RING_TYPE_L2_CMPL  UINT32_C(0x0)
-       /* TX Ring      (TR) */
-       #define HWRM_RING_FREE_INPUT_RING_TYPE_TX       UINT32_C(0x1)
-       /* RX Ring      (RR) */
-       #define HWRM_RING_FREE_INPUT_RING_TYPE_RX       UINT32_C(0x2)
-       /* RoCE Notification Completion Ring    (ROCE_CR) */
-       #define HWRM_RING_FREE_INPUT_RING_TYPE_ROCE_CMPL        UINT32_C(0x3)
-       uint8_t unused_0;
-       uint16_t ring_id;
-       /* Physical number of ring allocated. */
-       uint32_t unused_1;
+       uint64_t ntuple_filter_id;
+       /* This value is an opaque id into CFA data structures. */
 } __attribute__((packed));
 
 /* Output      (16 bytes) */
-struct hwrm_ring_free_output {
+struct hwrm_cfa_ntuple_filter_free_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -7603,12 +10042,13 @@ struct hwrm_ring_free_output {
         */
 } __attribute__((packed));
 
-/* hwrm_ring_grp_alloc */
+/* hwrm_cfa_ntuple_filter_cfg */
 /*
- * Description: This API allocates and does basic preparation for a ring group.
+ * Description: Configure an ntuple filter with a new destination VNIC and/or
+ * meter.
  */
-/* Input       (24 bytes) */
-struct hwrm_ring_grp_alloc_input {
+/* Input       (48 bytes) */
+struct hwrm_cfa_ntuple_filter_cfg_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -7635,104 +10075,50 @@ struct hwrm_ring_grp_alloc_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint16_t cr;
-       /* This value identifies the CR associated with the ring group. */
-       uint16_t rr;
-       /* This value identifies the main RR associated with the ring group. */
-       uint16_t ar;
-       /*
-        * This value identifies the aggregation RR associated with the
-        * ring group. If this value is 0xFF... (All Fs), then no
-        * Aggregation ring will be set.
-        */
-       uint16_t sc;
-       /*
-        * This value identifies the statistics context associated with
-        * the ring group.
-        */
-} __attribute__((packed));
-
-/* Output      (16 bytes) */
-struct hwrm_ring_grp_alloc_output {
-       uint16_t error_code;
-       /*
-        * Pass/Fail or error type Note: receiver to verify the in
-        * parameters, and fail the call with an error when appropriate
-        */
-       uint16_t req_type;
-       /* This field returns the type of original request. */
-       uint16_t seq_id;
-       /* This field provides original sequence number of the command. */
-       uint16_t resp_len;
-       /*
-        * This field is the length of the response in bytes. The last
-        * byte of the response is a valid flag that will read as '1'
-        * when the command has been completely written to memory.
-        */
-       uint32_t ring_group_id;
-       /*
-        * This is the ring group ID value. Use this value to program
-        * the default ring group for the VNIC or as table entries in an
-        * RSS/COS context.
-        */
-       uint8_t unused_0;
-       uint8_t unused_1;
-       uint8_t unused_2;
-       uint8_t valid;
+       uint32_t enables;
+       /* This bit must be '1' for the new_dst_id field to be configured. */
+       #define HWRM_CFA_NTUPLE_FILTER_CFG_INPUT_ENABLES_NEW_DST_ID     \
+               UINT32_C(0x1)
        /*
-        * This field is used in Output records to indicate that the
-        * output is completely written to RAM. This field should be
-        * read as '1' to indicate that the output has been completely
-        * written. When writing a command completion or response to an
-        * internal processor, the order of writes has to be such that
-        * this field is written last.
+        * This bit must be '1' for the new_mirror_vnic_id field to be
+        * configured.
         */
-} __attribute__((packed));
-
-/* hwrm_ring_grp_free */
-/*
- * Description: This API frees a ring group and associated resources. # If a
- * ring in the ring group is reset or free, then the associated rings in the
- * ring group shall also be reset/free using hwrm_ring_free. # A function driver
- * shall always use hwrm_ring_grp_free after freeing all rings in a group. # As
- * a part of executing this command, the HWRM shall reset all associated ring
- * group resources.
- */
-/* Input       (24 bytes) */
-struct hwrm_ring_grp_free_input {
-       uint16_t req_type;
+       #define HWRM_CFA_NTUPLE_FILTER_CFG_INPUT_ENABLES_NEW_MIRROR_VNIC_ID \
+               UINT32_C(0x2)
        /*
-        * This value indicates what type of request this is. The format
-        * for the rest of the command is determined by this field.
+        * This bit must be '1' for the new_meter_instance_id field to
+        * be configured.
         */
-       uint16_t cmpl_ring;
+       #define HWRM_CFA_NTUPLE_FILTER_CFG_INPUT_ENABLES_NEW_METER_INSTANCE_ID \
+               UINT32_C(0x4)
+       uint32_t unused_0;
+       uint64_t ntuple_filter_id;
+       /* This value is an opaque id into CFA data structures. */
+       uint32_t new_dst_id;
        /*
-        * This value indicates the what completion ring the request
-        * will be optionally completed on. If the value is -1, then no
-        * CR completion will be generated. Any other value must be a
-        * valid CR ring_id value for this function.
+        * If set, this value shall represent the new Logical VNIC ID of
+        * the destination VNIC for the RX path and new network port id
+        * of the destination port for the TX path.
         */
-       uint16_t seq_id;
-       /* This value indicates the command sequence number. */
-       uint16_t target_id;
-       /*
-        * Target ID of this command. 0x0 - 0xFFF8 - Used for function
-        * ids 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF
-        * - HWRM
+       uint32_t new_mirror_vnic_id;
+       /* New Logical VNIC ID of the VNIC where traffic is mirrored. */
+       uint16_t new_meter_instance_id;
+       /*
+        * New meter to attach to the flow. Specifying the invalid
+        * instance ID is used to remove any existing meter from the
+        * flow.
         */
-       uint64_t resp_addr;
        /*
-        * This is the host address where the response will be written
-        * when the request is complete. This area must be 16B aligned
-        * and must be cleared to zero before the request is made.
+        * A value of 0xfff is considered invalid and
+        * implies the instance is not configured.
         */
-       uint32_t ring_group_id;
-       /* This is the ring group ID value. */
-       uint32_t unused_0;
+       #define HWRM_CFA_NTUPLE_FILTER_CFG_INPUT_NEW_METER_INSTANCE_ID_INVALID \
+               UINT32_C(0xffff)
+       uint16_t unused_1[3];
 } __attribute__((packed));
 
 /* Output      (16 bytes) */
-struct hwrm_ring_grp_free_output {
+struct hwrm_cfa_ntuple_filter_cfg_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -7763,64 +10149,19 @@ struct hwrm_ring_grp_free_output {
         */
 } __attribute__((packed));
 
-/* hwrm_cfa_l2_filter_alloc */
+/* hwrm_cfa_em_flow_alloc */
 /*
- * Description: An L2 filter is a filter resource that is used to identify a
- * vnic or ring for a packet based on layer 2 fields. Layer 2 fields for
- * encapsulated packets include both outer L2 header and/or inner l2 header of
- * encapsulated packet. The L2 filter resource covers the following OS specific
- * L2 filters. Linux/FreeBSD (per function): # Broadcast enable/disable # List
- * of individual multicast filters # All multicast enable/disable filter #
- * Unicast filters # Promiscuous mode VMware: # Broadcast enable/disable (per
- * physical function) # All multicast enable/disable   (per function) # Unicast
- * filters per ring or vnic # Promiscuous mode per PF Windows: # Broadcast
- * enable/disable (per physical function) # List of individual multicast filters
- * (Driver needs to advertise the maximum number of filters supported) # All
- * multicast enable/disable per physical function # Unicast filters per vnic #
- * Promiscuous mode per PF Implementation notes on the use of VNIC in this
- * command: # By default, these filters belong to default vnic for the function.
- * # Once these filters are set up, only destination VNIC can be modified. # If
- * the destination VNIC is not specified in this command, then the HWRM shall
- * only create an l2 context id. HWRM Implementation notes for multicast
- * filters: # The hwrm_filter_alloc command can be used to set up multicast
- * filters (perfect match or partial match). Each individual function driver can
- * set up multicast filters independently. # The HWRM needs to keep track of
- * multicast filters set up by function drivers and maintain multicast group
- * replication records to enable a subset of functions to receive traffic for a
- * specific multicast address. # When a specific multicast filter cannot be set,
- * the HWRM shall return an error. In this error case, the driver should fall
- * back to using one general filter    (rather than specific) for all multicast
- * traffic. # When the SR-IOV is enabled, the HWRM needs to additionally track
- * source knockout per multicast group record. Examples of setting unicast
- * filters: For a unicast MAC based filter, one can use a combination of the
- * fields and masks provided in this command to set up the filter. Below are
- * some examples: # MAC + no VLAN filter: This filter is used to identify
- * traffic that does not contain any VLAN tags and matches destination (or
- * source) MAC address. This filter can be set up by setting only l2_addr field
- * to be a valid field. All other fields are not valid. The following value is
- * set for l2_addr. l2_addr = MAC # MAC + Any VLAN filter: This filter is used
- * to identify traffic that carries single VLAN tag and matches        (destination or
- * source) MAC address. This filter can be set up by setting only l2_addr and
- * l2_ovlan_mask fields to be valid fields. All other fields are not valid. The
- * following values are set for those two valid fields. l2_addr = MAC,
- * l2_ovlan_mask = 0xFFFF # MAC + no VLAN or VLAN ID=0: This filter is used to
- * identify untagged traffic that does not contain any VLAN tags or a VLAN tag
- * with VLAN ID = 0 and matches destination (or source) MAC address. This filter
- * can be set up by setting only l2_addr and l2_ovlan fields to be valid fields.
- * All other fields are not valid. The following value are set for l2_addr and
- * l2_ovlan. l2_addr = MAC, l2_ovlan = 0x0 # MAC + no VLAN or any VLAN: This
- * filter is used to identify traffic that contains zero or 1 VLAN tag and
- * matches destination (or source) MAC address. This filter can be set up by
- * setting only l2_addr, l2_ovlan, and l2_mask fields to be valid fields. All
- * other fields are not valid. The following value are set for l2_addr,
- * l2_ovlan, and l2_mask fields. l2_addr = MAC, l2_ovlan = 0x0, l2_ovlan_mask =
- * 0xFFFF # MAC + VLAN ID filter: This filter can be set up by setting only
- * l2_addr, l2_ovlan, and l2_ovlan_mask fields to be valid fields. All other
- * fields are not valid. The following values are set for those three valid
- * fields. l2_addr = MAC, l2_ovlan = VLAN ID, l2_ovlan_mask = 0xF000
+ * Description: This is a generic Exact Match  (EM) flow that uses fields from
+ * L4/L3/L2 headers. The EM flows apply to transmit and receive traffic. All
+ * L2/L3/L4 header fields are specified in network byte order. For each EM flow,
+ * there is an associated set of actions specified. For tunneled packets, all
+ * L2/L3/L4 fields specified are fields of inner headers unless otherwise
+ * specified. # If a field specified in this command is not enabled as a valid
+ * field, then that field shall not be used in matching packet header fields
+ * against this EM flow entry.
  */
-/* Input       (96 bytes) */
-struct hwrm_cfa_l2_filter_alloc_input {
+/* Input       (112 bytes) */
+struct hwrm_cfa_em_flow_alloc_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -7853,252 +10194,415 @@ struct hwrm_cfa_l2_filter_alloc_input {
         * enumeration is used for resources that are similar for both
         * TX and RX paths of the chip.
         */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_PATH       UINT32_C(0x1)
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_FLAGS_PATH UINT32_C(0x1)
        /* tx path */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_PATH_TX    \
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_FLAGS_PATH_TX      \
                (UINT32_C(0x0) << 0)
        /* rx path */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_PATH_RX    \
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_FLAGS_PATH_RX      \
                (UINT32_C(0x1) << 0)
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_PATH_LAST \
-               CFA_L2_FILTER_ALLOC_INPUT_FLAGS_PATH_RX
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_FLAGS_PATH_LAST \
+               CFA_EM_FLOW_ALLOC_INPUT_FLAGS_PATH_RX
        /*
-        * Setting of this flag indicates the applicability to the
-        * loopback path.
+        * Setting of this flag indicates enabling of a byte counter for
+        * a given flow.
         */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_LOOPBACK   UINT32_C(0x2)
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_FLAGS_BYTE_CTR     UINT32_C(0x2)
+       /*
+        * Setting of this flag indicates enabling of a packet counter
+        * for a given flow.
+        */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_FLAGS_PKT_CTR      UINT32_C(0x4)
+       /*
+        * Setting of this flag indicates de-capsulation action for the
+        * given flow.
+        */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_FLAGS_DECAP        UINT32_C(0x8)
+       /*
+        * Setting of this flag indicates encapsulation action for the
+        * given flow.
+        */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_FLAGS_ENCAP        UINT32_C(0x10)
        /*
         * Setting of this flag indicates drop action. If this flag is
         * not set, then it should be considered accept action.
         */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_DROP       UINT32_C(0x4)
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_FLAGS_DROP UINT32_C(0x20)
        /*
-        * If this flag is set, all t_l2_* fields are invalid and they
-        * should not be specified. If this flag is set, then l2_*
-        * fields refer to fields of outermost L2 header.
+        * Setting of this flag indicates that a meter is expected to be
+        * attached to this flow. This hint can be used when choosing
+        * the action record format required for the flow.
         */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_OUTERMOST UINT32_C(0x8)
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_FLAGS_METER        UINT32_C(0x40)
        uint32_t enables;
-       /* This bit must be '1' for the l2_addr field to be configured. */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_L2_ADDR UINT32_C(0x1)
-       /* This bit must be '1' for the l2_addr_mask field to be configured. */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_L2_ADDR_MASK     \
-               UINT32_C(0x2)
-       /* This bit must be '1' for the l2_ovlan field to be configured. */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_L2_OVLAN UINT32_C(0x4)
+       /* This bit must be '1' for the l2_filter_id field to be configured. */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_L2_FILTER_ID UINT32_C(0x1)
+       /* This bit must be '1' for the tunnel_type field to be configured. */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_TUNNEL_TYPE UINT32_C(0x2)
+       /* This bit must be '1' for the tunnel_id field to be configured. */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_TUNNEL_ID UINT32_C(0x4)
+       /* This bit must be '1' for the src_macaddr field to be configured. */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_SRC_MACADDR UINT32_C(0x8)
+       /* This bit must be '1' for the dst_macaddr field to be configured. */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_DST_MACADDR UINT32_C(0x10)
+       /* This bit must be '1' for the ovlan_vid field to be configured. */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_OVLAN_VID UINT32_C(0x20)
+       /* This bit must be '1' for the ivlan_vid field to be configured. */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_IVLAN_VID UINT32_C(0x40)
+       /* This bit must be '1' for the ethertype field to be configured. */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_ETHERTYPE UINT32_C(0x80)
+       /* This bit must be '1' for the src_ipaddr field to be configured. */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_SRC_IPADDR UINT32_C(0x100)
+       /* This bit must be '1' for the dst_ipaddr field to be configured. */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_DST_IPADDR UINT32_C(0x200)
+       /* This bit must be '1' for the ipaddr_type field to be configured. */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_IPADDR_TYPE UINT32_C(0x400)
+       /* This bit must be '1' for the ip_protocol field to be configured. */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_IP_PROTOCOL UINT32_C(0x800)
+       /* This bit must be '1' for the src_port field to be configured. */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_SRC_PORT UINT32_C(0x1000)
+       /* This bit must be '1' for the dst_port field to be configured. */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_DST_PORT UINT32_C(0x2000)
+       /* This bit must be '1' for the dst_id field to be configured. */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_DST_ID     UINT32_C(0x4000)
        /*
-        * This bit must be '1' for the l2_ovlan_mask field to be
+        * This bit must be '1' for the mirror_vnic_id field to be
         * configured.
         */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_L2_OVLAN_MASK     \
-               UINT32_C(0x8)
-       /* This bit must be '1' for the l2_ivlan field to be configured. */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_L2_IVLAN UINT32_C(0x10)
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_MIRROR_VNIC_ID     \
+               UINT32_C(0x8000)
        /*
-        * This bit must be '1' for the l2_ivlan_mask field to be
+        * This bit must be '1' for the encap_record_id field to be
         * configured.
         */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_L2_IVLAN_MASK     \
-               UINT32_C(0x20)
-       /* This bit must be '1' for the t_l2_addr field to be configured. */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_T_L2_ADDR UINT32_C(0x40)
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_ENCAP_RECORD_ID     \
+               UINT32_C(0x10000)
        /*
-        * This bit must be '1' for the t_l2_addr_mask field to be
+        * This bit must be '1' for the meter_instance_id field to be
         * configured.
         */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_T_L2_ADDR_MASK   \
-               UINT32_C(0x80)
-       /* This bit must be '1' for the t_l2_ovlan field to be configured. */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_T_L2_OVLAN       \
-               UINT32_C(0x100)
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_METER_INSTANCE_ID  \
+               UINT32_C(0x20000)
+       uint64_t l2_filter_id;
        /*
-        * This bit must be '1' for the t_l2_ovlan_mask field to be
-        * configured.
+        * This value identifies a set of CFA data structures used for
+        * an L2 context.
         */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_T_L2_OVLAN_MASK  \
-               UINT32_C(0x200)
-       /* This bit must be '1' for the t_l2_ivlan field to be configured. */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_T_L2_IVLAN       \
-               UINT32_C(0x400)
+       uint8_t tunnel_type;
+       /* Tunnel Type. */
+       /* Non-tunnel */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_TUNNEL_TYPE_NONTUNNEL \
+               UINT32_C(0x0)
+       /* Virtual eXtensible Local Area Network        (VXLAN) */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_TUNNEL_TYPE_VXLAN  UINT32_C(0x1)
        /*
-        * This bit must be '1' for the t_l2_ivlan_mask field to be
-        * configured.
+        * Network Virtualization Generic Routing
+        * Encapsulation        (NVGRE)
         */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_T_L2_IVLAN_MASK  \
-               UINT32_C(0x800)
-       /* This bit must be '1' for the src_type field to be configured. */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_SRC_TYPE UINT32_C(0x1000)
-       /* This bit must be '1' for the src_id field to be configured. */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_SRC_ID UINT32_C(0x2000)
-       /* This bit must be '1' for the tunnel_type field to be configured. */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_TUNNEL_TYPE      \
-               UINT32_C(0x4000)
-       /* This bit must be '1' for the dst_id field to be configured. */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_DST_ID UINT32_C(0x8000)
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_TUNNEL_TYPE_NVGRE  UINT32_C(0x2)
        /*
-        * This bit must be '1' for the mirror_vnic_id field to be
-        * configured.
+        * Generic Routing Encapsulation        (GRE) inside
+        * Ethernet payload
         */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_MIRROR_VNIC_ID   \
-               UINT32_C(0x10000)
-       uint8_t l2_addr[6];
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_TUNNEL_TYPE_L2GRE  UINT32_C(0x3)
+       /* IP in IP */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_TUNNEL_TYPE_IPIP   UINT32_C(0x4)
+       /* Generic Network Virtualization Encapsulation (Geneve) */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_TUNNEL_TYPE_GENEVE UINT32_C(0x5)
+       /* Multi-Protocol Lable Switching       (MPLS) */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_TUNNEL_TYPE_MPLS   UINT32_C(0x6)
+       /* Stateless Transport Tunnel   (STT) */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_TUNNEL_TYPE_STT    UINT32_C(0x7)
        /*
-        * This value sets the match value for the L2 MAC address.
-        * Destination MAC address for RX path. Source MAC address for
-        * TX path.
+        * Generic Routing Encapsulation        (GRE) inside IP
+        * datagram payload
+        */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_TUNNEL_TYPE_IPGRE  UINT32_C(0x8)
+       /*
+        * IPV4 over virtual eXtensible Local Area
+        * Network (IPV4oVXLAN)
+        */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_TUNNEL_TYPE_VXLAN_V4 UINT32_C(0x9)
+       /* Any tunneled traffic */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_TUNNEL_TYPE_ANYTUNNEL \
+               UINT32_C(0xff)
+       uint8_t unused_0;
+       uint16_t unused_1;
+       uint32_t tunnel_id;
+       /*
+        * Tunnel identifier. Virtual Network Identifier        (VNI). Only
+        * valid with tunnel_types VXLAN, NVGRE, and Geneve. Only lower
+        * 24-bits of VNI field are used in setting up the filter.
+        */
+       uint8_t src_macaddr[6];
+       /*
+        * This value indicates the source MAC address in the Ethernet
+        * header.
+        */
+       uint16_t meter_instance_id;
+       /* The meter instance to attach to the flow. */
+       /*
+        * A value of 0xfff is considered invalid and
+        * implies the instance is not configured.
+        */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_METER_INSTANCE_ID_INVALID   \
+               UINT32_C(0xffff)
+       uint8_t dst_macaddr[6];
+       /*
+        * This value indicates the destination MAC address in the
+        * Ethernet header.
+        */
+       uint16_t ovlan_vid;
+       /*
+        * This value indicates the VLAN ID of the outer VLAN tag in the
+        * Ethernet header.
+        */
+       uint16_t ivlan_vid;
+       /*
+        * This value indicates the VLAN ID of the inner VLAN tag in the
+        * Ethernet header.
+        */
+       uint16_t ethertype;
+       /* This value indicates the ethertype in the Ethernet header. */
+       uint8_t ip_addr_type;
+       /*
+        * This value indicates the type of IP address. 4 - IPv4 6 -
+        * IPv6 All others are invalid.
+        */
+       /* invalid */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_IP_ADDR_TYPE_UNKNOWN UINT32_C(0x0)
+       /* IPv4 */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_IP_ADDR_TYPE_IPV4  UINT32_C(0x4)
+       /* IPv6 */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_IP_ADDR_TYPE_IPV6  UINT32_C(0x6)
+       uint8_t ip_protocol;
+       /*
+        * The value of protocol filed in IP header. Applies to UDP and
+        * TCP traffic. 6 - TCP 17 - UDP
+        */
+       /* invalid */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_IP_PROTOCOL_UNKNOWN UINT32_C(0x0)
+       /* TCP */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_IP_PROTOCOL_TCP UINT32_C(0x6)
+       /* UDP */
+       #define HWRM_CFA_EM_FLOW_ALLOC_INPUT_IP_PROTOCOL_UDP UINT32_C(0x11)
+       uint8_t unused_2;
+       uint8_t unused_3;
+       uint32_t src_ipaddr[4];
+       /*
+        * The value of source IP address to be used in filtering. For
+        * IPv4, first four bytes represent the IP address.
+        */
+       uint32_t dst_ipaddr[4];
+       /*
+        * big_endian = True The value of destination IP address to be
+        * used in filtering. For IPv4, first four bytes represent the
+        * IP address.
+        */
+       uint16_t src_port;
+       /*
+        * The value of source port to be used in filtering. Applies to
+        * UDP and TCP traffic.
+        */
+       uint16_t dst_port;
+       /*
+        * The value of destination port to be used in filtering.
+        * Applies to UDP and TCP traffic.
+        */
+       uint16_t dst_id;
+       /*
+        * If set, this value shall represent the Logical VNIC ID of the
+        * destination VNIC for the RX path and network port id of the
+        * destination port for the TX path.
+        */
+       uint16_t mirror_vnic_id;
+       /* Logical VNIC ID of the VNIC where traffic is mirrored. */
+       uint32_t encap_record_id;
+       /* Logical ID of the encapsulation record. */
+       uint32_t unused_4;
+} __attribute__((packed));
+
+/* Output      (24 bytes) */
+struct hwrm_cfa_em_flow_alloc_output {
+       uint16_t error_code;
+       /*
+        * Pass/Fail or error type Note: receiver to verify the in
+        * parameters, and fail the call with an error when appropriate
+        */
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
+       /*
+        * This field is the length of the response in bytes. The last
+        * byte of the response is a valid flag that will read as '1'
+        * when the command has been completely written to memory.
+        */
+       uint64_t em_filter_id;
+       /* This value is an opaque id into CFA data structures. */
+       uint32_t flow_id;
+       /*
+        * This is the ID of the flow associated with this filter. This
+        * value shall be used to match and associate the flow
+        * identifier returned in completion records. A value of
+        * 0xFFFFFFFF shall indicate no flow id.
+        */
+       uint8_t unused_0;
+       uint8_t unused_1;
+       uint8_t unused_2;
+       uint8_t valid;
+       /*
+        * This field is used in Output records to indicate that the
+        * output is completely written to RAM. This field should be
+        * read as '1' to indicate that the output has been completely
+        * written. When writing a command completion or response to an
+        * internal processor, the order of writes has to be such that
+        * this field is written last.
+        */
+} __attribute__((packed));
+
+/* hwrm_cfa_em_flow_free */
+/* Description: Free an EM flow table entry */
+/* Input       (24 bytes) */
+struct hwrm_cfa_em_flow_free_input {
+       uint16_t req_type;
+       /*
+        * This value indicates what type of request this is. The format
+        * for the rest of the command is determined by this field.
+        */
+       uint16_t cmpl_ring;
+       /*
+        * This value indicates the what completion ring the request
+        * will be optionally completed on. If the value is -1, then no
+        * CR completion will be generated. Any other value must be a
+        * valid CR ring_id value for this function.
+        */
+       uint16_t seq_id;
+       /* This value indicates the command sequence number. */
+       uint16_t target_id;
+       /*
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function
+        * ids 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF
+        * - HWRM
         */
-       uint8_t unused_0;
-       uint8_t unused_1;
-       uint8_t l2_addr_mask[6];
+       uint64_t resp_addr;
        /*
-        * This value sets the mask value for the L2 address. A value of
-        * 0 will mask the corresponding bit from compare.
+        * This is the host address where the response will be written
+        * when the request is complete. This area must be 16B aligned
+        * and must be cleared to zero before the request is made.
         */
-       uint16_t l2_ovlan;
-       /* This value sets VLAN ID value for outer VLAN. */
-       uint16_t l2_ovlan_mask;
+       uint64_t em_filter_id;
+       /* This value is an opaque id into CFA data structures. */
+} __attribute__((packed));
+
+/* Output      (16 bytes) */
+struct hwrm_cfa_em_flow_free_output {
+       uint16_t error_code;
        /*
-        * This value sets the mask value for the ovlan id. A value of 0
-        * will mask the corresponding bit from compare.
+        * Pass/Fail or error type Note: receiver to verify the in
+        * parameters, and fail the call with an error when appropriate
         */
-       uint16_t l2_ivlan;
-       /* This value sets VLAN ID value for inner VLAN. */
-       uint16_t l2_ivlan_mask;
+       uint16_t req_type;
+       /* This field returns the type of original request. */
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
        /*
-        * This value sets the mask value for the ivlan id. A value of 0
-        * will mask the corresponding bit from compare.
+        * This field is the length of the response in bytes. The last
+        * byte of the response is a valid flag that will read as '1'
+        * when the command has been completely written to memory.
         */
+       uint32_t unused_0;
+       uint8_t unused_1;
        uint8_t unused_2;
        uint8_t unused_3;
-       uint8_t t_l2_addr[6];
+       uint8_t valid;
        /*
-        * This value sets the match value for the tunnel L2 MAC
-        * address. Destination MAC address for RX path. Source MAC
-        * address for TX path.
+        * This field is used in Output records to indicate that the
+        * output is completely written to RAM. This field should be
+        * read as '1' to indicate that the output has been completely
+        * written. When writing a command completion or response to an
+        * internal processor, the order of writes has to be such that
+        * this field is written last.
         */
-       uint8_t unused_4;
-       uint8_t unused_5;
-       uint8_t t_l2_addr_mask[6];
+} __attribute__((packed));
+
+/* hwrm_cfa_em_flow_cfg */
+/*
+ * Description: Configure an EM flow with a new destination VNIC and/or meter.
+ */
+/* Input       (48 bytes) */
+struct hwrm_cfa_em_flow_cfg_input {
+       uint16_t req_type;
        /*
-        * This value sets the mask value for the tunnel L2 address. A
-        * value of 0 will mask the corresponding bit from compare.
+        * This value indicates what type of request this is. The format
+        * for the rest of the command is determined by this field.
         */
-       uint16_t t_l2_ovlan;
-       /* This value sets VLAN ID value for tunnel outer VLAN. */
-       uint16_t t_l2_ovlan_mask;
+       uint16_t cmpl_ring;
        /*
-        * This value sets the mask value for the tunnel ovlan id. A
-        * value of 0 will mask the corresponding bit from compare.
+        * This value indicates the what completion ring the request
+        * will be optionally completed on. If the value is -1, then no
+        * CR completion will be generated. Any other value must be a
+        * valid CR ring_id value for this function.
         */
-       uint16_t t_l2_ivlan;
-       /* This value sets VLAN ID value for tunnel inner VLAN. */
-       uint16_t t_l2_ivlan_mask;
+       uint16_t seq_id;
+       /* This value indicates the command sequence number. */
+       uint16_t target_id;
        /*
-        * This value sets the mask value for the tunnel ivlan id. A
-        * value of 0 will mask the corresponding bit from compare.
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function
+        * ids 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF
+        * - HWRM
         */
-       uint8_t src_type;
-       /* This value identifies the type of source of the packet. */
-       /* Network port */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_SRC_TYPE_NPORT   UINT32_C(0x0)
-       /* Physical function */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_SRC_TYPE_PF      UINT32_C(0x1)
-       /* Virtual function */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_SRC_TYPE_VF      UINT32_C(0x2)
-       /* Virtual NIC of a function */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_SRC_TYPE_VNIC    UINT32_C(0x3)
-       /* Embedded processor for CFA management */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_SRC_TYPE_KONG    UINT32_C(0x4)
-       /* Embedded processor for OOB management */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_SRC_TYPE_APE     UINT32_C(0x5)
-       /* Embedded processor for RoCE */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_SRC_TYPE_BONO    UINT32_C(0x6)
-       /* Embedded processor for network proxy functions */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_SRC_TYPE_TANG    UINT32_C(0x7)
-       uint8_t unused_6;
-       uint32_t src_id;
+       uint64_t resp_addr;
        /*
-        * This value is the id of the source. For a network port, it
-        * represents port_id. For a physical function, it represents
-        * fid. For a virtual function, it represents vf_id. For a vnic,
-        * it represents vnic_id. For embedded processors, this id is
-        * not valid. Notes: 1. The function ID is implied if it src_id
-        * is not provided for a src_type that is either
+        * This is the host address where the response will be written
+        * when the request is complete. This area must be 16B aligned
+        * and must be cleared to zero before the request is made.
         */
-       uint8_t tunnel_type;
-       /* Tunnel Type. */
-       /* Non-tunnel */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_NONTUNNEL \
-               UINT32_C(0x0)
-       /* Virtual eXtensible Local Area Network        (VXLAN) */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_VXLAN \
-               UINT32_C(0x1)
+       uint32_t enables;
+       /* This bit must be '1' for the new_dst_id field to be configured. */
+       #define HWRM_CFA_EM_FLOW_CFG_INPUT_ENABLES_NEW_DST_ID   UINT32_C(0x1)
        /*
-        * Network Virtualization Generic Routing
-        * Encapsulation        (NVGRE)
+        * This bit must be '1' for the new_mirror_vnic_id field to be
+        * configured.
         */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_NVGRE \
+       #define HWRM_CFA_EM_FLOW_CFG_INPUT_ENABLES_NEW_MIRROR_VNIC_ID   \
                UINT32_C(0x2)
        /*
-        * Generic Routing Encapsulation        (GRE) inside
-        * Ethernet payload
-        */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_L2GRE UINT32_C(0x3)
-       /* IP in IP */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_IPIP UINT32_C(0x4)
-       /* Generic Network Virtualization Encapsulation (Geneve) */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_GENEVE UINT32_C(0x5)
-       /* Multi-Protocol Lable Switching       (MPLS) */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_MPLS UINT32_C(0x6)
-       /* Stateless Transport Tunnel   (STT) */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_STT  UINT32_C(0x7)
-       /*
-        * Generic Routing Encapsulation        (GRE) inside IP
-        * datagram payload
+        * This bit must be '1' for the new_meter_instance_id field to
+        * be configured.
         */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_IPGRE UINT32_C(0x8)
-       /* Any tunneled traffic */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_TUNNEL_TYPE_ANYTUNNEL \
-               UINT32_C(0xff)
-       uint8_t unused_7;
-       uint16_t dst_id;
+       #define HWRM_CFA_EM_FLOW_CFG_INPUT_ENABLES_NEW_METER_INSTANCE_ID  \
+               UINT32_C(0x4)
+       uint32_t unused_0;
+       uint64_t em_filter_id;
+       /* This value is an opaque id into CFA data structures. */
+       uint32_t new_dst_id;
        /*
-        * If set, this value shall represent the Logical VNIC ID of the
-        * destination VNIC for the RX path and network port id of the
-        * destination port for the TX path.
+        * If set, this value shall represent the new Logical VNIC ID of
+        * the destination VNIC for the RX path and network port id of
+        * the destination port for the TX path.
         */
-       uint16_t mirror_vnic_id;
-       /* Logical VNIC ID of the VNIC where traffic is mirrored. */
-       uint8_t pri_hint;
+       uint32_t new_mirror_vnic_id;
+       /* New Logical VNIC ID of the VNIC where traffic is mirrored. */
+       uint16_t new_meter_instance_id;
        /*
-        * This hint is provided to help in placing the filter in the
-        * filter table.
+        * New meter to attach to the flow. Specifying the invalid
+        * instance ID is used to remove any existing meter from the
+        * flow.
         */
-       /* No preference */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_PRI_HINT_NO_PREFER \
-               UINT32_C(0x0)
-       /* Above the given filter */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_PRI_HINT_ABOVE_FILTER \
-               UINT32_C(0x1)
-       /* Below the given filter */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_PRI_HINT_BELOW_FILTER \
-               UINT32_C(0x2)
-       /* As high as possible */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_PRI_HINT_MAX     UINT32_C(0x3)
-       /* As low as possible */
-       #define HWRM_CFA_L2_FILTER_ALLOC_INPUT_PRI_HINT_MIN     UINT32_C(0x4)
-       uint8_t unused_8;
-       uint32_t unused_9;
-       uint64_t l2_filter_id_hint;
        /*
-        * This is the ID of the filter that goes along with the
-        * pri_hint. This field is valid only for the following values.
-        * 1 - Above the given filter 2 - Below the given filter
+        * A value of 0xfff is considered invalid and
+        * implies the instance is not configured.
         */
+       #define HWRM_CFA_EM_FLOW_CFG_INPUT_NEW_METER_INSTANCE_ID_INVALID \
+               UINT32_C(0xffff)
+       uint16_t unused_1[3];
 } __attribute__((packed));
 
-/* Output      (24 bytes) */
-struct hwrm_cfa_l2_filter_alloc_output {
+/* Output      (16 bytes) */
+struct hwrm_cfa_em_flow_cfg_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -8114,21 +10618,10 @@ struct hwrm_cfa_l2_filter_alloc_output {
         * byte of the response is a valid flag that will read as '1'
         * when the command has been completely written to memory.
         */
-       uint64_t l2_filter_id;
-       /*
-        * This value identifies a set of CFA data structures used for
-        * an L2 context.
-        */
-       uint32_t flow_id;
-       /*
-        * This is the ID of the flow associated with this filter. This
-        * value shall be used to match and associate the flow
-        * identifier returned in completion records. A value of
-        * 0xFFFFFFFF shall indicate no flow id.
-        */
-       uint8_t unused_0;
+       uint32_t unused_0;
        uint8_t unused_1;
        uint8_t unused_2;
+       uint8_t unused_3;
        uint8_t valid;
        /*
         * This field is used in Output records to indicate that the
@@ -8140,13 +10633,13 @@ struct hwrm_cfa_l2_filter_alloc_output {
         */
 } __attribute__((packed));
 
-/* hwrm_cfa_l2_filter_free */
+/* hwrm_tunnel_dst_port_query */
 /*
- * Description: Free a L2 filter. The HWRM shall free all associated filter
- * resources with the L2 filter.
+ * Description: This function is called by a driver to query tunnel type
+ * specific destination port configuration.
  */
 /* Input       (24 bytes) */
-struct hwrm_cfa_l2_filter_free_input {
+struct hwrm_tunnel_dst_port_query_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -8173,15 +10666,25 @@ struct hwrm_cfa_l2_filter_free_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint64_t l2_filter_id;
+       uint8_t tunnel_type;
+       /* Tunnel Type. */
+       /* Virtual eXtensible Local Area Network        (VXLAN) */
+       #define HWRM_TUNNEL_DST_PORT_QUERY_INPUT_TUNNEL_TYPE_VXLAN \
+               UINT32_C(0x1)
+       /* Generic Network Virtualization Encapsulation (Geneve) */
+       #define HWRM_TUNNEL_DST_PORT_QUERY_INPUT_TUNNEL_TYPE_GENEVE \
+               UINT32_C(0x5)
        /*
-        * This value identifies a set of CFA data structures used for
-        * an L2 context.
+        * IPV4 over virtual eXtensible Local Area
+        * Network (IPV4oVXLAN)
         */
+       #define HWRM_TUNNEL_DST_PORT_QUERY_INPUT_TUNNEL_TYPE_VXLAN_V4 \
+               UINT32_C(0x9)
+       uint8_t unused_0[7];
 } __attribute__((packed));
 
 /* Output      (16 bytes) */
-struct hwrm_cfa_l2_filter_free_output {
+struct hwrm_tunnel_dst_port_query_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -8197,10 +10700,24 @@ struct hwrm_cfa_l2_filter_free_output {
         * byte of the response is a valid flag that will read as '1'
         * when the command has been completely written to memory.
         */
-       uint32_t unused_0;
+       uint16_t tunnel_dst_port_id;
+       /*
+        * This field represents the identifier of L4 destination port
+        * used for the given tunnel type. This field is valid for
+        * specific tunnel types that use layer 4       (e.g. UDP) transports
+        * for tunneling.
+        */
+       uint16_t tunnel_dst_port_val;
+       /*
+        * This field represents the value of L4 destination port
+        * identified by tunnel_dst_port_id. This field is valid for
+        * specific tunnel types that use layer 4       (e.g. UDP) transports
+        * for tunneling. This field is in network byte order. A value
+        * of 0 means that the destination port is not configured.
+        */
+       uint8_t unused_0;
        uint8_t unused_1;
        uint8_t unused_2;
-       uint8_t unused_3;
        uint8_t valid;
        /*
         * This field is used in Output records to indicate that the
@@ -8212,10 +10729,24 @@ struct hwrm_cfa_l2_filter_free_output {
         */
 } __attribute__((packed));
 
-/* hwrm_cfa_l2_filter_cfg */
-/* Description: Change the configuration of an existing L2 filter */
-/* Input       (40 bytes) */
-struct hwrm_cfa_l2_filter_cfg_input {
+/* hwrm_tunnel_dst_port_alloc */
+/*
+ * Description: This function is called by a driver to allocate l4 destination
+ * port for a specific tunnel type. The destination port value is provided in
+ * the input. If the HWRM supports only one global destination port for a tunnel
+ * type, then the HWRM shall keep track of its usage as described below. # The
+ * first caller that allocates a destination port shall always succeed and the
+ * HWRM shall save the destination port configuration for that tunnel type and
+ * increment the usage count to 1. # Subsequent callers allocating the same
+ * destination port for that tunnel type shall succeed and the HWRM shall
+ * increment the usage count for that port for each subsequent caller that
+ * succeeds. # Any subsequent caller trying to allocate a different destination
+ * port for that tunnel type shall fail until the usage count for the original
+ * destination port goes to zero. # A caller that frees a port will cause the
+ * usage count for that port to decrement.
+ */
+/* Input       (24 bytes) */
+struct hwrm_tunnel_dst_port_alloc_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -8242,52 +10773,33 @@ struct hwrm_cfa_l2_filter_cfg_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint32_t flags;
-       /*
-        * Enumeration denoting the RX, TX type of the resource. This
-        * enumeration is used for resources that are similar for both
-        * TX and RX paths of the chip.
-        */
-       #define HWRM_CFA_L2_FILTER_CFG_INPUT_FLAGS_PATH UINT32_C(0x1)
-       /* tx path */
-       #define HWRM_CFA_L2_FILTER_CFG_INPUT_FLAGS_PATH_TX \
-               (UINT32_C(0x0) << 0)
-       /* rx path */
-       #define HWRM_CFA_L2_FILTER_CFG_INPUT_FLAGS_PATH_RX \
-               (UINT32_C(0x1) << 0)
-       #define HWRM_CFA_L2_FILTER_CFG_INPUT_FLAGS_PATH_LAST \
-               CFA_L2_FILTER_CFG_INPUT_FLAGS_PATH_RX
-       /*
-        * Setting of this flag indicates drop action. If this flag is
-        * not set, then it should be considered accept action.
-        */
-       #define HWRM_CFA_L2_FILTER_CFG_INPUT_FLAGS_DROP UINT32_C(0x2)
-       uint32_t enables;
-       /* This bit must be '1' for the dst_id field to be configured. */
-       #define HWRM_CFA_L2_FILTER_CFG_INPUT_ENABLES_DST_ID     UINT32_C(0x1)
-       /*
-        * This bit must be '1' for the new_mirror_vnic_id field to be
-        * configured.
-        */
-       #define HWRM_CFA_L2_FILTER_CFG_INPUT_ENABLES_NEW_MIRROR_VNIC_ID   \
-               UINT32_C(0x2)
-       uint64_t l2_filter_id;
+       uint8_t tunnel_type;
+       /* Tunnel Type. */
+       /* Virtual eXtensible Local Area Network        (VXLAN) */
+       #define HWRM_TUNNEL_DST_PORT_ALLOC_INPUT_TUNNEL_TYPE_VXLAN UINT32_C(0x1)
+       /* Generic Network Virtualization Encapsulation (Geneve) */
+       #define HWRM_TUNNEL_DST_PORT_ALLOC_INPUT_TUNNEL_TYPE_GENEVE \
+               UINT32_C(0x5)
        /*
-        * This value identifies a set of CFA data structures used for
-        * an L2 context.
+        * IPV4 over virtual eXtensible Local Area
+        * Network (IPV4oVXLAN)
         */
-       uint32_t dst_id;
+       #define HWRM_TUNNEL_DST_PORT_ALLOC_INPUT_TUNNEL_TYPE_VXLAN_V4 \
+               UINT32_C(0x9)
+       uint8_t unused_0;
+       uint16_t tunnel_dst_port_val;
        /*
-        * If set, this value shall represent the Logical VNIC ID of the
-        * destination VNIC for the RX path and network port id of the
-        * destination port for the TX path.
+        * This field represents the value of L4 destination port used
+        * for the given tunnel type. This field is valid for specific
+        * tunnel types that use layer 4        (e.g. UDP) transports for
+        * tunneling. This field is in network byte order. A value of 0
+        * shall fail the command.
         */
-       uint32_t new_mirror_vnic_id;
-       /* New Logical VNIC ID of the VNIC where traffic is mirrored. */
+       uint32_t unused_1;
 } __attribute__((packed));
 
 /* Output      (16 bytes) */
-struct hwrm_cfa_l2_filter_cfg_output {
+struct hwrm_tunnel_dst_port_alloc_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -8303,10 +10815,17 @@ struct hwrm_cfa_l2_filter_cfg_output {
         * byte of the response is a valid flag that will read as '1'
         * when the command has been completely written to memory.
         */
-       uint32_t unused_0;
+       uint16_t tunnel_dst_port_id;
+       /*
+        * Identifier of a tunnel L4 destination port value. Only
+        * applies to tunnel types that has l4 destination port
+        * parameters.
+        */
+       uint8_t unused_0;
        uint8_t unused_1;
        uint8_t unused_2;
        uint8_t unused_3;
+       uint8_t unused_4;
        uint8_t valid;
        /*
         * This field is used in Output records to indicate that the
@@ -8318,10 +10837,13 @@ struct hwrm_cfa_l2_filter_cfg_output {
         */
 } __attribute__((packed));
 
-/* hwrm_cfa_l2_set_rx_mask */
-/* Description: This command will set rx mask of the function. */
-/* Input       (56 bytes) */
-struct hwrm_cfa_l2_set_rx_mask_input {
+/* hwrm_tunnel_dst_port_free */
+/*
+ * Description: This function is called by a driver to free l4 destination port
+ * for a specific tunnel type.
+ */
+/* Input       (24 bytes) */
+struct hwrm_tunnel_dst_port_free_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -8348,110 +10870,30 @@ struct hwrm_cfa_l2_set_rx_mask_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint32_t vnic_id;
-       /* VNIC ID */
-       uint32_t mask;
-       /* Reserved for future use. */
-       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_RESERVED     UINT32_C(0x1)
-       /*
-        * When this bit is '1', the function is requested to accept
-        * multi-cast packets specified by the multicast addr table.
-        */
-       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_MCAST        UINT32_C(0x2)
-       /*
-        * When this bit is '1', the function is requested to accept all
-        * multi-cast packets.
-        */
-       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_ALL_MCAST    UINT32_C(0x4)
-       /*
-        * When this bit is '1', the function is requested to accept
-        * broadcast packets.
-        */
-       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_BCAST        UINT32_C(0x8)
-       /*
-        * When this bit is '1', the function is requested to be put in
-        * the promiscuous mode. The HWRM should accept any function to
-        * set up promiscuous mode. The HWRM shall follow the semantics
-        * below for the promiscuous mode support. # When partitioning
-        * is not enabled on a port     (i.e. single PF on the port), then
-        * the PF shall be allowed to be in the promiscuous mode. When
-        * the PF is in the promiscuous mode, then it shall receive all
-        * host bound traffic on that port. # When partitioning is
-        * enabled on a port    (i.e. multiple PFs per port) and a PF on
-        * that port is in the promiscuous mode, then the PF receives
-        * all traffic within that partition as identified by a unique
-        * identifier for the PF        (e.g. S-Tag). If a unique outer VLAN
-        * for the PF is specified, then the setting of promiscuous mode
-        * on that PF shall result in the PF receiving all host bound
-        * traffic with matching outer VLAN. # A VF shall can be set in
-        * the promiscuous mode. In the promiscuous mode, the VF does
-        * not receive any traffic unless a unique outer VLAN for the VF
-        * is specified. If a unique outer VLAN for the VF is specified,
-        * then the setting of promiscuous mode on that VF shall result
-        * in the VF receiving all host bound traffic with the matching
-        * outer VLAN. # The HWRM shall allow the setting of promiscuous
-        * mode on a function independently from the promiscuous mode
-        * settings on other functions.
-        */
-       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_PROMISCUOUS UINT32_C(0x10)
-       /*
-        * If this flag is set, the corresponding RX filters shall be
-        * set up to cover multicast/broadcast filters for the outermost
-        * Layer 2 destination MAC address field.
-        */
-       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_OUTERMOST    UINT32_C(0x20)
-       /*
-        * If this flag is set, the corresponding RX filters shall be
-        * set up to cover multicast/broadcast filters for the VLAN-
-        * tagged packets that match the TPID and VID fields of VLAN
-        * tags in the VLAN tag table specified in this command.
-        */
-       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_VLANONLY     UINT32_C(0x40)
-       /*
-        * If this flag is set, the corresponding RX filters shall be
-        * set up to cover multicast/broadcast filters for non-VLAN
-        * tagged packets and VLAN-tagged packets that match the TPID
-        * and VID fields of VLAN tags in the VLAN tag table specified
-        * in this command.
-        */
-       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_VLAN_NONVLAN UINT32_C(0x80)
-       /*
-        * If this flag is set, the corresponding RX filters shall be
-        * set up to cover multicast/broadcast filters for non-VLAN
-        * tagged packets and VLAN-tagged packets matching any VLAN tag.
-        * If this flag is set, then the HWRM shall ignore VLAN tags
-        * specified in vlan_tag_tbl. If none of vlanonly, vlan_nonvlan,
-        * and anyvlan_nonvlan flags is set, then the HWRM shall ignore
-        * VLAN tags specified in vlan_tag_tbl. The HWRM client shall
-        * set at most one flag out of vlanonly, vlan_nonvlan, and
-        * anyvlan_nonvlan.
-        */
-       #define HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_ANYVLAN_NONVLAN      \
-               UINT32_C(0x100)
-       uint64_t mc_tbl_addr;
-       /* This is the address for mcast address tbl. */
-       uint32_t num_mc_entries;
-       /*
-        * This value indicates how many entries in mc_tbl are valid.
-        * Each entry is 6 bytes.
-        */
-       uint32_t unused_0;
-       uint64_t vlan_tag_tbl_addr;
+       uint8_t tunnel_type;
+       /* Tunnel Type. */
+       /* Virtual eXtensible Local Area Network        (VXLAN) */
+       #define HWRM_TUNNEL_DST_PORT_FREE_INPUT_TUNNEL_TYPE_VXLAN UINT32_C(0x1)
+       /* Generic Network Virtualization Encapsulation (Geneve) */
+       #define HWRM_TUNNEL_DST_PORT_FREE_INPUT_TUNNEL_TYPE_GENEVE UINT32_C(0x5)
        /*
-        * This is the address for VLAN tag table. Each VLAN entry in
-        * the table is 4 bytes of a VLAN tag including TPID, PCP, DEI,
-        * and VID fields in network byte order.
+        * IPV4 over virtual eXtensible Local Area
+        * Network (IPV4oVXLAN)
         */
-       uint32_t num_vlan_tags;
+       #define HWRM_TUNNEL_DST_PORT_FREE_INPUT_TUNNEL_TYPE_VXLAN_V4 \
+               UINT32_C(0x9)
+       uint8_t unused_0;
+       uint16_t tunnel_dst_port_id;
        /*
-        * This value indicates how many entries in vlan_tag_tbl are
-        * valid. Each entry is 4 bytes.
+        * Identifier of a tunnel L4 destination port value. Only
+        * applies to tunnel types that has l4 destination port
+        * parameters.
         */
        uint32_t unused_1;
 } __attribute__((packed));
 
 /* Output      (16 bytes) */
-struct hwrm_cfa_l2_set_rx_mask_output {
+struct hwrm_tunnel_dst_port_free_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -8482,13 +10924,13 @@ struct hwrm_cfa_l2_set_rx_mask_output {
         */
 } __attribute__((packed));
 
-/* hwrm_tunnel_dst_port_query */
+/* hwrm_stat_ctx_alloc */
 /*
- * Description: This function is called by a driver to query tunnel type
- * specific destination port configuration.
+ * Description: This command allocates and does basic preparation for a stat
+ * context.
  */
-/* Input       (24 bytes) */
-struct hwrm_tunnel_dst_port_query_input {
+/* Input       (32 bytes) */
+struct hwrm_stat_ctx_alloc_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -8515,19 +10957,35 @@ struct hwrm_tunnel_dst_port_query_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint8_t tunnel_type;
-       /* Tunnel Type. */
-       /* Virtual eXtensible Local Area Network        (VXLAN) */
-       #define HWRM_TUNNEL_DST_PORT_QUERY_INPUT_TUNNEL_TYPE_VXLAN \
-               UINT32_C(0x1)
-       /* Generic Network Virtualization Encapsulation (Geneve) */
-       #define HWRM_TUNNEL_DST_PORT_QUERY_INPUT_TUNNEL_TYPE_GENEVE \
-               UINT32_C(0x5)
-       uint8_t unused_0[7];
+       uint64_t stats_dma_addr;
+       /* This is the address for statistic block. */
+       uint32_t update_period_ms;
+       /*
+        * The statistic block update period in ms. e.g. 250ms, 500ms,
+        * 750ms, 1000ms. If update_period_ms is 0, then the stats
+        * update shall be never done and the DMA address shall not be
+        * used. In this case, the stat block can only be read by
+        * hwrm_stat_ctx_query command.
+        */
+       uint8_t stat_ctx_flags;
+       /*
+        * This field is used to specify statistics context specific
+        * configuration flags.
+        */
+       /*
+        * When this bit is set to '1', the statistics context shall be
+        * allocated for RoCE traffic only. In this case, traffic other
+        * than offloaded RoCE traffic shall not be included in this
+        * statistic context. When this bit is set to '0', the
+        * statistics context shall be used for the network traffic
+        * other than offloaded RoCE traffic.
+        */
+       #define HWRM_STAT_CTX_ALLOC_INPUT_STAT_CTX_FLAGS_ROCE   UINT32_C(0x1)
+       uint8_t unused_0[3];
 } __attribute__((packed));
 
 /* Output      (16 bytes) */
-struct hwrm_tunnel_dst_port_query_output {
+struct hwrm_stat_ctx_alloc_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -8535,29 +10993,16 @@ struct hwrm_tunnel_dst_port_query_output {
         */
        uint16_t req_type;
        /* This field returns the type of original request. */
-       uint16_t seq_id;
-       /* This field provides original sequence number of the command. */
-       uint16_t resp_len;
-       /*
-        * This field is the length of the response in bytes. The last
-        * byte of the response is a valid flag that will read as '1'
-        * when the command has been completely written to memory.
-        */
-       uint16_t tunnel_dst_port_id;
-       /*
-        * This field represents the identifier of L4 destination port
-        * used for the given tunnel type. This field is valid for
-        * specific tunnel types that use layer 4       (e.g. UDP) transports
-        * for tunneling.
-        */
-       uint16_t tunnel_dst_port_val;
-       /*
-        * This field represents the value of L4 destination port
-        * identified by tunnel_dst_port_id. This field is valid for
-        * specific tunnel types that use layer 4       (e.g. UDP) transports
-        * for tunneling. This field is in network byte order. A value
-        * of 0 means that the destination port is not configured.
+       uint16_t seq_id;
+       /* This field provides original sequence number of the command. */
+       uint16_t resp_len;
+       /*
+        * This field is the length of the response in bytes. The last
+        * byte of the response is a valid flag that will read as '1'
+        * when the command has been completely written to memory.
         */
+       uint32_t stat_ctx_id;
+       /* This is the statistics context ID value. */
        uint8_t unused_0;
        uint8_t unused_1;
        uint8_t unused_2;
@@ -8572,24 +11017,10 @@ struct hwrm_tunnel_dst_port_query_output {
         */
 } __attribute__((packed));
 
-/* hwrm_tunnel_dst_port_alloc */
-/*
- * Description: This function is called by a driver to allocate l4 destination
- * port for a specific tunnel type. The destination port value is provided in
- * the input. If the HWRM supports only one global destination port for a tunnel
- * type, then the HWRM shall keep track of its usage as described below. # The
- * first caller that allocates a destination port shall always succeed and the
- * HWRM shall save the destination port configuration for that tunnel type and
- * increment the usage count to 1. # Subsequent callers allocating the same
- * destination port for that tunnel type shall succeed and the HWRM shall
- * increment the usage count for that port for each subsequent caller that
- * succeeds. # Any subsequent caller trying to allocate a different destination
- * port for that tunnel type shall fail until the usage count for the original
- * destination port goes to zero. # A caller that frees a port will cause the
- * usage count for that port to decrement.
- */
+/* hwrm_stat_ctx_free */
+/* Description: This command is used to free a stat context. */
 /* Input       (24 bytes) */
-struct hwrm_tunnel_dst_port_alloc_input {
+struct hwrm_stat_ctx_free_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -8616,27 +11047,13 @@ struct hwrm_tunnel_dst_port_alloc_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint8_t tunnel_type;
-       /* Tunnel Type. */
-       /* Virtual eXtensible Local Area Network        (VXLAN) */
-       #define HWRM_TUNNEL_DST_PORT_ALLOC_INPUT_TUNNEL_TYPE_VXLAN UINT32_C(0x1)
-       /* Generic Network Virtualization Encapsulation (Geneve) */
-       #define HWRM_TUNNEL_DST_PORT_ALLOC_INPUT_TUNNEL_TYPE_GENEVE \
-               UINT32_C(0x5)
-       uint8_t unused_0;
-       uint16_t tunnel_dst_port_val;
-       /*
-        * This field represents the value of L4 destination port used
-        * for the given tunnel type. This field is valid for specific
-        * tunnel types that use layer 4        (e.g. UDP) transports for
-        * tunneling. This field is in network byte order. A value of 0
-        * shall fail the command.
-        */
-       uint32_t unused_1;
+       uint32_t stat_ctx_id;
+       /* ID of the statistics context that is being queried. */
+       uint32_t unused_0;
 } __attribute__((packed));
 
 /* Output      (16 bytes) */
-struct hwrm_tunnel_dst_port_alloc_output {
+struct hwrm_stat_ctx_free_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -8652,17 +11069,11 @@ struct hwrm_tunnel_dst_port_alloc_output {
         * byte of the response is a valid flag that will read as '1'
         * when the command has been completely written to memory.
         */
-       uint16_t tunnel_dst_port_id;
-       /*
-        * Identifier of a tunnel L4 destination port value. Only
-        * applies to tunnel types that has l4 destination port
-        * parameters.
-        */
+       uint32_t stat_ctx_id;
+       /* This is the statistics context ID value. */
        uint8_t unused_0;
        uint8_t unused_1;
        uint8_t unused_2;
-       uint8_t unused_3;
-       uint8_t unused_4;
        uint8_t valid;
        /*
         * This field is used in Output records to indicate that the
@@ -8674,61 +11085,46 @@ struct hwrm_tunnel_dst_port_alloc_output {
         */
 } __attribute__((packed));
 
-/* hwrm_tunnel_dst_port_free */
-/*
- * Description: This function is called by a driver to free l4 destination port
- * for a specific tunnel type.
- */
-/* Input       (24 bytes) */
-struct hwrm_tunnel_dst_port_free_input {
+/* hwrm_stat_ctx_query */
+/* Description: This command returns statistics of a context. */
+/* Input (24 bytes) */
+struct hwrm_stat_ctx_query_input {
        uint16_t req_type;
        /*
-        * This value indicates what type of request this is. The format
-        * for the rest of the command is determined by this field.
+        * This value indicates what type of request this is. The format for the
+        * rest of the command is determined by this field.
         */
        uint16_t cmpl_ring;
        /*
-        * This value indicates the what completion ring the request
-        * will be optionally completed on. If the value is -1, then no
-        * CR completion will be generated. Any other value must be a
-        * valid CR ring_id value for this function.
+        * This value indicates the what completion ring the request will be
+        * optionally completed on. If the value is -1, then no CR completion
+        * will be generated. Any other value must be a valid CR ring_id value
+        * for this function.
         */
        uint16_t seq_id;
        /* This value indicates the command sequence number. */
        uint16_t target_id;
        /*
-        * Target ID of this command. 0x0 - 0xFFF8 - Used for function
-        * ids 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF
-        * - HWRM
+        * Target ID of this command. 0x0 - 0xFFF8 - Used for function ids
+        * 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF - HWRM
         */
        uint64_t resp_addr;
        /*
-        * This is the host address where the response will be written
-        * when the request is complete. This area must be 16B aligned
-        * and must be cleared to zero before the request is made.
-        */
-       uint8_t tunnel_type;
-       /* Tunnel Type. */
-       /* Virtual eXtensible Local Area Network        (VXLAN) */
-       #define HWRM_TUNNEL_DST_PORT_FREE_INPUT_TUNNEL_TYPE_VXLAN UINT32_C(0x1)
-       /* Generic Network Virtualization Encapsulation (Geneve) */
-       #define HWRM_TUNNEL_DST_PORT_FREE_INPUT_TUNNEL_TYPE_GENEVE UINT32_C(0x5)
-       uint8_t unused_0;
-       uint16_t tunnel_dst_port_id;
-       /*
-        * Identifier of a tunnel L4 destination port value. Only
-        * applies to tunnel types that has l4 destination port
-        * parameters.
+        * This is the host address where the response will be written when the
+        * request is complete. This area must be 16B aligned and must be
+        * cleared to zero before the request is made.
         */
-       uint32_t unused_1;
+       uint32_t stat_ctx_id;
+       /* ID of the statistics context that is being queried. */
+       uint32_t unused_0;
 } __attribute__((packed));
 
-/* Output      (16 bytes) */
-struct hwrm_tunnel_dst_port_free_output {
+/* Output (176 bytes) */
+struct hwrm_stat_ctx_query_output {
        uint16_t error_code;
        /*
-        * Pass/Fail or error type Note: receiver to verify the in
-        * parameters, and fail the call with an error when appropriate
+        * Pass/Fail or error type Note: receiver to verify the in parameters,
+        * and fail the call with an error when appropriate
         */
        uint16_t req_type;
        /* This field returns the type of original request. */
@@ -8736,32 +11132,68 @@ struct hwrm_tunnel_dst_port_free_output {
        /* This field provides original sequence number of the command. */
        uint16_t resp_len;
        /*
-        * This field is the length of the response in bytes. The last
-        * byte of the response is a valid flag that will read as '1'
-        * when the command has been completely written to memory.
+        * This field is the length of the response in bytes. The last byte of
+        * the response is a valid flag that will read as '1' when the command
+        * has been completely written to memory.
         */
+       uint64_t tx_ucast_pkts;
+       /* Number of transmitted unicast packets */
+       uint64_t tx_mcast_pkts;
+       /* Number of transmitted multicast packets */
+       uint64_t tx_bcast_pkts;
+       /* Number of transmitted broadcast packets */
+       uint64_t tx_err_pkts;
+       /* Number of transmitted packets with error */
+       uint64_t tx_drop_pkts;
+       /* Number of dropped packets on transmit path */
+       uint64_t tx_ucast_bytes;
+       /* Number of transmitted bytes for unicast traffic */
+       uint64_t tx_mcast_bytes;
+       /* Number of transmitted bytes for multicast traffic */
+       uint64_t tx_bcast_bytes;
+       /* Number of transmitted bytes for broadcast traffic */
+       uint64_t rx_ucast_pkts;
+       /* Number of received unicast packets */
+       uint64_t rx_mcast_pkts;
+       /* Number of received multicast packets */
+       uint64_t rx_bcast_pkts;
+       /* Number of received broadcast packets */
+       uint64_t rx_err_pkts;
+       /* Number of received packets with error */
+       uint64_t rx_drop_pkts;
+       /* Number of dropped packets on received path */
+       uint64_t rx_ucast_bytes;
+       /* Number of received bytes for unicast traffic */
+       uint64_t rx_mcast_bytes;
+       /* Number of received bytes for multicast traffic */
+       uint64_t rx_bcast_bytes;
+       /* Number of received bytes for broadcast traffic */
+       uint64_t rx_agg_pkts;
+       /* Number of aggregated unicast packets */
+       uint64_t rx_agg_bytes;
+       /* Number of aggregated unicast bytes */
+       uint64_t rx_agg_events;
+       /* Number of aggregation events */
+       uint64_t rx_agg_aborts;
+       /* Number of aborted aggregations */
        uint32_t unused_0;
        uint8_t unused_1;
        uint8_t unused_2;
        uint8_t unused_3;
        uint8_t valid;
        /*
-        * This field is used in Output records to indicate that the
-        * output is completely written to RAM. This field should be
-        * read as '1' to indicate that the output has been completely
-        * written. When writing a command completion or response to an
-        * internal processor, the order of writes has to be such that
-        * this field is written last.
+        * This field is used in Output records to indicate that the output is
+        * completely written to RAM. This field should be read as '1' to
+        * indicate that the output has been completely written. When writing a
+        * command completion or response to an internal processor, the order of
+        * writes has to be such that this field is written last.
         */
 } __attribute__((packed));
 
-/* hwrm_stat_ctx_alloc */
-/*
- * Description: This command allocates and does basic preparation for a stat
- * context.
- */
-/* Input       (32 bytes) */
-struct hwrm_stat_ctx_alloc_input {
+/* hwrm_stat_ctx_clr_stats */
+/* Description: This command clears statistics of a context. */
+/* Input       (24 bytes) */
+struct hwrm_stat_ctx_clr_stats_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -8788,35 +11220,13 @@ struct hwrm_stat_ctx_alloc_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint64_t stats_dma_addr;
-       /* This is the address for statistic block. */
-       uint32_t update_period_ms;
-       /*
-        * The statistic block update period in ms. e.g. 250ms, 500ms,
-        * 750ms, 1000ms. If update_period_ms is 0, then the stats
-        * update shall be never done and the DMA address shall not be
-        * used. In this case, the stat block can only be read by
-        * hwrm_stat_ctx_query command.
-        */
-       uint8_t stat_ctx_flags;
-       /*
-        * This field is used to specify statistics context specific
-        * configuration flags.
-        */
-       /*
-        * When this bit is set to '1', the statistics context shall be
-        * allocated for RoCE traffic only. In this case, traffic other
-        * than offloaded RoCE traffic shall not be included in this
-        * statistic context. When this bit is set to '0', the
-        * statistics context shall be used for the network traffic
-        * other than offloaded RoCE traffic.
-        */
-       #define HWRM_STAT_CTX_ALLOC_INPUT_STAT_CTX_FLAGS_ROCE   UINT32_C(0x1)
-       uint8_t unused_0[3];
+       uint32_t stat_ctx_id;
+       /* ID of the statistics context that is being queried. */
+       uint32_t unused_0;
 } __attribute__((packed));
 
 /* Output      (16 bytes) */
-struct hwrm_stat_ctx_alloc_output {
+struct hwrm_stat_ctx_clr_stats_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -8832,11 +11242,10 @@ struct hwrm_stat_ctx_alloc_output {
         * byte of the response is a valid flag that will read as '1'
         * when the command has been completely written to memory.
         */
-       uint32_t stat_ctx_id;
-       /* This is the statistics context ID value. */
-       uint8_t unused_0;
+       uint32_t unused_0;
        uint8_t unused_1;
        uint8_t unused_2;
+       uint8_t unused_3;
        uint8_t valid;
        /*
         * This field is used in Output records to indicate that the
@@ -8848,10 +11257,18 @@ struct hwrm_stat_ctx_alloc_output {
         */
 } __attribute__((packed));
 
-/* hwrm_stat_ctx_free */
-/* Description: This command is used to free a stat context. */
-/* Input       (24 bytes) */
-struct hwrm_stat_ctx_free_input {
+/* hwrm_exec_fwd_resp */
+/*
+ * Description: This command is used to send an encapsulated request to the
+ * HWRM. This command instructs the HWRM to execute the request and forward the
+ * response of the encapsulated request to the location specified in the
+ * original request that is encapsulated. The target id of this command shall be
+ * set to 0xFFFF (HWRM). The response location in this command shall be used to
+ * acknowledge the receipt of the encapsulated request and forwarding of the
+ * response.
+ */
+/* Input       (128 bytes) */
+struct hwrm_exec_fwd_resp_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -8878,13 +11295,24 @@ struct hwrm_stat_ctx_free_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint32_t stat_ctx_id;
-       /* ID of the statistics context that is being queried. */
-       uint32_t unused_0;
+       uint32_t encap_request[26];
+       /*
+        * This is an encapsulated request. This request should be
+        * executed by the HWRM and the response should be provided in
+        * the response buffer inside the encapsulated request.
+        */
+       uint16_t encap_resp_target_id;
+       /*
+        * This value indicates the target id of the response to the
+        * encapsulated request. 0x0 - 0xFFF8 - Used for function ids
+        * 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF -
+        * HWRM
+        */
+       uint16_t unused_0[3];
 } __attribute__((packed));
 
 /* Output      (16 bytes) */
-struct hwrm_stat_ctx_free_output {
+struct hwrm_exec_fwd_resp_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -8900,11 +11328,10 @@ struct hwrm_stat_ctx_free_output {
         * byte of the response is a valid flag that will read as '1'
         * when the command has been completely written to memory.
         */
-       uint32_t stat_ctx_id;
-       /* This is the statistics context ID value. */
-       uint8_t unused_0;
+       uint32_t unused_0;
        uint8_t unused_1;
        uint8_t unused_2;
+       uint8_t unused_3;
        uint8_t valid;
        /*
         * This field is used in Output records to indicate that the
@@ -8916,10 +11343,18 @@ struct hwrm_stat_ctx_free_output {
         */
 } __attribute__((packed));
 
-/* hwrm_stat_ctx_clr_stats */
-/* Description: This command clears statistics of a context. */
-/* Input       (24 bytes) */
-struct hwrm_stat_ctx_clr_stats_input {
+/* hwrm_reject_fwd_resp */
+/*
+ * Description: This command is used to send an encapsulated request to the
+ * HWRM. This command instructs the HWRM to reject the request and forward the
+ * error response of the encapsulated request to the location specified in the
+ * original request that is encapsulated. The target id of this command shall be
+ * set to 0xFFFF (HWRM). The response location in this command shall be used to
+ * acknowledge the receipt of the encapsulated request and forwarding of the
+ * response.
+ */
+/* Input       (128 bytes) */
+struct hwrm_reject_fwd_resp_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -8946,13 +11381,25 @@ struct hwrm_stat_ctx_clr_stats_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint32_t stat_ctx_id;
-       /* ID of the statistics context that is being queried. */
-       uint32_t unused_0;
+       uint32_t encap_request[26];
+       /*
+        * This is an encapsulated request. This request should be
+        * rejected by the HWRM and the error response should be
+        * provided in the response buffer inside the encapsulated
+        * request.
+        */
+       uint16_t encap_resp_target_id;
+       /*
+        * This value indicates the target id of the response to the
+        * encapsulated request. 0x0 - 0xFFF8 - Used for function ids
+        * 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF -
+        * HWRM
+        */
+       uint16_t unused_0[3];
 } __attribute__((packed));
 
 /* Output      (16 bytes) */
-struct hwrm_stat_ctx_clr_stats_output {
+struct hwrm_reject_fwd_resp_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -8983,48 +11430,72 @@ struct hwrm_stat_ctx_clr_stats_output {
         */
 } __attribute__((packed));
 
-/* hwrm_stat_ctx_query */
-/* Description: This command returns statistics of a context. */
+/* hwrm_nvm_get_dir_entries */
 /* Input (24 bytes) */
-
-struct hwrm_stat_ctx_query_input {
+struct hwrm_nvm_get_dir_entries_input {
        uint16_t req_type;
-       /*
-        * This value indicates what type of request this is. The format for the
-        * rest of the command is determined by this field.
-        */
        uint16_t cmpl_ring;
-       /*
-        * This value indicates the what completion ring the request will be
-        * optionally completed on. If the value is -1, then no CR completion
-        * will be generated. Any other value must be a valid CR ring_id value
-        * for this function.
-        */
        uint16_t seq_id;
-       /* This value indicates the command sequence number. */
        uint16_t target_id;
-       /*
-        * Target ID of this command. 0x0 - 0xFFF8 - Used for function ids
-        * 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF - HWRM
-        */
        uint64_t resp_addr;
-       /*
-        * This is the host address where the response will be written when the
-        * request is complete. This area must be 16B aligned and must be
-        * cleared to zero before the request is made.
-        */
-       uint32_t stat_ctx_id;
-       /* ID of the statistics context that is being queried. */
+       uint64_t host_dest_addr;
+} __attribute__((packed));
+
+/* Output (16 bytes) */
+struct hwrm_nvm_get_dir_entries_output {
+       uint16_t error_code;
+       uint16_t req_type;
+       uint16_t seq_id;
+       uint16_t resp_len;
        uint32_t unused_0;
+       uint8_t unused_1;
+       uint8_t unused_2;
+       uint8_t unused_3;
+       uint8_t valid;
 } __attribute__((packed));
 
-/* Output (176 bytes) */
 
-struct hwrm_stat_ctx_query_output {
+/* hwrm_nvm_erase_dir_entry */
+/* Input (24 bytes) */
+struct hwrm_nvm_erase_dir_entry_input {
+       uint16_t req_type;
+       uint16_t cmpl_ring;
+       uint16_t seq_id;
+       uint16_t target_id;
+       uint64_t resp_addr;
+       uint16_t dir_idx;
+       uint16_t unused_0[3];
+};
+
+/* Output (16 bytes) */
+struct hwrm_nvm_erase_dir_entry_output {
+       uint16_t error_code;
+       uint16_t req_type;
+       uint16_t seq_id;
+       uint16_t resp_len;
+       uint32_t unused_0;
+       uint8_t unused_1;
+       uint8_t unused_2;
+       uint8_t unused_3;
+       uint8_t valid;
+};
+
+/* hwrm_nvm_get_dir_info */
+/* Input (16 bytes) */
+struct hwrm_nvm_get_dir_info_input {
+       uint16_t req_type;
+       uint16_t cmpl_ring;
+       uint16_t seq_id;
+       uint16_t target_id;
+       uint64_t resp_addr;
+} __attribute__((packed));
+
+/* Output (24 bytes) */
+struct hwrm_nvm_get_dir_info_output {
        uint16_t error_code;
        /*
-        * Pass/Fail or error type Note: receiver to verify the in parameters,
-        * and fail the call with an error when appropriate
+        * Pass/Fail or error type Note: receiver to verify the in
+        * parameters, and fail the call with an error when appropriate
         */
        uint16_t req_type;
        /* This field returns the type of original request. */
@@ -9032,76 +11503,36 @@ struct hwrm_stat_ctx_query_output {
        /* This field provides original sequence number of the command. */
        uint16_t resp_len;
        /*
-        * This field is the length of the response in bytes. The last byte of
-        * the response is a valid flag that will read as '1' when the command
-        * has been completely written to memory.
+        * This field is the length of the response in bytes. The last
+        * byte of the response is a valid flag that will read as '1'
+        * when the command has been completely written to memory.
         */
-       uint64_t tx_ucast_pkts;
-       /* Number of transmitted unicast packets */
-       uint64_t tx_mcast_pkts;
-       /* Number of transmitted multicast packets */
-       uint64_t tx_bcast_pkts;
-       /* Number of transmitted broadcast packets */
-       uint64_t tx_err_pkts;
-       /* Number of transmitted packets with error */
-       uint64_t tx_drop_pkts;
-       /* Number of dropped packets on transmit path */
-       uint64_t tx_ucast_bytes;
-       /* Number of transmitted bytes for unicast traffic */
-       uint64_t tx_mcast_bytes;
-       /* Number of transmitted bytes for multicast traffic */
-       uint64_t tx_bcast_bytes;
-       /* Number of transmitted bytes for broadcast traffic */
-       uint64_t rx_ucast_pkts;
-       /* Number of received unicast packets */
-       uint64_t rx_mcast_pkts;
-       /* Number of received multicast packets */
-       uint64_t rx_bcast_pkts;
-       /* Number of received broadcast packets */
-       uint64_t rx_err_pkts;
-       /* Number of received packets with error */
-       uint64_t rx_drop_pkts;
-       /* Number of dropped packets on received path */
-       uint64_t rx_ucast_bytes;
-       /* Number of received bytes for unicast traffic */
-       uint64_t rx_mcast_bytes;
-       /* Number of received bytes for multicast traffic */
-       uint64_t rx_bcast_bytes;
-       /* Number of received bytes for broadcast traffic */
-       uint64_t rx_agg_pkts;
-       /* Number of aggregated unicast packets */
-       uint64_t rx_agg_bytes;
-       /* Number of aggregated unicast bytes */
-       uint64_t rx_agg_events;
-       /* Number of aggregation events */
-       uint64_t rx_agg_aborts;
-       /* Number of aborted aggregations */
+       uint32_t entries;
+       /* Number of directory entries in the directory. */
+       uint32_t entry_length;
+       /* Size of each directory entry, in bytes. */
        uint32_t unused_0;
        uint8_t unused_1;
        uint8_t unused_2;
        uint8_t unused_3;
        uint8_t valid;
        /*
-        * This field is used in Output records to indicate that the output is
-        * completely written to RAM. This field should be read as '1' to
-        * indicate that the output has been completely written. When writing a
-        * command completion or response to an internal processor, the order of
-        * writes has to be such that this field is written last.
+        * This field is used in Output records to indicate that the
+        * output is completely written to RAM. This field should be
+        * read as '1' to indicate that the output has been completely
+        * written. When writing a command completion or response to an
+        * internal processor, the order of writes has to be such that
+        * this field is written last.
         */
 } __attribute__((packed));
 
-/* hwrm_exec_fwd_resp */
+/* hwrm_nvm_write */
 /*
- * Description: This command is used to send an encapsulated request to the
- * HWRM. This command instructs the HWRM to execute the request and forward the
- * response of the encapsulated request to the location specified in the
- * original request that is encapsulated. The target id of this command shall be
- * set to 0xFFFF (HWRM). The response location in this command shall be used to
- * acknowledge the receipt of the encapsulated request and forwarding of the
- * response.
+ * Note: Write to the allocated NVRAM of an item referenced by an existing
+ * directory entry.
  */
-/* Input       (128 bytes) */
-struct hwrm_exec_fwd_resp_input {
+/* Input (48 bytes) */
+struct hwrm_nvm_write_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -9128,24 +11559,63 @@ struct hwrm_exec_fwd_resp_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint32_t encap_request[26];
+       uint64_t host_src_addr;
+       /* 64-bit Host Source Address. This is where the source data is. */
+       uint16_t dir_type;
        /*
-        * This is an encapsulated request. This request should be
-        * executed by the HWRM and the response should be provided in
-        * the response buffer inside the encapsulated request.
+        * The Directory Entry Type (valid values are defined in the
+        * bnxnvm_directory_type enum defined in the file
+        * bnxnvm_defs.h).
         */
-       uint16_t encap_resp_target_id;
+       uint16_t dir_ordinal;
        /*
-        * This value indicates the target id of the response to the
-        * encapsulated request. 0x0 - 0xFFF8 - Used for function ids
-        * 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF -
-        * HWRM
+        * Directory ordinal. The 0-based instance of the combined
+        * Directory Entry Type and Extension.
         */
-       uint16_t unused_0[3];
+       uint16_t dir_ext;
+       /*
+        * The Directory Entry Extension flags (see BNX_DIR_EXT_* in the
+        * file bnxnvm_defs.h).
+        */
+       uint16_t dir_attr;
+       /*
+        * Directory Entry Attribute flags (see BNX_DIR_ATTR_* in the
+        * file bnxnvm_defs.h).
+        */
+       uint32_t dir_data_length;
+       /*
+        * Length of data to write, in bytes. May be less than or equal
+        * to the allocated size for the directory entry. The data
+        * length stored in the directory entry will be updated to
+        * reflect this value once the write is complete.
+        */
+       uint16_t option;
+       /* Option. */
+       uint16_t flags;
+       /*
+        * When this bit is '1', the original active image will not be
+        * removed. TBD: what purpose is this?
+        */
+       #define HWRM_NVM_WRITE_INPUT_FLAGS_KEEP_ORIG_ACTIVE_IMG UINT32_C(0x1)
+       uint32_t dir_item_length;
+       /*
+        * The requested length of the allocated NVM for the item, in
+        * bytes. This value may be greater than or equal to the
+        * specified data length (dir_data_length). If this value is
+        * less than the specified data length, it will be ignored. The
+        * response will contain the actual allocated item length, which
+        * may be greater than the requested item length. The purpose
+        * for allocating more than the required number of bytes for an
+        * item's data is to pre-allocate extra storage (padding) to
+        * accommodate the potential future growth of an item (e.g.
+        * upgraded firmware with a size increase, log growth, expanded
+        * configuration data).
+        */
+       uint32_t unused_0;
 } __attribute__((packed));
 
-/* Output      (16 bytes) */
-struct hwrm_exec_fwd_resp_output {
+/* Output (16 bytes) */
+struct hwrm_nvm_write_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -9161,10 +11631,17 @@ struct hwrm_exec_fwd_resp_output {
         * byte of the response is a valid flag that will read as '1'
         * when the command has been completely written to memory.
         */
-       uint32_t unused_0;
-       uint8_t unused_1;
-       uint8_t unused_2;
-       uint8_t unused_3;
+       uint32_t dir_item_length;
+       /*
+        * Length of the allocated NVM for the item, in bytes. The value
+        * may be greater than or equal to the specified data length or
+        * the requested item length. The actual item length used when
+        * creating a new directory entry will be a multiple of an NVM
+        * block size.
+        */
+       uint16_t dir_idx;
+       /* The directory index of the created or modified item. */
+       uint8_t unused_0;
        uint8_t valid;
        /*
         * This field is used in Output records to indicate that the
@@ -9176,18 +11653,13 @@ struct hwrm_exec_fwd_resp_output {
         */
 } __attribute__((packed));
 
-/* hwrm_reject_fwd_resp */
+/* hwrm_nvm_read */
 /*
- * Description: This command is used to send an encapsulated request to the
- * HWRM. This command instructs the HWRM to reject the request and forward the
- * error response of the encapsulated request to the location specified in the
- * original request that is encapsulated. The target id of this command shall be
- * set to 0xFFFF (HWRM). The response location in this command shall be used to
- * acknowledge the receipt of the encapsulated request and forwarding of the
- * response.
+ * Note: Read the contents of an NVRAM item as referenced (indexed) by an
+ * existing directory entry.
  */
-/* Input       (128 bytes) */
-struct hwrm_reject_fwd_resp_input {
+/* Input (40 bytes) */
+struct hwrm_nvm_read_input {
        uint16_t req_type;
        /*
         * This value indicates what type of request this is. The format
@@ -9214,25 +11686,24 @@ struct hwrm_reject_fwd_resp_input {
         * when the request is complete. This area must be 16B aligned
         * and must be cleared to zero before the request is made.
         */
-       uint32_t encap_request[26];
-       /*
-        * This is an encapsulated request. This request should be
-        * rejected by the HWRM and the error response should be
-        * provided in the response buffer inside the encapsulated
-        * request.
-        */
-       uint16_t encap_resp_target_id;
+       uint64_t host_dest_addr;
        /*
-        * This value indicates the target id of the response to the
-        * encapsulated request. 0x0 - 0xFFF8 - Used for function ids
-        * 0xFFF8 - 0xFFFE - Reserved for internal processors 0xFFFF -
-        * HWRM
+        * 64-bit Host Destination Address. This is the host address
+        * where the data will be written to.
         */
-       uint16_t unused_0[3];
+       uint16_t dir_idx;
+       /* The 0-based index of the directory entry. */
+       uint8_t unused_0;
+       uint8_t unused_1;
+       uint32_t offset;
+       /* The NVRAM byte-offset to read from. */
+       uint32_t len;
+       /* The length of the data to be read, in bytes. */
+       uint32_t unused_2;
 } __attribute__((packed));
 
-/* Output      (16 bytes) */
-struct hwrm_reject_fwd_resp_output {
+/* Output (16 bytes) */
+struct hwrm_nvm_read_output {
        uint16_t error_code;
        /*
         * Pass/Fail or error type Note: receiver to verify the in
@@ -9320,6 +11791,33 @@ struct output {
         */
 } __attribute__((packed));
 
+/* Short Command Structure (16 bytes) */
+struct hwrm_short_input {
+       uint16_t req_type;
+       /*
+        * This field indicates the type of request in the request
+        * buffer. The format for the rest of the command (request) is
+        * determined by this field.
+        */
+       uint16_t signature;
+       /*
+        * This field indicates a signature that is used to identify
+        * short form of the command listed here. This field shall be
+        * set to 17185 (0x4321).
+        */
+       /* Signature indicating this is a short form of HWRM command */
+       #define HWRM_SHORT_REQ_SIGNATURE_SHORT_CMD UINT32_C(0x4321)
+       uint16_t unused_0;
+       /* Reserved for future use. */
+       uint16_t size;
+       /* This value indicates the length of the request. */
+       uint64_t req_addr;
+       /*
+        * This is the host address where the request was written. This
+        * area must be 16B aligned.
+        */
+} __attribute__((packed));
+
 #define HWRM_GET_HWRM_ERROR_CODE(arg) \
        { \
                typeof(arg) x = (arg); \