Lines Matching +full:address +full:- +full:bits
1 // SPDX-License-Identifier: GPL-2.0-or-later
3 * AMD Address Translation Library
16 * MI300 has a fixed, model-specific mapping between a UMC instance and
23 * Redundant bits were removed from the map below.
39 u16 umc_id = FIELD_GET(UMC_ID_MI300, err->ipid); in get_coh_st_inst_id_mi300()
52 /* XOR the bits in @val. */
131 * Read UMC::CH::AddrHash{Bank,PC,PC2} registers to get XOR bits used
135 * get the values needed to reconstruct the normalized address. Apply additional
217 * MI300 systems report a DRAM address in MCA_ADDR for DRAM ECC errors. This must
218 * be converted to the intermediate normalized address (NA) before translating to a
219 * system physical address.
221 * The DRAM address includes bank, row, and column. Also included are bits for
226 * The MCA address format is as follows:
229 * Additionally, the PC and Bank bits may be hashed. This must be accounted for before
230 * reconstructing the normalized address.
262 /* Bits SID[1:0] act as Bank[5:4] for PC hash, so apply them here. */ in convert_dram_to_norm_addr_mi300()
267 /* Reconstruct the normalized address starting with NA[4:0] = 0 */ in convert_dram_to_norm_addr_mi300()
270 /* Column bits */ in convert_dram_to_norm_addr_mi300()
276 /* Bank bits */ in convert_dram_to_norm_addr_mi300()
282 /* Row lo bits */ in convert_dram_to_norm_addr_mi300()
288 /* Row hi bits */ in convert_dram_to_norm_addr_mi300()
297 /* SID bits */ in convert_dram_to_norm_addr_mi300()
315 * bits and find the System Physical address of each. The column bits are used
316 * to calculate the intermediate Normalized address, so all permutations should
319 * See amd_atl::convert_dram_to_norm_addr_mi300() for MI300 address formats.
329 a_err->addr &= ~MI300_UMC_MCA_COL; in _retire_row_mi300()
330 a_err->addr |= FIELD_PREP(MI300_UMC_MCA_COL, col); in _retire_row_mi300()
354 * In addition to the column bits, the row[13] bit should also be included when
358 * the column bits twice and flip the row[13] bit in-between.
360 * See MI300_UMC_MCA_ROW for the row bits in MCA_ADDR_UMC value.
365 a_err->addr ^= MI300_UMC_MCA_ROW13; in retire_row_mi300()
392 u8 node_id = FIELD_GET(MCA_IPID_INST_ID_HI, err->ipid); in get_die_id()
401 return topology_amd_node_id(err->cpu) % topology_amd_nodes_per_pkg(); in get_die_id()
410 return FIELD_GET(UMC_CHANNEL_NUM, err->ipid); in get_coh_st_inst_id()
415 u8 socket_id = topology_physical_package_id(err->cpu); in convert_umc_mca_addr_to_sys_addr()
417 unsigned long addr = get_addr(err->addr); in convert_umc_mca_addr_to_sys_addr()
424 ret_addr = prm_umc_norm_to_sys_addr(socket_id, err->ipid, addr); in convert_umc_mca_addr_to_sys_addr()