2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-29 15:43:59 +08:00
linux-next/drivers/scsi/qla2xxx
Michael Hernandez be37aa4b99 scsi: qla2xxx: Fix system crash while triggering FW dump
This patch fixes system hang/crash while firmware dump is attempted with
Block MQ enabled in qla2xxx driver. Fix is to remove check in fw dump
template entries for existing request and response queues so that full
buffer size is calculated during template size calculation.

Following stack trace is seen during firmware dump capture process

[  694.390588] qla2xxx [0000:81:00.0]-5003:11: ISP System Error - mbx1=4b1fh mbx2=10h mbx3=2ah mbx7=0h.
[  694.402336] BUG: unable to handle kernel paging request at ffffc90008c7b000
[  694.402372] IP: memcpy_erms+0x6/0x10
[  694.402386] PGD 105f01a067
[  694.402386] PUD 85f89c067
[  694.402398] PMD 10490cb067
[  694.402409] PTE 0
[  694.402421]
[  694.402437] Oops: 0002 [#1] PREEMPT SMP
[  694.402452] Modules linked in: netconsole configfs qla2xxx scsi_transport_fc
nvme_fc nvme_fabrics bnep bluetooth rfkill xt_tcpudp unix_diag xt_multiport
ip6table_filter ip6_tables iptable_filter ip_tables x_tables af_packet
iscsi_ibft iscsi_boot_sysfs xfs libcrc32c ipmi_ssif sb_edac edac_core
x86_pkg_temp_thermal intel_powerclamp coretemp kvm_intel kvm irqbypass igb
crct10dif_pclmul crc32_pclmul ghash_clmulni_intel pcbc aesni_intel iTCO_wdt
aes_x86_64 crypto_simd ptp iTCO_vendor_support glue_helper cryptd lpc_ich joydev
i2c_i801 pcspkr ioatdma mei_me pps_core tpm_tis mei mfd_core acpi_power_meter
tpm_tis_core ipmi_si ipmi_devintf tpm ipmi_msghandler shpchp wmi dca button
acpi_pad btrfs xor uas usb_storage hid_generic usbhid raid6_pq crc32c_intel ast
i2c_algo_bit drm_kms_helper syscopyarea sysfillrect
[  694.402692]  sysimgblt fb_sys_fops xhci_pci ttm ehci_pci sr_mod xhci_hcd
cdrom ehci_hcd drm usbcore sg
[  694.402730] CPU: 0 PID: 0 Comm: swapper/0 Not tainted 4.10.0-1-default+ #19
[  694.402753] Hardware name: Supermicro X10DRi/X10DRi, BIOS 1.1a 10/16/2015
[  694.402776] task: ffffffff81c0e4c0 task.stack: ffffffff81c00000
[  694.402798] RIP: 0010:memcpy_erms+0x6/0x10
[  694.402813] RSP: 0018:ffff88085fc03cd0 EFLAGS: 00210006
[  694.402832] RAX: ffffc90008c7ae0c RBX: 0000000000000004 RCX: 000000000001fe0c
[  694.402856] RDX: 0000000000020000 RSI: ffff8810332c01f4 RDI: ffffc90008c7b000
[  694.402879] RBP: ffff88085fc03d18 R08: 0000000000020000 R09: 0000000000279e0a
[  694.402903] R10: 0000000000000000 R11: f000000000000000 R12: ffff88085fc03d80
[  694.402927] R13: ffffc90008a01000 R14: ffffc90008a056d4 R15: ffff881052ef17e0
[  694.402951] FS:  0000000000000000(0000) GS:ffff88085fc00000(0000) knlGS:0000000000000000
[  694.402977] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[  694.403012] CR2: ffffc90008c7b000 CR3: 0000000001c09000 CR4: 00000000001406f0
[  694.403036] Call Trace:
[  694.403047]  <IRQ>
[  694.403072]  ? qla27xx_fwdt_entry_t263+0x18e/0x380 [qla2xxx]
[  694.403099]  qla27xx_walk_template+0x9d/0x1a0 [qla2xxx]
[  694.403124]  qla27xx_fwdump+0x1f3/0x272 [qla2xxx]
[  694.403149]  qla2x00_async_event+0xb08/0x1a50 [qla2xxx]
[  694.403169]  ? enqueue_task_fair+0xa2/0x9d0

Signed-off-by: Mike Hernandez <michael.hernandez@cavium.com>
Signed-off-by: Joe Carnuccio <joe.carnuccio@cavium.com>
Signed-off-by: Himanshu Madhani <himanshu.madhani@cavium.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2017-08-08 11:49:50 -04:00
..
Kconfig scsi: qla2xxx: avoid unused-function warning 2017-07-01 17:14:58 -04:00
Makefile scsi: qla2xxx: Add FC-NVMe F/W initialization and transport registration 2017-06-27 21:21:47 -04:00
qla_attr.c scsi: qla2xxx: fix a bunch of typos and spelling mistakes 2017-07-01 17:12:31 -04:00
qla_bsg.c scsi: qla2xxx: fix a bunch of typos and spelling mistakes 2017-07-01 17:12:31 -04:00
qla_bsg.h qla2xxx: Add bsg interface to support statistics counter reset. 2016-07-15 15:35:37 -04:00
qla_dbg.c scsi: qla2xxx: Add FC-NVMe F/W initialization and transport registration 2017-06-27 21:21:47 -04:00
qla_dbg.h scsi: qla2xxx: Include Exchange offload/Extended Login into FW dump 2017-06-27 21:21:41 -04:00
qla_def.h scsi: qla2xxx: Send FC4 type NVMe to the management server 2017-06-27 21:21:47 -04:00
qla_devtbl.h
qla_dfs.c scsi: qla2xxx: Move target stat counters from vha to qpair. 2017-06-27 21:21:41 -04:00
qla_fw.h scsi: qla2xxx: Add FC-NVMe command handling 2017-06-27 21:21:47 -04:00
qla_gbl.h scsi: qla2xxx: Send FC4 type NVMe to the management server 2017-06-27 21:21:47 -04:00
qla_gs.c scsi: qla2xxx: Use FC-NVMe FC4 type for FDMI registration 2017-06-27 21:24:00 -04:00
qla_init.c scsi: qla2xxx: fix a bunch of typos and spelling mistakes 2017-07-01 17:12:31 -04:00
qla_inline.h scsi: qla2xxx: Add function call to qpair for door bell 2017-06-27 21:21:41 -04:00
qla_iocb.c scsi: qla2xxx: Protect access to qpair members with qpair->qp_lock 2017-07-01 16:49:27 -04:00
qla_isr.c Merge branch 'for-linus' of git://git.kernel.dk/linux-block 2017-07-11 15:36:52 -07:00
qla_mbx.c scsi: qla2xxx: fix a bunch of typos and spelling mistakes 2017-07-01 17:12:31 -04:00
qla_mid.c scsi: qla2xxx: Fix mailbox failure while deleting Queue pairs 2017-06-27 21:21:40 -04:00
qla_mr.c Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending 2017-03-02 14:52:05 -08:00
qla_mr.h
qla_nvme.c qla2xxx: Fix NVMe entry_type for iocb packet on BE system 2017-07-01 17:20:42 -04:00
qla_nvme.h scsi: qla2xxx: Add FC-NVMe F/W initialization and transport registration 2017-06-27 21:21:47 -04:00
qla_nx2.c scsi: qla2xxx: fix a bunch of typos and spelling mistakes 2017-07-01 17:12:31 -04:00
qla_nx2.h qla2xxx: Move two arrays from header files to .c files 2017-01-17 11:26:41 -08:00
qla_nx.c scsi: qla2xxx: fix a bunch of typos and spelling mistakes 2017-07-01 17:12:31 -04:00
qla_nx.h scsi: qla2xxx: remove writeq/readq function definitions 2017-06-12 20:48:08 -04:00
qla_os.c scsi: qla2xxx: Add FC-NVMe F/W initialization and transport registration 2017-06-27 21:21:47 -04:00
qla_settings.h
qla_sup.c Replace <asm/uaccess.h> with <linux/uaccess.h> globally 2016-12-24 11:46:01 -08:00
qla_target.c scsi: qla2xxx: Off by one in qlt_ctio_to_cmd() 2017-07-12 17:20:21 -04:00
qla_target.h scsi: qla2xxx: Remove datasegs_per_cmd and datasegs_per_cont field 2017-06-27 21:21:41 -04:00
qla_tmpl.c scsi: qla2xxx: Fix system crash while triggering FW dump 2017-08-08 11:49:50 -04:00
qla_tmpl.h qla2xxx: ISP27xx fwdump template error print simplification. 2014-09-25 14:25:02 +02:00
qla_version.h scsi: qla2xxx: Update Driver version to 10.00.00.00-k 2017-06-27 21:24:13 -04:00
tcm_qla2xxx.c scsi: qla2xxx: Move target stat counters from vha to qpair. 2017-06-27 21:21:41 -04:00
tcm_qla2xxx.h qla2xxx: Track I-T nexus as single fc_port struct 2017-02-08 23:34:07 -08:00