src/dpdk/drivers/net/qede/qede_debug.c
static u32 qed_grc_dump_rss(struct ecore_hwfn *p_hwfn,
			    struct ecore_ptt *p_ptt, u32 *dump_buf, bool dump)
{
	struct dbg_tools_data *dev_data = &p_hwfn->dbg_info;
	u32 offset = 0;
	u8 rss_mem_id;

	for (rss_mem_id = 0; rss_mem_id < NUM_RSS_MEM_TYPES; rss_mem_id++) {
		u32 rss_addr, num_entries, total_dwords;
		struct rss_mem_defs *rss_defs;
		u32 addr, num_dwords_to_read;
		bool packed;

		rss_defs = &s_rss_mem_defs[rss_mem_id];
		rss_addr = rss_defs->addr;
		num_entries = rss_defs->num_entries[dev_data->chip_id];
		total_dwords = (num_entries * rss_defs->entry_width) / 32;
		packed = (rss_defs->entry_width == 16);

		offset += qed_grc_dump_mem_hdr(p_hwfn,
					       dump_buf + offset,
					       dump,
					       rss_defs->mem_name,
					       0,
					       total_dwords,
					       rss_defs->entry_width,
					       packed,
					       rss_defs->type_name, 0);

		/* Dump RSS data */
		if (!dump) {
			offset += total_dwords;
			continue;
		}

		addr = BYTES_TO_DWORDS(RSS_REG_RSS_RAM_DATA);
		while (total_dwords) {
			num_dwords_to_read = OSAL_MIN_T(u32,
						      RSS_REG_RSS_RAM_DATA_SIZE,
						      total_dwords);
			ecore_wr(p_hwfn, p_ptt, RSS_REG_RSS_RAM_ADDR, rss_addr);
			offset += qed_grc_dump_addr_range(p_hwfn,
							  p_ptt,
							  dump_buf + offset,
							  dump,
							  addr,
							  num_dwords_to_read,
							  false,
							  SPLIT_TYPE_NONE, 0);
			total_dwords -= num_dwords_to_read;
			rss_addr++;
		}
	}

	return offset;
}
/* Dumps GRC RSS data. Returns the dumped size in dwords. */
Dumps GRC RSS data. Returns the dumped size in dwords.
Dumps GRC RSS data . Returns the dumped size in dwords .
static u32 qed_grc_dump_rss(struct ecore_hwfn *p_hwfn,
			    struct ecore_ptt *p_ptt, u32 *dump_buf, bool dump)
{
	struct dbg_tools_data *dev_data = &p_hwfn->dbg_info;
	u32 offset = 0;
	u8 rss_mem_id;
	for (rss_mem_id = 0; rss_mem_id < NUM_RSS_MEM_TYPES; rss_mem_id++) {
		u32 rss_addr, num_entries, total_dwords;
		struct rss_mem_defs *rss_defs;
		u32 addr, num_dwords_to_read;
		bool packed;
		rss_defs = &s_rss_mem_defs[rss_mem_id];
		rss_addr = rss_defs->addr;
		num_entries = rss_defs->num_entries[dev_data->chip_id];
		total_dwords = (num_entries * rss_defs->entry_width) / 32;
		packed = (rss_defs->entry_width == 16);
		offset += qed_grc_dump_mem_hdr(p_hwfn,
					       dump_buf + offset,
					       dump,
					       rss_defs->mem_name,
					       0,
					       total_dwords,
					       rss_defs->entry_width,
					       packed,
					       rss_defs->type_name, 0);
		if (!dump) {
			offset += total_dwords;
			continue;
		}
		addr = BYTES_TO_DWORDS(RSS_REG_RSS_RAM_DATA);
		while (total_dwords) {
			num_dwords_to_read = OSAL_MIN_T(u32,
						      RSS_REG_RSS_RAM_DATA_SIZE,
						      total_dwords);
			ecore_wr(p_hwfn, p_ptt, RSS_REG_RSS_RAM_ADDR, rss_addr);
			offset += qed_grc_dump_addr_range(p_hwfn,
							  p_ptt,
							  dump_buf + offset,
							  dump,
							  addr,
							  num_dwords_to_read,
							  false,
							  SPLIT_TYPE_NONE, 0);
			total_dwords -= num_dwords_to_read;
			rss_addr++;
		}
	}
	return offset;
}
static u32 qed_grc_dump_rss ( struct ecore_hwfn * p_hwfn , struct ecore_ptt * p_ptt , u32 * dump_buf , bool dump ) { struct dbg_tools_data * dev_data = & p_hwfn -> dbg_info ; u32 offset = 0 ; u8 rss_mem_id ; for ( rss_mem_id = 0 ; rss_mem_id < NUM_RSS_MEM_TYPES ; rss_mem_id ++ ) { u32 rss_addr , num_entries , total_dwords ; struct rss_mem_defs * rss_defs ; u32 addr , num_dwords_to_read ; bool packed ; rss_defs = & s_rss_mem_defs [ rss_mem_id ] ; rss_addr = rss_defs -> addr ; num_entries = rss_defs -> num_entries [ dev_data -> chip_id ] ; total_dwords = ( num_entries * rss_defs -> entry_width ) / 32 ; packed = ( rss_defs -> entry_width == 16 ) ; offset += qed_grc_dump_mem_hdr ( p_hwfn , dump_buf + offset , dump , rss_defs -> mem_name , 0 , total_dwords , rss_defs -> entry_width , packed , rss_defs -> type_name , 0 ) ; if ( ! dump ) { offset += total_dwords ; continue ; } addr = BYTES_TO_DWORDS ( RSS_REG_RSS_RAM_DATA ) ; while ( total_dwords ) { num_dwords_to_read = OSAL_MIN_T ( u32 , RSS_REG_RSS_RAM_DATA_SIZE , total_dwords ) ; ecore_wr ( p_hwfn , p_ptt , RSS_REG_RSS_RAM_ADDR , rss_addr ) ; offset += qed_grc_dump_addr_range ( p_hwfn , p_ptt , dump_buf + offset , dump , addr , num_dwords_to_read , false , SPLIT_TYPE_NONE , 0 ) ; total_dwords -= num_dwords_to_read ; rss_addr ++ ; } } return offset ; }
Dumps GRC RSS data.
Dumps GRC RSS data .
/* Dump RSS data */