Skip to content

Commit 816a6c6

Browse files
ofirbittogabbay
authored andcommitted
habanalabs/gaudi: fetch TPC/MME ECC errors from F/W
In case F/W security is enabled driver cannot access ECC registers, hence driver must fetch the ECC info from F/W. Signed-off-by: Ofir Bitton <[email protected]> Reviewed-by: Oded Gabbay <[email protected]> Signed-off-by: Oded Gabbay <[email protected]>
1 parent 72d6625 commit 816a6c6

File tree

1 file changed

+6
-0
lines changed
  • drivers/misc/habanalabs/gaudi

1 file changed

+6
-0
lines changed

drivers/misc/habanalabs/gaudi/gaudi.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7457,6 +7457,11 @@ static void gaudi_handle_ecc_event(struct hl_device *hdev, u16 event_type,
74577457
bool extract_info_from_fw;
74587458
int rc;
74597459

7460+
if (hdev->asic_prop.fw_security_enabled) {
7461+
extract_info_from_fw = true;
7462+
goto extract_ecc_info;
7463+
}
7464+
74607465
switch (event_type) {
74617466
case GAUDI_EVENT_PCIE_CORE_SERR ... GAUDI_EVENT_PCIE_PHY_DERR:
74627467
case GAUDI_EVENT_DMA0_SERR_ECC ... GAUDI_EVENT_MMU_DERR:
@@ -7529,6 +7534,7 @@ static void gaudi_handle_ecc_event(struct hl_device *hdev, u16 event_type,
75297534
return;
75307535
}
75317536

7537+
extract_ecc_info:
75327538
if (extract_info_from_fw) {
75337539
ecc_address = le64_to_cpu(ecc_data->ecc_address);
75347540
ecc_syndrom = le64_to_cpu(ecc_data->ecc_syndrom);

0 commit comments

Comments
 (0)