src/dpdk/drivers/net/qede/qede_debug.c
static u32 qed_grc_dump_reset_regs(struct ecore_hwfn *p_hwfn,
				   struct ecore_ptt *p_ptt,
				   u32 *dump_buf, bool dump)
{
	u32 offset = 0, num_regs = 0;
	u8 reset_reg_id;

	/* Calculate header size */
	offset += qed_grc_dump_regs_hdr(dump_buf,
					false,
					0, SPLIT_TYPE_NONE, 0, "RESET_REGS");

	/* Write reset registers */
	for (reset_reg_id = 0; reset_reg_id < NUM_DBG_RESET_REGS;
	     reset_reg_id++) {
		const struct dbg_reset_reg *reset_reg;
		u32 reset_reg_addr;

		reset_reg = qed_get_dbg_reset_reg(p_hwfn, reset_reg_id);

		if (GET_FIELD(reset_reg->data, DBG_RESET_REG_IS_REMOVED))
			continue;

		reset_reg_addr = GET_FIELD(reset_reg->data, DBG_RESET_REG_ADDR);
		offset += qed_grc_dump_reg_entry(p_hwfn,
						 p_ptt,
						 dump_buf + offset,
						 dump,
						 reset_reg_addr,
						 1, false, SPLIT_TYPE_NONE, 0);
		num_regs++;
	}

	/* Write header */
	if (dump)
		qed_grc_dump_regs_hdr(dump_buf,
				      true, num_regs, SPLIT_TYPE_NONE,
				      0, "RESET_REGS");

	return offset;
}
/* Dump reset registers. Returns the dumped size in dwords. */
Dump reset registers. Returns the dumped size in dwords.
Dump reset registers . Returns the dumped size in dwords .
static u32 qed_grc_dump_reset_regs(struct ecore_hwfn *p_hwfn,
				   struct ecore_ptt *p_ptt,
				   u32 *dump_buf, bool dump)
{
	u32 offset = 0, num_regs = 0;
	u8 reset_reg_id;
	offset += qed_grc_dump_regs_hdr(dump_buf,
					false,
					0, SPLIT_TYPE_NONE, 0, "RESET_REGS");
	for (reset_reg_id = 0; reset_reg_id < NUM_DBG_RESET_REGS;
	     reset_reg_id++) {
		const struct dbg_reset_reg *reset_reg;
		u32 reset_reg_addr;
		reset_reg = qed_get_dbg_reset_reg(p_hwfn, reset_reg_id);
		if (GET_FIELD(reset_reg->data, DBG_RESET_REG_IS_REMOVED))
			continue;
		reset_reg_addr = GET_FIELD(reset_reg->data, DBG_RESET_REG_ADDR);
		offset += qed_grc_dump_reg_entry(p_hwfn,
						 p_ptt,
						 dump_buf + offset,
						 dump,
						 reset_reg_addr,
						 1, false, SPLIT_TYPE_NONE, 0);
		num_regs++;
	}
	if (dump)
		qed_grc_dump_regs_hdr(dump_buf,
				      true, num_regs, SPLIT_TYPE_NONE,
				      0, "RESET_REGS");
	return offset;
}
static u32 qed_grc_dump_reset_regs ( struct ecore_hwfn * p_hwfn , struct ecore_ptt * p_ptt , u32 * dump_buf , bool dump ) { u32 offset = 0 , num_regs = 0 ; u8 reset_reg_id ; offset += qed_grc_dump_regs_hdr ( dump_buf , false , 0 , SPLIT_TYPE_NONE , 0 , " " ) ; for ( reset_reg_id = 0 ; reset_reg_id < NUM_DBG_RESET_REGS ; reset_reg_id ++ ) { const struct dbg_reset_reg * reset_reg ; u32 reset_reg_addr ; reset_reg = qed_get_dbg_reset_reg ( p_hwfn , reset_reg_id ) ; if ( GET_FIELD ( reset_reg -> data , DBG_RESET_REG_IS_REMOVED ) ) continue ; reset_reg_addr = GET_FIELD ( reset_reg -> data , DBG_RESET_REG_ADDR ) ; offset += qed_grc_dump_reg_entry ( p_hwfn , p_ptt , dump_buf + offset , dump , reset_reg_addr , 1 , false , SPLIT_TYPE_NONE , 0 ) ; num_regs ++ ; } if ( dump ) qed_grc_dump_regs_hdr ( dump_buf , true , num_regs , SPLIT_TYPE_NONE , 0 , " " ) ; return offset ; }
Dump reset registers.
Dump reset registers .
/* Calculate header size */ /* Write reset registers */ /* Write header */