mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-16 16:46:43 +07:00
qed*: Utilize FW 8.33.11.0
This FW contains several fixes and features RDMA Features - SRQ support - XRC support - Memory window support - RDMA low latency queue support - RDMA bonding support RDMA bug fixes - RDMA remote invalidate during retransmit fix - iWARP MPA connect interop issue with RTR fix - iWARP Legacy DPM support - Fix MPA reject flow - iWARP error handling - RQ WQE validation checks MISC - Fix some HSI types endianity - New Restriction: vlan insertion in core_tx_bd_data can't be set for LB packets ETH - HW QoS offload support - Fix vlan, dcb and sriov flow of VF sending a packet with inband VLAN tag instead of default VLAN - Allow GRE version 1 offloads in RX flow - Allow VXLAN steering iSCSI / FcoE - Fix bd availability checking flow - Support 256th sge proerly in iscsi/fcoe retransmit - Performance improvement - Fix handle iSCSI command arrival with AHS and with immediate - Fix ipv6 traffic class configuration DEBUG - Update debug utilities Signed-off-by: Michal Kalderon <Michal.Kalderon@cavium.com> Signed-off-by: Tomer Tayar <Tomer.Tayar@cavium.com> Signed-off-by: Manish Rangankar <Manish.Rangankar@cavium.com> Signed-off-by: Ariel Elior <Ariel.Elior@cavium.com> Acked-by: Jason Gunthorpe <jgg@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
18dcbe12fe
commit
50bc60cb15
@ -45,7 +45,7 @@ struct rdma_cqe_responder {
|
||||
__le32 imm_data_or_inv_r_Key;
|
||||
__le32 length;
|
||||
__le32 imm_data_hi;
|
||||
__le16 rq_cons;
|
||||
__le16 rq_cons_or_srq_id;
|
||||
u8 flags;
|
||||
#define RDMA_CQE_RESPONDER_TOGGLE_BIT_MASK 0x1
|
||||
#define RDMA_CQE_RESPONDER_TOGGLE_BIT_SHIFT 0
|
||||
@ -115,6 +115,7 @@ enum rdma_cqe_requester_status_enum {
|
||||
RDMA_CQE_REQ_STS_RNR_NAK_RETRY_CNT_ERR,
|
||||
RDMA_CQE_REQ_STS_TRANSPORT_RETRY_CNT_ERR,
|
||||
RDMA_CQE_REQ_STS_WORK_REQUEST_FLUSHED_ERR,
|
||||
RDMA_CQE_REQ_STS_XRC_VOILATION_ERR,
|
||||
MAX_RDMA_CQE_REQUESTER_STATUS_ENUM
|
||||
};
|
||||
|
||||
@ -136,6 +137,7 @@ enum rdma_cqe_type {
|
||||
RDMA_CQE_TYPE_REQUESTER,
|
||||
RDMA_CQE_TYPE_RESPONDER_RQ,
|
||||
RDMA_CQE_TYPE_RESPONDER_SRQ,
|
||||
RDMA_CQE_TYPE_RESPONDER_XRC_SRQ,
|
||||
RDMA_CQE_TYPE_INVALID,
|
||||
MAX_RDMA_CQE_TYPE
|
||||
};
|
||||
|
@ -3695,7 +3695,7 @@ static int process_resp_flush(struct qedr_qp *qp, struct qedr_cq *cq,
|
||||
static void try_consume_resp_cqe(struct qedr_cq *cq, struct qedr_qp *qp,
|
||||
struct rdma_cqe_responder *resp, int *update)
|
||||
{
|
||||
if (le16_to_cpu(resp->rq_cons) == qp->rq.wqe_cons) {
|
||||
if (le16_to_cpu(resp->rq_cons_or_srq_id) == qp->rq.wqe_cons) {
|
||||
consume_cqe(cq);
|
||||
*update |= 1;
|
||||
}
|
||||
@ -3710,7 +3710,7 @@ static int qedr_poll_cq_resp(struct qedr_dev *dev, struct qedr_qp *qp,
|
||||
|
||||
if (resp->status == RDMA_CQE_RESP_STS_WORK_REQUEST_FLUSHED_ERR) {
|
||||
cnt = process_resp_flush(qp, cq, num_entries, wc,
|
||||
resp->rq_cons);
|
||||
resp->rq_cons_or_srq_id);
|
||||
try_consume_resp_cqe(cq, qp, resp, update);
|
||||
} else {
|
||||
cnt = process_resp_one(dev, qp, cq, wc, resp);
|
||||
|
@ -265,6 +265,7 @@ struct grc_param_defs {
|
||||
u32 min;
|
||||
u32 max;
|
||||
bool is_preset;
|
||||
bool is_persistent;
|
||||
u32 exclude_all_preset_val;
|
||||
u32 crash_preset_val;
|
||||
};
|
||||
@ -1520,129 +1521,129 @@ static struct platform_defs s_platform_defs[] = {
|
||||
|
||||
static struct grc_param_defs s_grc_param_defs[] = {
|
||||
/* DBG_GRC_PARAM_DUMP_TSTORM */
|
||||
{{1, 1, 1}, 0, 1, false, 1, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 1, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_MSTORM */
|
||||
{{1, 1, 1}, 0, 1, false, 1, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 1, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_USTORM */
|
||||
{{1, 1, 1}, 0, 1, false, 1, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 1, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_XSTORM */
|
||||
{{1, 1, 1}, 0, 1, false, 1, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 1, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_YSTORM */
|
||||
{{1, 1, 1}, 0, 1, false, 1, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 1, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_PSTORM */
|
||||
{{1, 1, 1}, 0, 1, false, 1, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 1, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_REGS */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_RAM */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_PBUF */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_IOR */
|
||||
{{0, 0, 0}, 0, 1, false, 0, 1},
|
||||
{{0, 0, 0}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_VFC */
|
||||
{{0, 0, 0}, 0, 1, false, 0, 1},
|
||||
{{0, 0, 0}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_CM_CTX */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_ILT */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_RSS */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_CAU */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_QM */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_MCP */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_RESERVED */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
/* DBG_GRC_PARAM_MCP_TRACE_META_SIZE */
|
||||
{{1, 1, 1}, 1, 0xffffffff, false, true, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_CFC */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_IGU */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_BRB */
|
||||
{{0, 0, 0}, 0, 1, false, 0, 1},
|
||||
{{0, 0, 0}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_BTB */
|
||||
{{0, 0, 0}, 0, 1, false, 0, 1},
|
||||
{{0, 0, 0}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_BMB */
|
||||
{{0, 0, 0}, 0, 1, false, 0, 1},
|
||||
{{0, 0, 0}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_NIG */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_MULD */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_PRS */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_DMAE */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_TM */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_SDM */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_DIF */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_STATIC */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_UNSTALL */
|
||||
{{0, 0, 0}, 0, 1, false, 0, 0},
|
||||
{{0, 0, 0}, 0, 1, false, false, 0, 0},
|
||||
|
||||
/* DBG_GRC_PARAM_NUM_LCIDS */
|
||||
{{MAX_LCIDS, MAX_LCIDS, MAX_LCIDS}, 1, MAX_LCIDS, false, MAX_LCIDS,
|
||||
MAX_LCIDS},
|
||||
{{MAX_LCIDS, MAX_LCIDS, MAX_LCIDS}, 1, MAX_LCIDS, false, false,
|
||||
MAX_LCIDS, MAX_LCIDS},
|
||||
|
||||
/* DBG_GRC_PARAM_NUM_LTIDS */
|
||||
{{MAX_LTIDS, MAX_LTIDS, MAX_LTIDS}, 1, MAX_LTIDS, false, MAX_LTIDS,
|
||||
MAX_LTIDS},
|
||||
{{MAX_LTIDS, MAX_LTIDS, MAX_LTIDS}, 1, MAX_LTIDS, false, false,
|
||||
MAX_LTIDS, MAX_LTIDS},
|
||||
|
||||
/* DBG_GRC_PARAM_EXCLUDE_ALL */
|
||||
{{0, 0, 0}, 0, 1, true, 0, 0},
|
||||
{{0, 0, 0}, 0, 1, true, false, 0, 0},
|
||||
|
||||
/* DBG_GRC_PARAM_CRASH */
|
||||
{{0, 0, 0}, 0, 1, true, 0, 0},
|
||||
{{0, 0, 0}, 0, 1, true, false, 0, 0},
|
||||
|
||||
/* DBG_GRC_PARAM_PARITY_SAFE */
|
||||
{{0, 0, 0}, 0, 1, false, 1, 0},
|
||||
{{0, 0, 0}, 0, 1, false, false, 1, 0},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_CM */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_DUMP_PHY */
|
||||
{{1, 1, 1}, 0, 1, false, 0, 1},
|
||||
{{1, 1, 1}, 0, 1, false, false, 0, 1},
|
||||
|
||||
/* DBG_GRC_PARAM_NO_MCP */
|
||||
{{0, 0, 0}, 0, 1, false, 0, 0},
|
||||
{{0, 0, 0}, 0, 1, false, false, 0, 0},
|
||||
|
||||
/* DBG_GRC_PARAM_NO_FW_VER */
|
||||
{{0, 0, 0}, 0, 1, false, 0, 0}
|
||||
{{0, 0, 0}, 0, 1, false, false, 0, 0}
|
||||
};
|
||||
|
||||
static struct rss_mem_defs s_rss_mem_defs[] = {
|
||||
@ -4731,8 +4732,13 @@ static enum dbg_status qed_mcp_trace_dump(struct qed_hwfn *p_hwfn,
|
||||
offset += qed_dump_section_hdr(dump_buf + offset,
|
||||
dump, "mcp_trace_meta", 1);
|
||||
|
||||
/* Read trace meta info (trace_meta_size_bytes is dword-aligned) */
|
||||
if (mcp_access) {
|
||||
/* If MCP Trace meta size parameter was set, use it.
|
||||
* Otherwise, read trace meta.
|
||||
* trace_meta_size_bytes is dword-aligned.
|
||||
*/
|
||||
trace_meta_size_bytes =
|
||||
qed_grc_get_param(p_hwfn, DBG_GRC_PARAM_MCP_TRACE_META_SIZE);
|
||||
if ((!trace_meta_size_bytes || dump) && mcp_access) {
|
||||
status = qed_mcp_trace_get_meta_info(p_hwfn,
|
||||
p_ptt,
|
||||
trace_data_size_bytes,
|
||||
@ -5063,8 +5069,9 @@ void qed_dbg_grc_set_params_default(struct qed_hwfn *p_hwfn)
|
||||
u32 i;
|
||||
|
||||
for (i = 0; i < MAX_DBG_GRC_PARAMS; i++)
|
||||
dev_data->grc.param_val[i] =
|
||||
s_grc_param_defs[i].default_val[dev_data->chip_id];
|
||||
if (!s_grc_param_defs[i].is_persistent)
|
||||
dev_data->grc.param_val[i] =
|
||||
s_grc_param_defs[i].default_val[dev_data->chip_id];
|
||||
}
|
||||
|
||||
enum dbg_status qed_dbg_grc_get_dump_buf_size(struct qed_hwfn *p_hwfn,
|
||||
@ -6071,10 +6078,14 @@ static const struct igu_fifo_addr_data s_igu_fifo_addr_data[] = {
|
||||
|
||||
/******************************** Variables **********************************/
|
||||
|
||||
/* MCP Trace meta data - used in case the dump doesn't contain the meta data
|
||||
* (e.g. due to no NVRAM access).
|
||||
/* MCP Trace meta data array - used in case the dump doesn't contain the
|
||||
* meta data (e.g. due to no NVRAM access).
|
||||
*/
|
||||
static struct user_dbg_array s_mcp_trace_meta = { NULL, 0 };
|
||||
static struct user_dbg_array s_mcp_trace_meta_arr = { NULL, 0 };
|
||||
|
||||
/* Parsed MCP Trace meta data info, based on MCP trace meta array */
|
||||
static struct mcp_trace_meta s_mcp_trace_meta;
|
||||
static bool s_mcp_trace_meta_valid;
|
||||
|
||||
/* Temporary buffer, used for print size calculations */
|
||||
static char s_temp_buf[MAX_MSG_LEN];
|
||||
@ -6104,6 +6115,9 @@ static u32 qed_read_from_cyclic_buf(void *buf,
|
||||
|
||||
val_ptr = (u8 *)&val;
|
||||
|
||||
/* Assume running on a LITTLE ENDIAN and the buffer is network order
|
||||
* (BIG ENDIAN), as high order bytes are placed in lower memory address.
|
||||
*/
|
||||
for (i = 0; i < num_bytes_to_read; i++) {
|
||||
val_ptr[i] = bytes_buf[*offset];
|
||||
*offset = qed_cyclic_add(*offset, 1, buf_size);
|
||||
@ -6185,7 +6199,7 @@ static u32 qed_read_param(u32 *dump_buf,
|
||||
offset += 4;
|
||||
}
|
||||
|
||||
return offset / 4;
|
||||
return (u32)offset / 4;
|
||||
}
|
||||
|
||||
/* Reads a section header from the specified buffer.
|
||||
@ -6503,6 +6517,8 @@ static void qed_mcp_trace_free_meta(struct qed_hwfn *p_hwfn,
|
||||
{
|
||||
u32 i;
|
||||
|
||||
s_mcp_trace_meta_valid = false;
|
||||
|
||||
/* Release modules */
|
||||
if (meta->modules) {
|
||||
for (i = 0; i < meta->modules_num; i++)
|
||||
@ -6529,6 +6545,10 @@ static enum dbg_status qed_mcp_trace_alloc_meta(struct qed_hwfn *p_hwfn,
|
||||
u8 *meta_buf_bytes = (u8 *)meta_buf;
|
||||
u32 offset = 0, signature, i;
|
||||
|
||||
/* Free the previous meta before loading a new one. */
|
||||
if (s_mcp_trace_meta_valid)
|
||||
qed_mcp_trace_free_meta(p_hwfn, meta);
|
||||
|
||||
memset(meta, 0, sizeof(*meta));
|
||||
|
||||
/* Read first signature */
|
||||
@ -6594,31 +6614,153 @@ static enum dbg_status qed_mcp_trace_alloc_meta(struct qed_hwfn *p_hwfn,
|
||||
format_len, format_ptr->format_str);
|
||||
}
|
||||
|
||||
s_mcp_trace_meta_valid = true;
|
||||
return DBG_STATUS_OK;
|
||||
}
|
||||
|
||||
/* Parses an MCP trace buffer. If result_buf is not NULL, the MCP Trace results
|
||||
* are printed to it. The parsing status is returned.
|
||||
* Arguments:
|
||||
* trace_buf - MCP trace cyclic buffer
|
||||
* trace_buf_size - MCP trace cyclic buffer size in bytes
|
||||
* data_offset - offset in bytes of the data to parse in the MCP trace cyclic
|
||||
* buffer.
|
||||
* data_size - size in bytes of data to parse.
|
||||
* parsed_buf - destination buffer for parsed data.
|
||||
* parsed_bytes - size of parsed data in bytes.
|
||||
*/
|
||||
static enum dbg_status qed_parse_mcp_trace_buf(u8 *trace_buf,
|
||||
u32 trace_buf_size,
|
||||
u32 data_offset,
|
||||
u32 data_size,
|
||||
char *parsed_buf,
|
||||
u32 *parsed_bytes)
|
||||
{
|
||||
u32 param_mask, param_shift;
|
||||
enum dbg_status status;
|
||||
|
||||
*parsed_bytes = 0;
|
||||
|
||||
if (!s_mcp_trace_meta_valid)
|
||||
return DBG_STATUS_MCP_TRACE_BAD_DATA;
|
||||
|
||||
status = DBG_STATUS_OK;
|
||||
|
||||
while (data_size) {
|
||||
struct mcp_trace_format *format_ptr;
|
||||
u8 format_level, format_module;
|
||||
u32 params[3] = { 0, 0, 0 };
|
||||
u32 header, format_idx, i;
|
||||
|
||||
if (data_size < MFW_TRACE_ENTRY_SIZE)
|
||||
return DBG_STATUS_MCP_TRACE_BAD_DATA;
|
||||
|
||||
header = qed_read_from_cyclic_buf(trace_buf,
|
||||
&data_offset,
|
||||
trace_buf_size,
|
||||
MFW_TRACE_ENTRY_SIZE);
|
||||
data_size -= MFW_TRACE_ENTRY_SIZE;
|
||||
format_idx = header & MFW_TRACE_EVENTID_MASK;
|
||||
|
||||
/* Skip message if its index doesn't exist in the meta data */
|
||||
if (format_idx > s_mcp_trace_meta.formats_num) {
|
||||
u8 format_size =
|
||||
(u8)((header & MFW_TRACE_PRM_SIZE_MASK) >>
|
||||
MFW_TRACE_PRM_SIZE_SHIFT);
|
||||
|
||||
if (data_size < format_size)
|
||||
return DBG_STATUS_MCP_TRACE_BAD_DATA;
|
||||
|
||||
data_offset = qed_cyclic_add(data_offset,
|
||||
format_size,
|
||||
trace_buf_size);
|
||||
data_size -= format_size;
|
||||
continue;
|
||||
}
|
||||
|
||||
format_ptr = &s_mcp_trace_meta.formats[format_idx];
|
||||
|
||||
for (i = 0,
|
||||
param_mask = MCP_TRACE_FORMAT_P1_SIZE_MASK,
|
||||
param_shift = MCP_TRACE_FORMAT_P1_SIZE_SHIFT;
|
||||
i < MCP_TRACE_FORMAT_MAX_PARAMS;
|
||||
i++,
|
||||
param_mask <<= MCP_TRACE_FORMAT_PARAM_WIDTH,
|
||||
param_shift += MCP_TRACE_FORMAT_PARAM_WIDTH) {
|
||||
/* Extract param size (0..3) */
|
||||
u8 param_size = (u8)((format_ptr->data & param_mask) >>
|
||||
param_shift);
|
||||
|
||||
/* If the param size is zero, there are no other
|
||||
* parameters.
|
||||
*/
|
||||
if (!param_size)
|
||||
break;
|
||||
|
||||
/* Size is encoded using 2 bits, where 3 is used to
|
||||
* encode 4.
|
||||
*/
|
||||
if (param_size == 3)
|
||||
param_size = 4;
|
||||
|
||||
if (data_size < param_size)
|
||||
return DBG_STATUS_MCP_TRACE_BAD_DATA;
|
||||
|
||||
params[i] = qed_read_from_cyclic_buf(trace_buf,
|
||||
&data_offset,
|
||||
trace_buf_size,
|
||||
param_size);
|
||||
data_size -= param_size;
|
||||
}
|
||||
|
||||
format_level = (u8)((format_ptr->data &
|
||||
MCP_TRACE_FORMAT_LEVEL_MASK) >>
|
||||
MCP_TRACE_FORMAT_LEVEL_SHIFT);
|
||||
format_module = (u8)((format_ptr->data &
|
||||
MCP_TRACE_FORMAT_MODULE_MASK) >>
|
||||
MCP_TRACE_FORMAT_MODULE_SHIFT);
|
||||
if (format_level >= ARRAY_SIZE(s_mcp_trace_level_str))
|
||||
return DBG_STATUS_MCP_TRACE_BAD_DATA;
|
||||
|
||||
/* Print current message to results buffer */
|
||||
*parsed_bytes +=
|
||||
sprintf(qed_get_buf_ptr(parsed_buf, *parsed_bytes),
|
||||
"%s %-8s: ",
|
||||
s_mcp_trace_level_str[format_level],
|
||||
s_mcp_trace_meta.modules[format_module]);
|
||||
*parsed_bytes +=
|
||||
sprintf(qed_get_buf_ptr(parsed_buf, *parsed_bytes),
|
||||
format_ptr->format_str,
|
||||
params[0], params[1], params[2]);
|
||||
}
|
||||
|
||||
/* Add string NULL terminator */
|
||||
(*parsed_bytes)++;
|
||||
|
||||
return status;
|
||||
}
|
||||
|
||||
/* Parses an MCP Trace dump buffer.
|
||||
* If result_buf is not NULL, the MCP Trace results are printed to it.
|
||||
* In any case, the required results buffer size is assigned to
|
||||
* parsed_results_bytes.
|
||||
* parsed_bytes.
|
||||
* The parsing status is returned.
|
||||
*/
|
||||
static enum dbg_status qed_parse_mcp_trace_dump(struct qed_hwfn *p_hwfn,
|
||||
u32 *dump_buf,
|
||||
char *results_buf,
|
||||
u32 *parsed_results_bytes)
|
||||
char *parsed_buf,
|
||||
u32 *parsed_bytes)
|
||||
{
|
||||
u32 end_offset, bytes_left, trace_data_dwords, trace_meta_dwords;
|
||||
u32 param_mask, param_shift, param_num_val, num_section_params;
|
||||
const char *section_name, *param_name, *param_str_val;
|
||||
u32 offset, results_offset = 0;
|
||||
struct mcp_trace_meta meta;
|
||||
u32 data_size, trace_data_dwords, trace_meta_dwords;
|
||||
u32 offset, results_offset, parsed_buf_bytes;
|
||||
u32 param_num_val, num_section_params;
|
||||
struct mcp_trace *trace;
|
||||
enum dbg_status status;
|
||||
const u32 *meta_buf;
|
||||
u8 *trace_buf;
|
||||
|
||||
*parsed_results_bytes = 0;
|
||||
*parsed_bytes = 0;
|
||||
|
||||
/* Read global_params section */
|
||||
dump_buf += qed_read_section_hdr(dump_buf,
|
||||
@ -6629,7 +6771,7 @@ static enum dbg_status qed_parse_mcp_trace_dump(struct qed_hwfn *p_hwfn,
|
||||
/* Print global params */
|
||||
dump_buf += qed_print_section_params(dump_buf,
|
||||
num_section_params,
|
||||
results_buf, &results_offset);
|
||||
parsed_buf, &results_offset);
|
||||
|
||||
/* Read trace_data section */
|
||||
dump_buf += qed_read_section_hdr(dump_buf,
|
||||
@ -6646,8 +6788,7 @@ static enum dbg_status qed_parse_mcp_trace_dump(struct qed_hwfn *p_hwfn,
|
||||
trace = (struct mcp_trace *)dump_buf;
|
||||
trace_buf = (u8 *)dump_buf + sizeof(*trace);
|
||||
offset = trace->trace_oldest;
|
||||
end_offset = trace->trace_prod;
|
||||
bytes_left = qed_cyclic_sub(end_offset, offset, trace->size);
|
||||
data_size = qed_cyclic_sub(trace->trace_prod, offset, trace->size);
|
||||
dump_buf += trace_data_dwords;
|
||||
|
||||
/* Read meta_data section */
|
||||
@ -6664,126 +6805,33 @@ static enum dbg_status qed_parse_mcp_trace_dump(struct qed_hwfn *p_hwfn,
|
||||
/* Choose meta data buffer */
|
||||
if (!trace_meta_dwords) {
|
||||
/* Dump doesn't include meta data */
|
||||
if (!s_mcp_trace_meta.ptr)
|
||||
if (!s_mcp_trace_meta_arr.ptr)
|
||||
return DBG_STATUS_MCP_TRACE_NO_META;
|
||||
meta_buf = s_mcp_trace_meta.ptr;
|
||||
meta_buf = s_mcp_trace_meta_arr.ptr;
|
||||
} else {
|
||||
/* Dump includes meta data */
|
||||
meta_buf = dump_buf;
|
||||
}
|
||||
|
||||
/* Allocate meta data memory */
|
||||
status = qed_mcp_trace_alloc_meta(p_hwfn, meta_buf, &meta);
|
||||
status = qed_mcp_trace_alloc_meta(p_hwfn, meta_buf, &s_mcp_trace_meta);
|
||||
if (status != DBG_STATUS_OK)
|
||||
goto free_mem;
|
||||
return status;
|
||||
|
||||
/* Ignore the level and modules masks - just print everything that is
|
||||
* already in the buffer.
|
||||
*/
|
||||
while (bytes_left) {
|
||||
struct mcp_trace_format *format_ptr;
|
||||
u8 format_level, format_module;
|
||||
u32 params[3] = { 0, 0, 0 };
|
||||
u32 header, format_idx, i;
|
||||
status = qed_parse_mcp_trace_buf(trace_buf,
|
||||
trace->size,
|
||||
offset,
|
||||
data_size,
|
||||
parsed_buf ?
|
||||
parsed_buf + results_offset :
|
||||
NULL,
|
||||
&parsed_buf_bytes);
|
||||
if (status != DBG_STATUS_OK)
|
||||
return status;
|
||||
|
||||
if (bytes_left < MFW_TRACE_ENTRY_SIZE) {
|
||||
status = DBG_STATUS_MCP_TRACE_BAD_DATA;
|
||||
goto free_mem;
|
||||
}
|
||||
*parsed_bytes = results_offset + parsed_buf_bytes;
|
||||
|
||||
header = qed_read_from_cyclic_buf(trace_buf,
|
||||
&offset,
|
||||
trace->size,
|
||||
MFW_TRACE_ENTRY_SIZE);
|
||||
bytes_left -= MFW_TRACE_ENTRY_SIZE;
|
||||
format_idx = header & MFW_TRACE_EVENTID_MASK;
|
||||
|
||||
/* Skip message if its index doesn't exist in the meta data */
|
||||
if (format_idx > meta.formats_num) {
|
||||
u8 format_size =
|
||||
(u8)((header &
|
||||
MFW_TRACE_PRM_SIZE_MASK) >>
|
||||
MFW_TRACE_PRM_SIZE_SHIFT);
|
||||
|
||||
if (bytes_left < format_size) {
|
||||
status = DBG_STATUS_MCP_TRACE_BAD_DATA;
|
||||
goto free_mem;
|
||||
}
|
||||
|
||||
offset = qed_cyclic_add(offset,
|
||||
format_size, trace->size);
|
||||
bytes_left -= format_size;
|
||||
continue;
|
||||
}
|
||||
|
||||
format_ptr = &meta.formats[format_idx];
|
||||
|
||||
for (i = 0,
|
||||
param_mask = MCP_TRACE_FORMAT_P1_SIZE_MASK, param_shift =
|
||||
MCP_TRACE_FORMAT_P1_SIZE_SHIFT;
|
||||
i < MCP_TRACE_FORMAT_MAX_PARAMS;
|
||||
i++, param_mask <<= MCP_TRACE_FORMAT_PARAM_WIDTH,
|
||||
param_shift += MCP_TRACE_FORMAT_PARAM_WIDTH) {
|
||||
/* Extract param size (0..3) */
|
||||
u8 param_size =
|
||||
(u8)((format_ptr->data &
|
||||
param_mask) >> param_shift);
|
||||
|
||||
/* If the param size is zero, there are no other
|
||||
* parameters.
|
||||
*/
|
||||
if (!param_size)
|
||||
break;
|
||||
|
||||
/* Size is encoded using 2 bits, where 3 is used to
|
||||
* encode 4.
|
||||
*/
|
||||
if (param_size == 3)
|
||||
param_size = 4;
|
||||
|
||||
if (bytes_left < param_size) {
|
||||
status = DBG_STATUS_MCP_TRACE_BAD_DATA;
|
||||
goto free_mem;
|
||||
}
|
||||
|
||||
params[i] = qed_read_from_cyclic_buf(trace_buf,
|
||||
&offset,
|
||||
trace->size,
|
||||
param_size);
|
||||
|
||||
bytes_left -= param_size;
|
||||
}
|
||||
|
||||
format_level =
|
||||
(u8)((format_ptr->data &
|
||||
MCP_TRACE_FORMAT_LEVEL_MASK) >>
|
||||
MCP_TRACE_FORMAT_LEVEL_SHIFT);
|
||||
format_module =
|
||||
(u8)((format_ptr->data &
|
||||
MCP_TRACE_FORMAT_MODULE_MASK) >>
|
||||
MCP_TRACE_FORMAT_MODULE_SHIFT);
|
||||
if (format_level >= ARRAY_SIZE(s_mcp_trace_level_str)) {
|
||||
status = DBG_STATUS_MCP_TRACE_BAD_DATA;
|
||||
goto free_mem;
|
||||
}
|
||||
|
||||
/* Print current message to results buffer */
|
||||
results_offset +=
|
||||
sprintf(qed_get_buf_ptr(results_buf,
|
||||
results_offset), "%s %-8s: ",
|
||||
s_mcp_trace_level_str[format_level],
|
||||
meta.modules[format_module]);
|
||||
results_offset +=
|
||||
sprintf(qed_get_buf_ptr(results_buf,
|
||||
results_offset),
|
||||
format_ptr->format_str, params[0], params[1],
|
||||
params[2]);
|
||||
}
|
||||
|
||||
free_mem:
|
||||
*parsed_results_bytes = results_offset + 1;
|
||||
qed_mcp_trace_free_meta(p_hwfn, &meta);
|
||||
return status;
|
||||
return DBG_STATUS_OK;
|
||||
}
|
||||
|
||||
/* Parses a Reg FIFO dump buffer.
|
||||
@ -7291,8 +7339,8 @@ enum dbg_status qed_print_idle_chk_results(struct qed_hwfn *p_hwfn,
|
||||
|
||||
void qed_dbg_mcp_trace_set_meta_data(u32 *data, u32 size)
|
||||
{
|
||||
s_mcp_trace_meta.ptr = data;
|
||||
s_mcp_trace_meta.size_in_dwords = size;
|
||||
s_mcp_trace_meta_arr.ptr = data;
|
||||
s_mcp_trace_meta_arr.size_in_dwords = size;
|
||||
}
|
||||
|
||||
enum dbg_status qed_get_mcp_trace_results_buf_size(struct qed_hwfn *p_hwfn,
|
||||
@ -7316,6 +7364,19 @@ enum dbg_status qed_print_mcp_trace_results(struct qed_hwfn *p_hwfn,
|
||||
results_buf, &parsed_buf_size);
|
||||
}
|
||||
|
||||
enum dbg_status qed_print_mcp_trace_line(u8 *dump_buf,
|
||||
u32 num_dumped_bytes,
|
||||
char *results_buf)
|
||||
{
|
||||
u32 parsed_bytes;
|
||||
|
||||
return qed_parse_mcp_trace_buf(dump_buf,
|
||||
num_dumped_bytes,
|
||||
0,
|
||||
num_dumped_bytes,
|
||||
results_buf, &parsed_bytes);
|
||||
}
|
||||
|
||||
enum dbg_status qed_get_reg_fifo_results_buf_size(struct qed_hwfn *p_hwfn,
|
||||
u32 *dump_buf,
|
||||
u32 num_dumped_dwords,
|
||||
@ -7891,6 +7952,7 @@ int qed_dbg_all_data(struct qed_dev *cdev, void *buffer)
|
||||
}
|
||||
}
|
||||
|
||||
qed_set_debug_engine(cdev, org_engine);
|
||||
/* mcp_trace */
|
||||
rc = qed_dbg_mcp_trace(cdev, (u8 *)buffer + offset +
|
||||
REGDUMP_HEADER_SIZE, &feature_size);
|
||||
@ -7903,8 +7965,6 @@ int qed_dbg_all_data(struct qed_dev *cdev, void *buffer)
|
||||
DP_ERR(cdev, "qed_dbg_mcp_trace failed. rc = %d\n", rc);
|
||||
}
|
||||
|
||||
qed_set_debug_engine(cdev, org_engine);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -7929,9 +7989,10 @@ int qed_dbg_all_data_size(struct qed_dev *cdev)
|
||||
REGDUMP_HEADER_SIZE + qed_dbg_fw_asserts_size(cdev);
|
||||
}
|
||||
|
||||
qed_set_debug_engine(cdev, org_engine);
|
||||
|
||||
/* Engine common */
|
||||
regs_len += REGDUMP_HEADER_SIZE + qed_dbg_mcp_trace_size(cdev);
|
||||
qed_set_debug_engine(cdev, org_engine);
|
||||
|
||||
return regs_len;
|
||||
}
|
||||
|
@ -407,6 +407,7 @@ static void qed_init_qm_pq(struct qed_hwfn *p_hwfn,
|
||||
"pq overflow! pq %d, max pq %d\n", pq_idx, max_pq);
|
||||
|
||||
/* init pq params */
|
||||
qm_info->qm_pq_params[pq_idx].port_id = p_hwfn->port_id;
|
||||
qm_info->qm_pq_params[pq_idx].vport_id = qm_info->start_vport +
|
||||
qm_info->num_vports;
|
||||
qm_info->qm_pq_params[pq_idx].tc_id = tc;
|
||||
@ -727,8 +728,9 @@ static void qed_dp_init_qm_params(struct qed_hwfn *p_hwfn)
|
||||
pq = &(qm_info->qm_pq_params[i]);
|
||||
DP_VERBOSE(p_hwfn,
|
||||
NETIF_MSG_HW,
|
||||
"pq idx %d, vport_id %d, tc %d, wrr_grp %d, rl_valid %d\n",
|
||||
"pq idx %d, port %d, vport_id %d, tc %d, wrr_grp %d, rl_valid %d\n",
|
||||
qm_info->start_pq + i,
|
||||
pq->port_id,
|
||||
pq->vport_id,
|
||||
pq->tc_id, pq->wrr_group, pq->rl_valid);
|
||||
}
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -467,12 +467,11 @@ static void qed_tx_pq_map_rt_init(struct qed_hwfn *p_hwfn,
|
||||
u16 *p_first_tx_pq_id;
|
||||
|
||||
ext_voq = qed_get_ext_voq(p_hwfn,
|
||||
p_params->port_id,
|
||||
pq_params[i].port_id,
|
||||
tc_id,
|
||||
p_params->max_phys_tcs_per_port);
|
||||
is_vf_pq = (i >= p_params->num_pf_pqs);
|
||||
rl_valid = pq_params[i].rl_valid &&
|
||||
pq_params[i].vport_id < max_qm_global_rls;
|
||||
rl_valid = pq_params[i].rl_valid > 0;
|
||||
|
||||
/* Update first Tx PQ of VPORT/TC */
|
||||
vport_id_in_pf = pq_params[i].vport_id - p_params->start_vport;
|
||||
@ -494,10 +493,11 @@ static void qed_tx_pq_map_rt_init(struct qed_hwfn *p_hwfn,
|
||||
}
|
||||
|
||||
/* Check RL ID */
|
||||
if (pq_params[i].rl_valid && pq_params[i].vport_id >=
|
||||
max_qm_global_rls)
|
||||
if (rl_valid && pq_params[i].vport_id >= max_qm_global_rls) {
|
||||
DP_NOTICE(p_hwfn,
|
||||
"Invalid VPORT ID for rate limiter configuration\n");
|
||||
rl_valid = false;
|
||||
}
|
||||
|
||||
/* Prepare PQ map entry */
|
||||
QM_INIT_TX_PQ_MAP(p_hwfn,
|
||||
@ -528,7 +528,7 @@ static void qed_tx_pq_map_rt_init(struct qed_hwfn *p_hwfn,
|
||||
pq_info = PQ_INFO_ELEMENT(*p_first_tx_pq_id,
|
||||
p_params->pf_id,
|
||||
tc_id,
|
||||
p_params->port_id,
|
||||
pq_params[i].port_id,
|
||||
rl_valid ? 1 : 0,
|
||||
rl_valid ?
|
||||
pq_params[i].vport_id : 0);
|
||||
@ -603,6 +603,7 @@ static void qed_other_pq_map_rt_init(struct qed_hwfn *p_hwfn,
|
||||
* Return -1 on error.
|
||||
*/
|
||||
static int qed_pf_wfq_rt_init(struct qed_hwfn *p_hwfn,
|
||||
|
||||
struct qed_qm_pf_rt_init_params *p_params)
|
||||
{
|
||||
u16 num_tx_pqs = p_params->num_pf_pqs + p_params->num_vf_pqs;
|
||||
@ -619,7 +620,7 @@ static int qed_pf_wfq_rt_init(struct qed_hwfn *p_hwfn,
|
||||
|
||||
for (i = 0; i < num_tx_pqs; i++) {
|
||||
ext_voq = qed_get_ext_voq(p_hwfn,
|
||||
p_params->port_id,
|
||||
pq_params[i].port_id,
|
||||
pq_params[i].tc_id,
|
||||
p_params->max_phys_tcs_per_port);
|
||||
crd_reg_offset =
|
||||
@ -1020,7 +1021,8 @@ bool qed_send_qm_stop_cmd(struct qed_hwfn *p_hwfn,
|
||||
*__p_var = (*__p_var & ~BIT(__offset)) | \
|
||||
((enable) ? BIT(__offset) : 0); \
|
||||
} while (0)
|
||||
#define PRS_ETH_TUNN_FIC_FORMAT -188897008
|
||||
#define PRS_ETH_TUNN_OUTPUT_FORMAT -188897008
|
||||
#define PRS_ETH_OUTPUT_FORMAT -46832
|
||||
|
||||
void qed_set_vxlan_dest_port(struct qed_hwfn *p_hwfn,
|
||||
struct qed_ptt *p_ptt, u16 dest_port)
|
||||
@ -1046,11 +1048,15 @@ void qed_set_vxlan_enable(struct qed_hwfn *p_hwfn,
|
||||
shift = PRS_REG_ENCAPSULATION_TYPE_EN_VXLAN_ENABLE_SHIFT;
|
||||
SET_TUNNEL_TYPE_ENABLE_BIT(reg_val, shift, vxlan_enable);
|
||||
qed_wr(p_hwfn, p_ptt, PRS_REG_ENCAPSULATION_TYPE_EN, reg_val);
|
||||
if (reg_val)
|
||||
qed_wr(p_hwfn,
|
||||
p_ptt,
|
||||
PRS_REG_OUTPUT_FORMAT_4_0_BB_K2,
|
||||
(u32)PRS_ETH_TUNN_FIC_FORMAT);
|
||||
if (reg_val) {
|
||||
reg_val =
|
||||
qed_rd(p_hwfn, p_ptt, PRS_REG_OUTPUT_FORMAT_4_0_BB_K2);
|
||||
|
||||
/* Update output only if tunnel blocks not included. */
|
||||
if (reg_val == (u32)PRS_ETH_OUTPUT_FORMAT)
|
||||
qed_wr(p_hwfn, p_ptt, PRS_REG_OUTPUT_FORMAT_4_0_BB_K2,
|
||||
(u32)PRS_ETH_TUNN_OUTPUT_FORMAT);
|
||||
}
|
||||
|
||||
/* Update NIG register */
|
||||
reg_val = qed_rd(p_hwfn, p_ptt, NIG_REG_ENC_TYPE_ENABLE);
|
||||
@ -1077,11 +1083,15 @@ void qed_set_gre_enable(struct qed_hwfn *p_hwfn,
|
||||
shift = PRS_REG_ENCAPSULATION_TYPE_EN_IP_OVER_GRE_ENABLE_SHIFT;
|
||||
SET_TUNNEL_TYPE_ENABLE_BIT(reg_val, shift, ip_gre_enable);
|
||||
qed_wr(p_hwfn, p_ptt, PRS_REG_ENCAPSULATION_TYPE_EN, reg_val);
|
||||
if (reg_val)
|
||||
qed_wr(p_hwfn,
|
||||
p_ptt,
|
||||
PRS_REG_OUTPUT_FORMAT_4_0_BB_K2,
|
||||
(u32)PRS_ETH_TUNN_FIC_FORMAT);
|
||||
if (reg_val) {
|
||||
reg_val =
|
||||
qed_rd(p_hwfn, p_ptt, PRS_REG_OUTPUT_FORMAT_4_0_BB_K2);
|
||||
|
||||
/* Update output only if tunnel blocks not included. */
|
||||
if (reg_val == (u32)PRS_ETH_OUTPUT_FORMAT)
|
||||
qed_wr(p_hwfn, p_ptt, PRS_REG_OUTPUT_FORMAT_4_0_BB_K2,
|
||||
(u32)PRS_ETH_TUNN_OUTPUT_FORMAT);
|
||||
}
|
||||
|
||||
/* Update NIG register */
|
||||
reg_val = qed_rd(p_hwfn, p_ptt, NIG_REG_ENC_TYPE_ENABLE);
|
||||
@ -1126,11 +1136,15 @@ void qed_set_geneve_enable(struct qed_hwfn *p_hwfn,
|
||||
shift = PRS_REG_ENCAPSULATION_TYPE_EN_IP_OVER_GENEVE_ENABLE_SHIFT;
|
||||
SET_TUNNEL_TYPE_ENABLE_BIT(reg_val, shift, ip_geneve_enable);
|
||||
qed_wr(p_hwfn, p_ptt, PRS_REG_ENCAPSULATION_TYPE_EN, reg_val);
|
||||
if (reg_val)
|
||||
qed_wr(p_hwfn,
|
||||
p_ptt,
|
||||
PRS_REG_OUTPUT_FORMAT_4_0_BB_K2,
|
||||
(u32)PRS_ETH_TUNN_FIC_FORMAT);
|
||||
if (reg_val) {
|
||||
reg_val =
|
||||
qed_rd(p_hwfn, p_ptt, PRS_REG_OUTPUT_FORMAT_4_0_BB_K2);
|
||||
|
||||
/* Update output only if tunnel blocks not included. */
|
||||
if (reg_val == (u32)PRS_ETH_OUTPUT_FORMAT)
|
||||
qed_wr(p_hwfn, p_ptt, PRS_REG_OUTPUT_FORMAT_4_0_BB_K2,
|
||||
(u32)PRS_ETH_TUNN_OUTPUT_FORMAT);
|
||||
}
|
||||
|
||||
/* Update NIG register */
|
||||
qed_wr(p_hwfn, p_ptt, NIG_REG_NGE_ETH_ENABLE,
|
||||
@ -1152,6 +1166,38 @@ void qed_set_geneve_enable(struct qed_hwfn *p_hwfn,
|
||||
ip_geneve_enable ? 1 : 0);
|
||||
}
|
||||
|
||||
#define PRS_ETH_VXLAN_NO_L2_ENABLE_OFFSET 4
|
||||
#define PRS_ETH_VXLAN_NO_L2_OUTPUT_FORMAT -927094512
|
||||
|
||||
void qed_set_vxlan_no_l2_enable(struct qed_hwfn *p_hwfn,
|
||||
struct qed_ptt *p_ptt, bool enable)
|
||||
{
|
||||
u32 reg_val, cfg_mask;
|
||||
|
||||
/* read PRS config register */
|
||||
reg_val = qed_rd(p_hwfn, p_ptt, PRS_REG_MSG_INFO);
|
||||
|
||||
/* set VXLAN_NO_L2_ENABLE mask */
|
||||
cfg_mask = BIT(PRS_ETH_VXLAN_NO_L2_ENABLE_OFFSET);
|
||||
|
||||
if (enable) {
|
||||
/* set VXLAN_NO_L2_ENABLE flag */
|
||||
reg_val |= cfg_mask;
|
||||
|
||||
/* update PRS FIC register */
|
||||
qed_wr(p_hwfn,
|
||||
p_ptt,
|
||||
PRS_REG_OUTPUT_FORMAT_4_0_BB_K2,
|
||||
(u32)PRS_ETH_VXLAN_NO_L2_OUTPUT_FORMAT);
|
||||
} else {
|
||||
/* clear VXLAN_NO_L2_ENABLE flag */
|
||||
reg_val &= ~cfg_mask;
|
||||
}
|
||||
|
||||
/* write PRS config register */
|
||||
qed_wr(p_hwfn, p_ptt, PRS_REG_MSG_INFO, reg_val);
|
||||
}
|
||||
|
||||
#define T_ETH_PACKET_ACTION_GFT_EVENTID 23
|
||||
#define PARSER_ETH_CONN_GFT_ACTION_CM_HDR 272
|
||||
#define T_ETH_PACKET_MATCH_RFS_EVENTID 25
|
||||
@ -1268,6 +1314,10 @@ void qed_gft_config(struct qed_hwfn *p_hwfn,
|
||||
ram_line_lo = 0;
|
||||
ram_line_hi = 0;
|
||||
|
||||
/* Tunnel type */
|
||||
SET_FIELD(ram_line_lo, GFT_RAM_LINE_TUNNEL_DST_PORT, 1);
|
||||
SET_FIELD(ram_line_lo, GFT_RAM_LINE_TUNNEL_OVER_IP_PROTOCOL, 1);
|
||||
|
||||
if (profile_type == GFT_PROFILE_TYPE_4_TUPLE) {
|
||||
SET_FIELD(ram_line_hi, GFT_RAM_LINE_DST_IP, 1);
|
||||
SET_FIELD(ram_line_hi, GFT_RAM_LINE_SRC_IP, 1);
|
||||
@ -1279,9 +1329,14 @@ void qed_gft_config(struct qed_hwfn *p_hwfn,
|
||||
SET_FIELD(ram_line_hi, GFT_RAM_LINE_OVER_IP_PROTOCOL, 1);
|
||||
SET_FIELD(ram_line_lo, GFT_RAM_LINE_ETHERTYPE, 1);
|
||||
SET_FIELD(ram_line_lo, GFT_RAM_LINE_DST_PORT, 1);
|
||||
} else if (profile_type == GFT_PROFILE_TYPE_IP_DST_PORT) {
|
||||
} else if (profile_type == GFT_PROFILE_TYPE_IP_DST_ADDR) {
|
||||
SET_FIELD(ram_line_hi, GFT_RAM_LINE_DST_IP, 1);
|
||||
SET_FIELD(ram_line_lo, GFT_RAM_LINE_ETHERTYPE, 1);
|
||||
} else if (profile_type == GFT_PROFILE_TYPE_IP_SRC_ADDR) {
|
||||
SET_FIELD(ram_line_hi, GFT_RAM_LINE_SRC_IP, 1);
|
||||
SET_FIELD(ram_line_lo, GFT_RAM_LINE_ETHERTYPE, 1);
|
||||
} else if (profile_type == GFT_PROFILE_TYPE_TUNNEL_TYPE) {
|
||||
SET_FIELD(ram_line_lo, GFT_RAM_LINE_TUNNEL_ETHERTYPE, 1);
|
||||
}
|
||||
|
||||
qed_wr(p_hwfn,
|
||||
|
@ -2375,13 +2375,6 @@ qed_iwarp_ll2_comp_syn_pkt(void *cxt, struct qed_ll2_comp_rx_data *data)
|
||||
|
||||
memset(&tx_pkt, 0, sizeof(tx_pkt));
|
||||
tx_pkt.num_of_bds = 1;
|
||||
tx_pkt.vlan = data->vlan;
|
||||
|
||||
if (GET_FIELD(data->parse_flags,
|
||||
PARSING_AND_ERR_FLAGS_TAG8021QEXIST))
|
||||
SET_FIELD(tx_pkt.bd_flags,
|
||||
CORE_TX_BD_DATA_VLAN_INSERTION, 1);
|
||||
|
||||
tx_pkt.l4_hdr_offset_w = (data->length.packet_length) >> 2;
|
||||
tx_pkt.tx_dest = QED_LL2_TX_DEST_LB;
|
||||
tx_pkt.first_frag = buf->data_phys_addr +
|
||||
|
@ -1974,7 +1974,7 @@ qed_arfs_mode_to_hsi(enum qed_filter_config_mode mode)
|
||||
if (mode == QED_FILTER_CONFIG_MODE_5_TUPLE)
|
||||
return GFT_PROFILE_TYPE_4_TUPLE;
|
||||
if (mode == QED_FILTER_CONFIG_MODE_IP_DEST)
|
||||
return GFT_PROFILE_TYPE_IP_DST_PORT;
|
||||
return GFT_PROFILE_TYPE_IP_DST_ADDR;
|
||||
return GFT_PROFILE_TYPE_L4_DST_PORT;
|
||||
}
|
||||
|
||||
|
@ -591,16 +591,6 @@ static void qed_ll2_rxq_flush(struct qed_hwfn *p_hwfn, u8 connection_handle)
|
||||
}
|
||||
}
|
||||
|
||||
static u8 qed_ll2_convert_rx_parse_to_tx_flags(u16 parse_flags)
|
||||
{
|
||||
u8 bd_flags = 0;
|
||||
|
||||
if (GET_FIELD(parse_flags, PARSING_AND_ERR_FLAGS_TAG8021QEXIST))
|
||||
SET_FIELD(bd_flags, CORE_TX_BD_DATA_VLAN_INSERTION, 1);
|
||||
|
||||
return bd_flags;
|
||||
}
|
||||
|
||||
static int qed_ll2_lb_rxq_handler(struct qed_hwfn *p_hwfn,
|
||||
struct qed_ll2_info *p_ll2_conn)
|
||||
{
|
||||
@ -744,7 +734,6 @@ qed_ooo_submit_tx_buffers(struct qed_hwfn *p_hwfn,
|
||||
struct qed_ooo_buffer *p_buffer;
|
||||
u16 l4_hdr_offset_w;
|
||||
dma_addr_t first_frag;
|
||||
u16 parse_flags;
|
||||
u8 bd_flags;
|
||||
int rc;
|
||||
|
||||
@ -756,8 +745,6 @@ qed_ooo_submit_tx_buffers(struct qed_hwfn *p_hwfn,
|
||||
|
||||
first_frag = p_buffer->rx_buffer_phys_addr +
|
||||
p_buffer->placement_offset;
|
||||
parse_flags = p_buffer->parse_flags;
|
||||
bd_flags = qed_ll2_convert_rx_parse_to_tx_flags(parse_flags);
|
||||
SET_FIELD(bd_flags, CORE_TX_BD_DATA_FORCE_VLAN_MODE, 1);
|
||||
SET_FIELD(bd_flags, CORE_TX_BD_DATA_L4_PROTOCOL, 1);
|
||||
|
||||
|
@ -110,7 +110,7 @@
|
||||
|
||||
#define FW_MAJOR_VERSION 8
|
||||
#define FW_MINOR_VERSION 33
|
||||
#define FW_REVISION_VERSION 1
|
||||
#define FW_REVISION_VERSION 11
|
||||
#define FW_ENGINEERING_VERSION 0
|
||||
|
||||
/***********************/
|
||||
|
@ -105,7 +105,7 @@
|
||||
#define ETH_CTL_FRAME_ETH_TYPE_NUM 4
|
||||
|
||||
/* GFS constants */
|
||||
#define ETH_GFT_TRASH_CAN_VPORT 0x1FF
|
||||
#define ETH_GFT_TRASHCAN_VPORT 0x1FF /* GFT drop flow vport number */
|
||||
|
||||
/* Destination port mode */
|
||||
enum dest_port_mode {
|
||||
|
@ -753,8 +753,8 @@ struct e4_ystorm_iscsi_task_ag_ctx {
|
||||
#define E4_YSTORM_ISCSI_TASK_AG_CTX_BIT1_SHIFT 5
|
||||
#define E4_YSTORM_ISCSI_TASK_AG_CTX_VALID_MASK 0x1
|
||||
#define E4_YSTORM_ISCSI_TASK_AG_CTX_VALID_SHIFT 6
|
||||
#define E4_YSTORM_ISCSI_TASK_AG_CTX_BIT3_MASK 0x1
|
||||
#define E4_YSTORM_ISCSI_TASK_AG_CTX_BIT3_SHIFT 7
|
||||
#define E4_YSTORM_ISCSI_TASK_AG_CTX_TTT_VALID_MASK 0x1 /* bit3 */
|
||||
#define E4_YSTORM_ISCSI_TASK_AG_CTX_TTT_VALID_SHIFT 7
|
||||
u8 flags1;
|
||||
#define E4_YSTORM_ISCSI_TASK_AG_CTX_CF0_MASK 0x3
|
||||
#define E4_YSTORM_ISCSI_TASK_AG_CTX_CF0_SHIFT 0
|
||||
|
@ -51,6 +51,8 @@
|
||||
#define RDMA_MAX_CQS (64 * 1024)
|
||||
#define RDMA_MAX_TIDS (128 * 1024 - 1)
|
||||
#define RDMA_MAX_PDS (64 * 1024)
|
||||
#define RDMA_MAX_XRC_SRQS (1024)
|
||||
#define RDMA_MAX_SRQS (32 * 1024)
|
||||
|
||||
#define RDMA_NUM_STATISTIC_COUNTERS MAX_NUM_VPORTS
|
||||
#define RDMA_NUM_STATISTIC_COUNTERS_K2 MAX_NUM_VPORTS_K2
|
||||
|
@ -59,6 +59,9 @@ enum roce_async_events_type {
|
||||
ROCE_ASYNC_EVENT_CQ_OVERFLOW_ERR,
|
||||
ROCE_ASYNC_EVENT_SRQ_EMPTY,
|
||||
ROCE_ASYNC_EVENT_DESTROY_QP_DONE,
|
||||
ROCE_ASYNC_EVENT_XRC_DOMAIN_ERR,
|
||||
ROCE_ASYNC_EVENT_INVALID_XRCETH_ERR,
|
||||
ROCE_ASYNC_EVENT_XRC_SRQ_CATASTROPHIC_ERR,
|
||||
MAX_ROCE_ASYNC_EVENTS_TYPE
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user