linux_dsm_epyc7002/drivers/scsi/lpfc
James Smart cb34990b90 scsi: lpfc: Fix panic when FW-log buffsize is not initialized
While trying to get adapter fw-log for a function whose buffsize was set to
0, kernel panic occurred.

When buffsize is 0, the kernel buffer for the log won't be allocated.  When
fw log usage was enabled, it failed to check the buffer size, and log usage
was started. Eventually the driver referenced the unallocated log buffer.

Added checks of the buffer size before allowing fw logging to be enabled
and added check for valid buffer if enabling fw log.

Performed a couple other minor cleanups while fixing this:
 - clarified log messages
 - re-evaluated log message severity
 - treat any error as an error, not only a couple codes

Signed-off-by: Dick Kennedy <dick.kennedy@broadcom.com>
Signed-off-by: James Smart <jsmart2021@gmail.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2018-12-07 22:35:31 -05:00
..
lpfc_attr.c scsi: lpfc: add Trunking support 2018-11-06 20:42:51 -05:00
lpfc_attr.h scsi: lpfc: Revise copyright for new company language 2018-07-10 22:15:09 -04:00
lpfc_bsg.c scsi: lpfc: Fix panic when FW-log buffsize is not initialized 2018-12-07 22:35:31 -05:00
lpfc_bsg.h scsi: lpfc: add Trunking support 2018-11-06 20:42:51 -05:00
lpfc_compat.h scsi: lpfc: Revise copyright for new company language 2018-07-10 22:15:09 -04:00
lpfc_crtn.h scsi: lpfc: Implement GID_PT on Nameserver query to support faster failover 2018-11-06 20:42:51 -05:00
lpfc_ct.c scsi: lpfc: add Trunking support 2018-11-06 20:42:51 -05:00
lpfc_debugfs.c SCSI misc on 20181024 2018-10-25 07:40:30 -07:00
lpfc_debugfs.h scsi: lpfc: Revise copyright for new company language 2018-07-10 22:15:09 -04:00
lpfc_disc.h scsi: lpfc: Limit tracking of tgt queue depth in fast path 2018-08-02 15:45:19 -04:00
lpfc_els.c scsi: lpfc: add Trunking support 2018-11-06 20:42:51 -05:00
lpfc_hbadisc.c scsi: lpfc: add Trunking support 2018-11-06 20:42:51 -05:00
lpfc_hw4.h scsi: lpfc: add Trunking support 2018-11-06 20:42:51 -05:00
lpfc_hw.h scsi: lpfc: Implement GID_PT on Nameserver query to support faster failover 2018-11-06 20:42:51 -05:00
lpfc_ids.h scsi: lpfc: Revise copyright for new company language 2018-07-10 22:15:09 -04:00
lpfc_init.c scsi: lpfc: Fix panic when FW-log buffsize is not initialized 2018-12-07 22:35:31 -05:00
lpfc_logmsg.h scsi: lpfc: Revise copyright for new company language 2018-07-10 22:15:09 -04:00
lpfc_mbox.c scsi: lpfc: Revise copyright for new company language 2018-07-10 22:15:09 -04:00
lpfc_mem.c scsi: lpfc: Revise copyright for new company language 2018-07-10 22:15:09 -04:00
lpfc_nl.h scsi: lpfc: Revise copyright for new company language 2018-07-10 22:15:09 -04:00
lpfc_nportdisc.c scsi: lpfc: Implement GID_PT on Nameserver query to support faster failover 2018-11-06 20:42:51 -05:00
lpfc_nvme.c SCSI misc on 20181024 2018-10-25 07:40:30 -07:00
lpfc_nvme.h scsi: lpfc: Limit tracking of tgt queue depth in fast path 2018-08-02 15:45:19 -04:00
lpfc_nvmet.c scsi: lpfc: Fix errors in log messages. 2018-09-11 20:37:33 -04:00
lpfc_nvmet.h scsi: lpfc: Revise copyright for new company language 2018-07-10 22:15:09 -04:00
lpfc_scsi.c scsi: lpfc: reduce locking when updating statistics 2018-09-11 20:37:33 -04:00
lpfc_scsi.h scsi: lpfc: add Trunking support 2018-11-06 20:42:51 -05:00
lpfc_sli4.h scsi: lpfc: add Trunking support 2018-11-06 20:42:51 -05:00
lpfc_sli.c scsi: lpfc: Fix panic when FW-log buffsize is not initialized 2018-12-07 22:35:31 -05:00
lpfc_sli.h scsi: lpfc: Revise copyright for new company language 2018-07-10 22:15:09 -04:00
lpfc_version.h scsi: lpfc: update driver version to 12.0.0.8 2018-11-06 20:42:51 -05:00
lpfc_vport.c scsi: lpfc: Correct irq handling via locks when taking adapter offline 2018-09-11 20:37:33 -04:00
lpfc_vport.h scsi: lpfc: Revise copyright for new company language 2018-07-10 22:15:09 -04:00
lpfc.h scsi: lpfc: add Trunking support 2018-11-06 20:42:51 -05:00
Makefile scsi: lpfc: Revise copyright for new company language 2018-07-10 22:15:09 -04:00