Skip to content

Commit 5852ed2

Browse files
jsmart-ghmartinkpetersen
authored andcommitted
scsi: lpfc: Reduce log messages seen after firmware download
Messages around firmware download were incorrectly tagged as being related to discovery trace events. Thus, firmware download status ended up dumping the trace log as well as the firmware update message. As there were a couple of log messages in this state, the trace log was dumped multiple times. Resolve this by converting from trace events to SLI events. Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Ewan D. Milne <[email protected]> Signed-off-by: James Smart <[email protected]> Signed-off-by: Martin K. Petersen <[email protected]>
1 parent c80b27c commit 5852ed2

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

drivers/scsi/lpfc/lpfc_init.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2104,7 +2104,7 @@ lpfc_handle_eratt_s4(struct lpfc_hba *phba)
21042104
}
21052105
if (reg_err1 == SLIPORT_ERR1_REG_ERR_CODE_2 &&
21062106
reg_err2 == SLIPORT_ERR2_REG_FW_RESTART) {
2107-
lpfc_printf_log(phba, KERN_ERR, LOG_TRACE_EVENT,
2107+
lpfc_printf_log(phba, KERN_ERR, LOG_SLI,
21082108
"3143 Port Down: Firmware Update "
21092109
"Detected\n");
21102110
en_rn_msg = false;

drivers/scsi/lpfc/lpfc_sli.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13363,6 +13363,7 @@ lpfc_sli4_eratt_read(struct lpfc_hba *phba)
1336313363
uint32_t uerr_sta_hi, uerr_sta_lo;
1336413364
uint32_t if_type, portsmphr;
1336513365
struct lpfc_register portstat_reg;
13366+
u32 logmask;
1336613367

1336713368
/*
1336813369
* For now, use the SLI4 device internal unrecoverable error
@@ -13413,7 +13414,12 @@ lpfc_sli4_eratt_read(struct lpfc_hba *phba)
1341313414
readl(phba->sli4_hba.u.if_type2.ERR1regaddr);
1341413415
phba->work_status[1] =
1341513416
readl(phba->sli4_hba.u.if_type2.ERR2regaddr);
13416-
lpfc_printf_log(phba, KERN_ERR, LOG_TRACE_EVENT,
13417+
logmask = LOG_TRACE_EVENT;
13418+
if (phba->work_status[0] ==
13419+
SLIPORT_ERR1_REG_ERR_CODE_2 &&
13420+
phba->work_status[1] == SLIPORT_ERR2_REG_FW_RESTART)
13421+
logmask = LOG_SLI;
13422+
lpfc_printf_log(phba, KERN_ERR, logmask,
1341713423
"2885 Port Status Event: "
1341813424
"port status reg 0x%x, "
1341913425
"port smphr reg 0x%x, "

0 commit comments

Comments
 (0)