From 4034d7061a112b78d60cdb581c2d71f7cfa9f74e Mon Sep 17 00:00:00 2001 From: Chandrakanth patil Date: Tue, 19 Mar 2024 12:17:57 +0530 Subject: [PATCH] mpi3mr: diag fault success beyond F000 fault code Accept any fault as successful for diagnostic fault reset, not just the 0xF000 code. print fault information and return. Reviewed by: imp Approved by: imp Differential revision: https://reviews.freebsd.org/D44426 --- sys/dev/mpi3mr/mpi3mr.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/sys/dev/mpi3mr/mpi3mr.c b/sys/dev/mpi3mr/mpi3mr.c index 1adc19f49de..916829f4a38 100644 --- a/sys/dev/mpi3mr/mpi3mr.c +++ b/sys/dev/mpi3mr/mpi3mr.c @@ -1403,14 +1403,10 @@ mpi3mr_soft_reset_success(U32 ioc_status, U32 ioc_config) static inline bool mpi3mr_diagfault_success(struct mpi3mr_softc *sc, U32 ioc_status) { - U32 fault; - if (!(ioc_status & MPI3_SYSIF_IOC_STATUS_FAULT)) return false; - fault = mpi3mr_regread(sc, MPI3_SYSIF_FAULT_OFFSET) & MPI3_SYSIF_FAULT_CODE_MASK; - if (fault == MPI3_SYSIF_FAULT_CODE_DIAG_FAULT_RESET) - return true; - return false; + mpi3mr_print_fault_info(sc); + return true; } /**