Skip to contentSkip to conversation

lpfc: Update lpfc to revision 12.6.0.4

PATCH In review James Smart 3 participants 19 messages Jan 28, 2020 – May 13, 2020

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

cover lpfc: Update lpfc to revision 12.6.0.4

Update lpfc to revision 12.6.0.4

Patch set contains mainly fixes and a few cleanups.

The patch "lpfc: Change lpfc_lun_queue_depth attribute to writable" is dependent upon the following patch series, which adds the new scsi service routine shost_change_max_queue_depths():
https://www.spinics.net/lists/linux-scsi/msg137981.html

The patches were cut against Martin's 5.6/scsi-queue tree

-- james

James Smart (12):
lpfc: Fix RQ buffer leakage when no IOCBs available
lpfc: Fix lpfc_io_buf resource leak in lpfc_get_scsi_buf_s4 error path
lpfc: Fix broken Credit Recovery after driver load
lpfc: Fix registration of ELS type support in fdmi
lpfc: Fix release of hwq to clear the eq relationship
lpfc: Fix compiler warning on frame size
lpfc: Fix coverity errors in fmdi attribute handling
lpfc: Remove handler for obsolete ELS - Read Port Status (RPS)
lpfc: Clean up hba max_lun_queue_depth checks
lpfc: Change lpfc_lun_queue_depth attribute to writable
lpfc: Update lpfc version to 12.6.0.4
lpfc: Copyright updates for 12.6.0.4 patches

 drivers/scsi/lpfc/lpfc.h         |   7 +-
 drivers/scsi/lpfc/lpfc_attr.c    |  64 +++++++++++--
 drivers/scsi/lpfc/lpfc_ct.c      | 141 ++++++++++++++--------------
 drivers/scsi/lpfc/lpfc_els.c     | 195 ++-------------------------------------
 drivers/scsi/lpfc/lpfc_hbadisc.c |  61 +++++++-----
 drivers/scsi/lpfc/lpfc_hw.h      |  58 ++++--------
 drivers/scsi/lpfc/lpfc_init.c    |  40 ++++----
 drivers/scsi/lpfc/lpfc_scsi.c    |   6 +-
 drivers/scsi/lpfc/lpfc_sli.c     |  15 +--
 drivers/scsi/lpfc/lpfc_version.h |   4 +-
 10 files changed, 227 insertions(+), 364 deletions(-)
Signature · 1 line
2.13.7
#1 lore raw

PATCH 1/12 lpfc: Fix RQ buffer leakage when no IOCBs available

The driver is occasionally see the following SLI Port error, requiring reset and reinit:
Port Status Event: ... error 1=0x52004a01, error 2=0x218

The failure means an RQ timeout. That is, the adapter had received asynchronous receive frames, ran out of buffer slots to place the frames, and the driver did not replenish the buffer slots before a timeout occurred. The driver should not be so slow in replenishing buffers that a timeout can occur.

When the driver received all the frames of a sequence, it allocates an IOCB to put the frames in. In a situation where there was no IOCB available for the frame of a sequence, the RQ buffer corresponding to the first frame of the sequence was not returned to the FW. Eventually, with enough traffic encountering the situation, the timeout occurred.

Fix by releasing the buffer back to firmware whenever there is no IOCB for the first frame.

---
 drivers/scsi/lpfc/lpfc_sli.c | 4 ++++
 1 file changed, 4 insertions(+)
drivers/scsi/lpfc/lpfc_sli.c +4 -0
index 64002b0cb02d..ab6f58bc80a4 100644
@@ -17950,6 +17950,10 @@ lpfc_prep_seq(struct lpfc_vport *vport, struct hbq_dmabuf *seq_dmabuf)
 			list_add_tail(&iocbq->list, &first_iocbq->list);
 		}
 	}
+	/* Free the sequence's header buffer */
+	if (!first_iocbq)
+		lpfc_in_buf_free(vport->phba, &seq_dmabuf->dbuf);
+
 	return first_iocbq;
 }
 
Signature · 1 line
2.13.7
#2 lore raw

PATCH 2/12 lpfc: Fix lpfc_io_buf resource leak in lpfc_get_scsi_buf_s4 error path

In reply to James Smart

If a call to lpfc_get_cmd_rsp_buf_per_hdwq returns NULL (memory allocation failure), a previously allocated lpfc_io_buf resource is leaked.

Fix by releasing the lpfc_io_buf resource in the failure path.

Fixes d79c9e9d4b3d ("scsi: lpfc: Support dynamic unbounded SGL lists on G7 hardware.")
Cc <[email protected]> # v5.4+
---
 drivers/scsi/lpfc/lpfc_scsi.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/scsi/lpfc/lpfc_scsi.c +3 -1
index 2c7e0b22db2f..96ac4a154c58 100644
@@ -671,8 +671,10 @@ lpfc_get_scsi_buf_s4(struct lpfc_hba *phba, struct lpfc_nodelist *ndlp,
 	lpfc_cmd->prot_data_type = 0;
 #endif
 	tmp = lpfc_get_cmd_rsp_buf_per_hdwq(phba, lpfc_cmd);
-	if (!tmp)
+	if (!tmp) {
+		lpfc_release_io_buf(phba, lpfc_cmd, lpfc_cmd->hdwq);
 		return NULL;
+	}
 
 	lpfc_cmd->fcp_cmnd = tmp->fcp_cmnd;
 	lpfc_cmd->fcp_rsp = tmp->fcp_rsp;
Signature · 1 line
2.13.7
#3 lore raw

PATCH 3/12 lpfc: Fix broken Credit Recovery after driver load

In reply to James Smart

When driver is set to enable bb credit recovery, the switch displayed the setting as inactive. If the link bounces, it switches to Active.

During link up processing, the driver currently does a MBX_READ_SPARAM followed by a MBX_CONFIG_LINK. These mbox commands are queued to be executed, one at a time and the completion is processed by the worker thread. Since the MBX_READ_SPARAM is done BEFORE the MBX_CONFIG_LINK, the BB_SC_N bit is never set the the returned values. BB Credit recovery status only gets set after the driver requests the feature in CONFIG_LINK, which is done after the link up. Thus the ordering of READ_SPARAM needs to follow the CONFIG_LINK.

Fix by reordering so that READ_SPARAM is done after CONFIG_LINK. Added a HBA_DEFER_FLOGI flag so that any FLOGI handling waits until after the READ_SPARAM is done so that the proper BB credit value is set in the FLOGI payload.

Fixes 6bfb16208298 ("scsi: lpfc: Fix configuration of BB credit recovery in service parameters")
Cc <[email protected]> # v5.4+
---
 drivers/scsi/lpfc/lpfc.h         |  1 +
 drivers/scsi/lpfc/lpfc_hbadisc.c | 59 ++++++++++++++++++++++++++--------------
 2 files changed, 40 insertions(+), 20 deletions(-)
drivers/scsi/lpfc/lpfc.h +1 -0
index 04d73e2be373..3f2cb17c4574 100644
@@ -749,6 +749,7 @@ struct lpfc_hba {
 					 * capability
 					 */
 #define HBA_FLOGI_ISSUED	0x100000 /* FLOGI was issued */
+#define HBA_DEFER_FLOGI		0x800000 /* Defer FLOGI till read_sparm cmpl */
 
 	uint32_t fcp_ring_in_use; /* When polling test if intr-hndlr active*/
 	struct lpfc_dmabuf slim2p;
drivers/scsi/lpfc/lpfc_hbadisc.c +39 -20

90 lines not on this page · raw message

Signature · 1 line
2.13.7
#4 lore raw

Re: [PATCH 03/12] lpfc: Fix broken Credit Recovery after driver load

Hi,

this commit, applied in Ubuntu's 5.4.0-30.34 tree as 77d5805eafdb5c42bdfe78f058ad9c40ee1278b4, appears to cause our HPE-branded 2-port 8Gb lpfcs to report FLOGI errors. Reverting it fixes target discovery for me. See below for log messages and HW details.

Quoted 2 lines · James Smart

When driver is set to enable bb credit recovery, the switch displayed the setting as inactive. If the link bounces, it switches to Active.

[..]

Quoted 4 lines
Fixes 6bfb16208298 ("scsi: lpfc: Fix configuration of BB credit recovery in service parameters")
Cc <[email protected]> # v5.4+

Broken log messages:

[    5.837826] Emulex LightPulse Fibre Channel SCSI driver 12.6.0.4
[    5.837827] Copyright (C) 2017-2019 Broadcom. All Rights Reserved. The term "Broadcom" refers to Broadcom Inc. and/or its subsidiaries.
[    5.838807] scsi host2: Emulex LPe12000 PCIe Fibre Channel Adapter on PCI bus 07 device 00 irq 128
[    8.300583] scsi host4: Emulex LPe12000 PCIe Fibre Channel Adapter on PCI bus 07 device 01 irq 182
[    8.858018] lpfc 0000:07:00.0: 0:1303 Link Up Event x1 received Data: x1 xf7 x20 x0 x0 x0 0
[   11.380022] lpfc 0000:07:00.1: 1:1303 Link Up Event x1 received Data: x1 xf7 x20 x0 x0 x0 0
[   28.819755] lpfc 0000:07:00.1: 1:(0):0237 Pending Link Event during Discovery: State x7
[   28.819963] lpfc 0000:07:00.1: 1:1305 Link Down Event x2 received Data: x2 x7 x98014 x0 x0
[   28.915823] lpfc 0000:07:00.1: 1:1303 Link Up Event x3 received Data: x3 x0 x20 x0 x0 x0 0
[   28.920083] lpfc 0000:07:00.0: 0:(0):2858 FLOGI failure Status:x3/x2 TMO:x10 Data x101000 x0

Reverted:

[   74.838109] Emulex LightPulse Fibre Channel SCSI driver 12.6.0.4-7fbb1b050a65
[   74.838111] Copyright (C) 2017-2019 Broadcom. All Rights Reserved. The term "Broadcom" refers to Broadcom Inc. and/or its subsidiaries.
[   74.840310] scsi host2: Emulex LPe12000 PCIe Fibre Channel Adapter on PCI bus 07 device 00 irq 128
[   77.272319] scsi host4: Emulex LPe12000 PCIe Fibre Channel Adapter on PCI bus 07 device 01 irq 182
[   77.813387] lpfc 0000:07:00.0: 0:1303 Link Up Event x1 received Data: x1 xf7 x20 x0 x0 x0 0
[   80.261594] lpfc 0000:07:00.1: 1:1303 Link Up Event x1 received Data: x1 xf7 x20 x0 x0 x0 0

(plus various sd attach messages)

systool info:

    active_fc4s         = "0x00 0x00 0x01 0x00 0x00 0x00 0x00 0x01 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 "
    dev_loss_tmo        = "30"
    max_npiv_vports     = "255"
    maxframe_size       = "2048 bytes"
    npiv_vports_inuse   = "0"
    port_id             = "0x0b0260"
    port_state          = "Online"
    port_type           = "NPort (fabric via point-to-point)"
    speed               = "8 Gbit"
    supported_classes   = "Class 3"
    supported_fc4s      = "0x00 0x00 0x01 0x00 0x00 0x00 0x00 0x01 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 "
    supported_speeds    = "2 Gbit, 4 Gbit, 8 Gbit"
    symbolic_name       = "Emulex AJ763B/AH403A FV2.10X6 DV12.6.0.4-7fbb1b050a65 HN:pm01-vh03 OS:Linux"
    tgtid_bind_type     = "wwpn (World Wide Port Name)"

Let me know if you need further debug logs or something.

Thanks,

Signature · 2 lines
Chris Hofstaedtler / Deduktiva GmbH (FN 418592 b, HG Wien)
www.deduktiva.com / +43 1 353 1707
#5 lore raw

Re: [PATCH 03/12] lpfc: Fix broken Credit Recovery after driver load

Quoted 7 lines · Chris Hofstaedtler

Hi,

this commit, applied in Ubuntu's 5.4.0-30.34 tree as 77d5805eafdb5c42bdfe78f058ad9c40ee1278b4, appears to cause our HPE-branded 2-port 8Gb lpfcs to report FLOGI errors. Reverting it fixes target discovery for me. See below for log messages and HW details.

Quoted 5 lines

...
Let me know if you need further debug logs or something.

Thanks,

I'm more interested in what other patches you do or do not have in your tree.

This is the message that threw it to the left:
0237 Pending Link Event during Discovery

Let me look a little.

-- james

#6 lore raw

Re: [PATCH 03/12] lpfc: Fix broken Credit Recovery after driver load

Quoted 5 lines · James Smart
Quoted 4 lines · Chris Hofstaedtler

this commit, applied in Ubuntu's 5.4.0-30.34 tree as 77d5805eafdb5c42bdfe78f058ad9c40ee1278b4, appears to cause our HPE-branded 2-port 8Gb lpfcs to report FLOGI errors. Reverting it fixes target discovery for me. See below for log messages and HW details.

..

Quoted 3 lines

I'm more interested in what other patches you do or do not have in your tree.

I'd imagine the patches come from LP#1855303.

Please find a short log of drivers/scsi/lpfc below. As an additional info, before we were running off Ubuntu's 5.3.0-43.36 which had lpfc 12.2.0.3.

Quoted 6 lines

This is the message that threw it to the left:
0237 Pending Link Event during Discovery

Let me look a little.

-- james

Many thanks,
Chris

432bc5a9f5c1 scsi: lpfc: add RDF registration and Link Integrity FPIN logging 40953bf88d5f scsi: lpfc: Copyright updates for 12.6.0.4 patches
dbbf73335448 scsi: lpfc: Update lpfc version to 12.6.0.4
e8b80ff76088 scsi: lpfc: Clean up hba max_lun_queue_depth checks
3c011ebffaef scsi: lpfc: Remove handler for obsolete ELS - Read Port Status (RPS) 9b200f712004 scsi: lpfc: Fix coverity errors in fmdi attribute handling 0be9b30cd635 scsi: lpfc: Fix compiler warning on frame size
2f985fdbaec3 scsi: lpfc: Fix release of hwq to clear the eq relationship 5acd7d9f7eea scsi: lpfc: Fix registration of ELS type support in fdmi
77d5805eafdb scsi: lpfc: Fix broken Credit Recovery after driver load
6b5806410b8f scsi: lpfc: Fix lpfc_io_buf resource leak in lpfc_get_scsi_buf_s4 error path fa9df073dbce scsi: lpfc: Fix RQ buffer leakage when no IOCBs available
c5198e2e539b scsi: lpfc: Update lpfc version to 12.6.0.3
390e6a77e06f scsi: lpfc: Fix improper flag check for IO type
e2200d875825 scsi: lpfc: Fix MDS Latency Diagnostics Err-drop rates
038e6643ac38 scsi: lpfc: Fix unmap of dpp bars affecting next driver load 42898fe98599 scsi: lpfc: Fix disablement of FC-AL on lpe35000 models
1b6e85b0950d scsi: lpfc: Fix ras_log via debugfs
8d291637e21c scsi: lpfc: Fix Fabric hostname registration if system hostname changes c7f141b558f6 scsi: lpfc: Fix missing check for CSF in Write Object Mbox Rsp 107a9fe98ada scsi: lpfc: Fix incomplete NVME discovery when target
45dc4914d65f scsi: lpfc: size cpu map by last cpu id set
48d76e9b38a4 scsi: lpfc: Update lpfc version to 12.6.0.2
e667dc171fe4 scsi: lpfc: revise nvme max queues to be hdwq count
db8d6e2ab615 scsi: lpfc: Initialize cpu_map for not present cpus
d7b48a096eb7 scsi: lpfc: fix inlining of lpfc_sli4_cleanup_poll_list()
d0ff88ef8591 scsi: lpfc: Fix lpfc_cpumask_of_node_init()
a41d3723e398 scsi: lpfc: Fix a kernel warning triggered by lpfc_sli4_enable_intr() 723fabed8c5e scsi: lpfc: Update lpfc version to 12.6.0.1
8c708b2e7d79 scsi: lpfc: Add enablement of multiple adapter dumps
c50fd99a1fe9 scsi: lpfc: Change default IRQ model on AMD architectures
79d488b36a1e scsi: lpfc: Add registration for CPU Offline/Online events 328383a3f61b scsi: lpfc: Clarify FAWNN error message
e45f34740925 scsi: lpfc: Sync with FC-NVMe-2 SLER change to require Conf with SLER eaeaddbfee55 scsi: lpfc: Fix dynamic fw log enablement check
e35dc794fcdd scsi: lpfc: Fix kernel crash at lpfc_nvme_info_show during remote port bounce 4f175d5b6bca scsi: lpfc: Fix configuration of BB credit recovery in service parameters 8b22efb072fc scsi: lpfc: Make lpfc_debugfs_ras_log_data static
3323028b62de scsi: lpfc: Fix NULL check before mempool_destroy is not needed ae036af7d4f6 scsi: lpfc: fix spelling error in MAGIC_NUMER_xxx
18c38c2053fb scsi: lpfc: fix build error of lpfc_debugfs.c for vfree/vmalloc 0df2dcbaaa0d scsi: lpfc: lpfc_nvmet: Fix Use plain integer as NULL pointer 90c3f71713d5 scsi: lpfc: lpfc_attr: Fix Use plain integer as NULL pointer a3babc0488ff scsi: lpfc: Update lpfc version to 12.6.0.0
d7d082705c12 scsi: lpfc: Add additional discovery log messages
24dc02b77a1a scsi: lpfc: Add FC-AL support to lpe32000 models
980ed57564f6 scsi: lpfc: Add FA-WWN Async Event reporting
6ac712225cca scsi: lpfc: Add log macros to allow print by serverity or verbosity setting 2c0bc5bbd84a scsi: lpfc: Make FW logging dynamically configurable
3965a40a4e75 scsi: lpfc: Revise interrupt coalescing for missing scenarios 5078750b034c scsi: lpfc: Remove lock contention target write path
8f82561d4ed4 scsi: lpfc: Slight fast-path performance optimizations
632e3ddb91dc scsi: lpfc: fix coverity error of dereference after null check 07a9248d7ea0 scsi: lpfc: Fix lockdep errors in sli_ringtx_put
10662b03cd9f scsi: lpfc: Fix reporting of read-only fw error errors
2c737f5a5c47 scsi: lpfc: fix lpfc_nvmet_mrq to be bound by hdw queue count ce0e7ee555b1 scsi: lpfc: Make function lpfc_defer_pt2pt_acc static
035922837ebc scsi: lpfc: Update lpfc version to 12.4.0.1
c0e0637b5639 scsi: lpfc: cleanup: remove unused fcp_txcmlpq_cnt
f6f38dbe38dd scsi: lpfc: Complete removal of FCoE T10 PI support on SLI-4 adapters 87ba9f4e1e44 scsi: lpfc: Update async event logging
53aa87d8ac63 scsi: lpfc: Fix host hang at boot or slow boot
5df05a9d6459 scsi: lpfc: Fix coverity errors on NULL pointer checks
c01400547f7a scsi: lpfc: Fix NVMe ABTS in response to receiving an ABTS e5c93b45be68 scsi: lpfc: Fix GPF on scsi command completion
55863d7f0b03 scsi: lpfc: Fix device recovery errors after PLOGI failures 9084ef6d5222 scsi: lpfc: Fix NVME io abort failures causing hangs
e3537e7f1fe8 scsi: lpfc: Fix miss of register read failure check
88764affd6e3 scsi: lpfc: Fix premature re-enabling of interrupts in lpfc_sli_host_down fc99d4225045 scsi: lpfc: Fix pt2pt discovery on SLI3 HBAs
15e8455c4668 UBUNTU: SAUCE: Revert "nvme_fc: add module to ops template to allow module references" 190fa9115ac0 scsi: lpfc: Fix: Rework setting of fdmi symbolic node name registration ebd66c10c8f0 scsi: lpfc: use hdwq assigned cpu for allocation
f42c518b6b1e scsi: lpfc: Fix a kernel warning triggered by lpfc_get_sgl_per_hdwq() 1a8ce116a003 scsi: lpfc: Fix hdwq sgl locks and irq handling
3815dd60ccda scsi: lpfc: Fix list corruption detected in lpfc_put_sgl_per_hdwq 644726cf4623 scsi: lpfc: fix: Coverity: lpfc_get_scsi_buf_s3(): Null pointer dereferences 15d7e5222908 scsi: lpfc: Fix rpi release when deleting vport
5b82af018796 scsi: lpfc: Fix memory leak on lpfc_bsg_write_ebuf_set func a7441301b20d nvme_fc: add module to ops template to allow module references ac173a225715 scsi: lpfc: fix: Coverity: lpfc_cmpl_els_rsp(): Null pointer dereferences 170cd3bb6108 scsi: lpfc: Fix duplicate unreg_rpi error in port offline flow 46dc7c48f754 scsi: lpfc: Fix unexpected error messages during RSCN handling 6182634f0d10 scsi: lpfc: Fix SLI3 hba in loop mode not discovering devices 4b4a2235f14f scsi: lpfc: Fix hardlockup in lpfc_abort_handler
d46f5c50c520 scsi: lpfc: Fix list corruption in lpfc_sli_get_iocbq
ba7d99a490e2 scsi: lpfc: Fix locking on mailbox command completion
763e1491d43a scsi: lpfc: Fix discovery failures when target device connectivity bounces f027d0e29db4 scsi: lpfc: Fix spinlock_irq issues in lpfc_els_flush_cmd() a3c51276ddfc scsi: lpfc: Fix bad ndlp ptr in xri aborted handling
f83e148a4100 Merge tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi
(this merge is in 5.4 mainline)

Signature · 2 lines
Chris Hofstaedtler / Deduktiva GmbH (FN 418592 b, HG Wien)
www.deduktiva.com / +43 1 353 1707
#7 lore raw

Re: [PATCH 03/12] lpfc: Fix broken Credit Recovery after driver load

In reply to James Smart
Quoted 6 lines · James Smart
Quoted 5 lines · Chris Hofstaedtler

this commit, applied in Ubuntu's 5.4.0-30.34 tree as 77d5805eafdb5c42bdfe78f058ad9c40ee1278b4, appears to cause our HPE-branded 2-port 8Gb lpfcs to report FLOGI errors. Reverting it fixes target discovery for me. See below for log messages and HW details.

Quoted 8 lines
Quoted 5 lines

...
Let me know if you need further debug logs or something.

Thanks,

I'm more interested in what other patches you do or do not have in your tree.

To save everybody time figuring out patches, I've tried with a 5.7-rc tree 24085f70a6e1b0cb647ec92623284641d8270637, which gives these dmesg messages:

[    4.222975] Emulex LightPulse Fibre Channel SCSI driver 12.8.0.0
[    4.223864] scsi host2: Emulex LPe12000 PCIe Fibre Channel Adapter on PCI bus 07 device 00 irq 128
[    6.654380] scsi host4: Emulex LPe12000 PCIe Fibre Channel Adapter on PCI bus 07 device 01 irq 182
[    7.169041] lpfc 0000:07:00.0: 0:1303 Link Up Event x1 received Data: x1 xf7 x20 x0 x0 x0 0
[    9.578752] lpfc 0000:07:00.1: 1:1303 Link Up Event x1 received Data: x1 xf7 x20 x0 x0 x0 0
[   27.225755] lpfc 0000:07:00.0: 0:(0):2858 FLOGI failure Status:x3/x2 TMO:x10 Data x101000 x0
[   29.637644] lpfc 0000:07:00.1: 1:(0):2858 FLOGI failure Status:x3/x2 TMO:x10 Data x101000 x0
[   47.275946] lpfc 0000:07:00.0: 0:(0):2858 FLOGI failure Status:x3/x2 TMO:x10 Data x101000 x0
[   49.787867] lpfc 0000:07:00.1: 1:(0):2858 FLOGI failure Status:x3/x2 TMO:x10 Data x101000 x0
[   67.356082] lpfc 0000:07:00.0: 0:(0):2858 FLOGI failure Status:x3/x2 TMO:x10 Data x101000 x0
[   69.875049] lpfc 0000:07:00.1: 1:(0):2858 FLOGI failure Status:x3/x2 TMO:x10 Data x101000 x0
[   87.401269] lpfc 0000:07:00.0: 0:(0):2858 FLOGI failure Status:x3/x2 TMO:x10 Data x101000 x0
[   89.929189] lpfc 0000:07:00.1: 1:(0):2858 FLOGI failure Status:x3/x2 TMO:x10 Data x101000 x0
[  105.533242] lpfc 0000:07:00.0: 0:(0):0237 Pending Link Event during Discovery: State x7
[  105.533546] lpfc 0000:07:00.0: 0:1305 Link Down Event x2 received Data: x2 x7 x98014 x0 x0
[  105.615008] lpfc 0000:07:00.0: 0:1303 Link Up Event x3 received Data: x3 x0 x20 x0 x0 x0 0
[  109.989341] lpfc 0000:07:00.1: 1:(0):2858 FLOGI failure Status:x3/x2 TMO:x10 Data x101000 x0
[  124.772701] lpfc 0000:07:00.0: 0:(0):2858 FLOGI failure Status:x3/x2 TMO:x10 Data x101000 x0
Quoted 6 lines

This is the message that threw it to the left:
0237 Pending Link Event during Discovery

Let me look a little.

-- james

Best,
Chris

Signature · 2 lines
Chris Hofstaedtler / Deduktiva GmbH (FN 418592 b, HG Wien)
www.deduktiva.com / +43 1 353 1707
#8 lore raw

PATCH 4/12 lpfc: Fix registration of ELS type support in fdmi

In reply to James Smart

Adjust FC4 Types in FDMI settings

The driver sets FDMI information registring ELS as a FC4 type. ELS is a fc3 type and should not be registered.

Fix by removing ELS type bit when we register for FDMI Port attributes.

---
 drivers/scsi/lpfc/lpfc_ct.c | 2 --
 1 file changed, 2 deletions(-)
drivers/scsi/lpfc/lpfc_ct.c +0 -2
index 58b35a1442c1..fa70e2001b8e 100644
@@ -2453,7 +2453,6 @@ lpfc_fdmi_port_attr_fc4type(struct lpfc_vport *vport,
 	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
 	memset(ae, 0, 32);
 
-	ae->un.AttrTypes[3] = 0x02; /* Type 0x1 - ELS */
 	ae->un.AttrTypes[2] = 0x01; /* Type 0x8 - FCP */
 	ae->un.AttrTypes[7] = 0x01; /* Type 0x20 - CT */
 
@@ -2771,7 +2770,6 @@ lpfc_fdmi_port_attr_active_fc4type(struct lpfc_vport *vport,
 	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
 	memset(ae, 0, 32);
 
-	ae->un.AttrTypes[3] = 0x02; /* Type 0x1 - ELS */
 	ae->un.AttrTypes[2] = 0x01; /* Type 0x8 - FCP */
 	ae->un.AttrTypes[7] = 0x01; /* Type 0x20 - CT */
 
Signature · 1 line
2.13.7
#9 lore raw

PATCH 5/12 lpfc: Fix release of hwq to clear the eq relationship

In reply to James Smart

When performing reset testing, the eq's list for related hwq's was getting corrupted. In cases where there is not a 1:1 eq to hwq, the eq is shared. The eq maintains a list of hwqs utilizing it in case of cpu offlining and polling. During the reset, the hwqs are being torn down so they can be recreated. The recreation was getting confused by seeing a non-null eq assignment on the eq and the eq list became corrupt.

Correct by clearing the hdwq eq assignment when the hwq is cleaned up.

---
 drivers/scsi/lpfc/lpfc_init.c | 1 +
 1 file changed, 1 insertion(+)
drivers/scsi/lpfc/lpfc_init.c +1 -0
index 5a605773dd0a..9fd238d49117 100644
@@ -9235,6 +9235,7 @@ lpfc_sli4_release_hdwq(struct lpfc_hba *phba)
 		/* Free the CQ/WQ corresponding to the Hardware Queue */
 		lpfc_sli4_queue_free(hdwq[idx].io_cq);
 		lpfc_sli4_queue_free(hdwq[idx].io_wq);
+		hdwq[idx].hba_eq = NULL;
 		hdwq[idx].io_cq = NULL;
 		hdwq[idx].io_wq = NULL;
 		if (phba->cfg_xpsgl && !phba->nvmet_support)
Signature · 1 line
2.13.7
#10 lore raw

PATCH 6/12 lpfc: Fix compiler warning on frame size

In reply to James Smart

The following error is see from the compiler:

drivers/scsi/lpfc/lpfc_init.c: In function
‘lpfc_cpuhp_get_eq’: drivers/scsi/lpfc/lpfc_init.c:12660:1:
error: the frame size of 1032 bytes is larger than 1024 bytes
[-Werror=frame-larger-than=]

The issue is due to allocating a cpumask on the stack.

Fix by converting to a dynamical allocation of the cpu mask.

---
 drivers/scsi/lpfc/lpfc_init.c | 20 ++++++++++++++------
 1 file changed, 14 insertions(+), 6 deletions(-)
drivers/scsi/lpfc/lpfc_init.c +14 -6
index 9fd238d49117..9a6191818a23 100644
@@ -11106,15 +11106,19 @@ lpfc_cpu_affinity_check(struct lpfc_hba *phba, int vectors)
  * @cpu:    cpu going offline
  * @eqlist:
  */
-static void
+static int
 lpfc_cpuhp_get_eq(struct lpfc_hba *phba, unsigned int cpu,
 		  struct list_head *eqlist)
 {
 	const struct cpumask *maskp;
 	struct lpfc_queue *eq;
-	cpumask_t tmp;
+	struct cpumask *tmp;
 	u16 idx;
 
+	tmp = kzalloc(cpumask_size(), GFP_KERNEL);
+	if (!tmp)
+		return -ENOMEM;
+
 	for (idx = 0; idx < phba->cfg_irq_chann; idx++) {
 		maskp = pci_irq_get_affinity(phba->pcidev, idx);
 		if (!maskp)
@@ -11124,7 +11128,7 @@ lpfc_cpuhp_get_eq(struct lpfc_hba *phba, unsigned int cpu,
 		 * then we don't need to poll the eq attached
 		 * to it.
 		 */
-		if (!cpumask_and(&tmp, maskp, cpumask_of(cpu)))
+		if (!cpumask_and(tmp, maskp, cpumask_of(cpu)))
 			continue;
 		/* get the cpus that are online and are affini-
 		 * tized to this irq vector.  If the count is
@@ -11132,8 +11136,8 @@ lpfc_cpuhp_get_eq(struct lpfc_hba *phba, unsigned int cpu,
 		 * down this vector.  Since this cpu has not
 		 * gone offline yet, we need >1.
 		 */
-		cpumask_and(&tmp, maskp, cpu_online_mask);
-		if (cpumask_weight(&tmp) > 1)
+		cpumask_and(tmp, maskp, cpu_online_mask);
+		if (cpumask_weight(tmp) > 1)
 			continue;
 
 		/* Now that we have an irq to shutdown, get the eq
@@ -11144,6 +11148,8 @@ lpfc_cpuhp_get_eq(struct lpfc_hba *phba, unsigned int cpu,
 		eq = phba->sli4_hba.hba_eq_hdl[idx].eq;
 		list_add(&eq->_poll_list, eqlist);
 	}
+	kfree(tmp);
+	return 0;
 }
 
 static void __lpfc_cpuhp_remove(struct lpfc_hba *phba)
@@ -11314,7 +11320,9 @@ static int lpfc_cpu_offline(unsigned int cpu, struct hlist_node *node)
 
 	lpfc_irq_rebalance(phba, cpu, true);
 
-	lpfc_cpuhp_get_eq(phba, cpu, &eqlist);
+	retval = lpfc_cpuhp_get_eq(phba, cpu, &eqlist);
+	if (retval)
+		return retval;
 
 	/* start polling on these eq's */
 	list_for_each_entry_safe(eq, next, &eqlist, _poll_list) {
Signature · 1 line
2.13.7
#11 lore raw

PATCH 7/12 lpfc: Fix coverity errors in fmdi attribute handling

In reply to James Smart

Coverity reported a memory corruption error for the fdmi attributes routines:
CID 15768 [Memory Corruption] Out-of-bounds access on FDMI

Sloppy coding of the fmdi structures. In both the lpfc_fdmi_attr_def and lpfc_fdmi_reg_port_list structures, a field was placed at the start of payload that may have variable content. The field was given an arbitrary type (uint32_t). The code then uses the field name to derive an address, which it used in things such as memset and memcpy. The memset sizes or memcpy lengths were larger than the arbitrary type, thus coverity reported an error.

Fix by replacing the arbitrary fields with the real field structures describing the payload.

---
 drivers/scsi/lpfc/lpfc_ct.c | 137 ++++++++++++++++++++++----------------------
 drivers/scsi/lpfc/lpfc_hw.h |  36 ++++++------
 2 files changed, 85 insertions(+), 88 deletions(-)
drivers/scsi/lpfc/lpfc_ct.c +69 -68
index fa70e2001b8e..8db27e84263e 100644
@@ -2073,8 +2073,8 @@ lpfc_fdmi_hba_attr_wwnn(struct lpfc_vport *vport, struct lpfc_fdmi_attr_def *ad)
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, sizeof(struct lpfc_name));
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	memcpy(&ae->un.AttrWWN, &vport->fc_sparam.nodeName,
 	       sizeof(struct lpfc_name));
@@ -2090,8 +2090,8 @@ lpfc_fdmi_hba_attr_manufacturer(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t len, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	/* This string MUST be consistent with other FC platforms
 	 * supported by Broadcom.
@@ -2115,8 +2115,8 @@ lpfc_fdmi_hba_attr_sn(struct lpfc_vport *vport, struct lpfc_fdmi_attr_def *ad)
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t len, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	strncpy(ae->un.AttrString, phba->SerialNumber,
 		sizeof(ae->un.AttrString));
@@ -2137,8 +2137,8 @@ lpfc_fdmi_hba_attr_model(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t len, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	strncpy(ae->un.AttrString, phba->ModelName,
 		sizeof(ae->un.AttrString));
@@ -2158,8 +2158,8 @@ lpfc_fdmi_hba_attr_description(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t len, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	strncpy(ae->un.AttrString, phba->ModelDesc,
 		sizeof(ae->un.AttrString));
@@ -2181,8 +2181,8 @@ lpfc_fdmi_hba_attr_hdw_ver(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t i, j, incr, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	/* Convert JEDEC ID to ascii for hardware version */
 	incr = vp->rev.biuRev;
@@ -2211,8 +2211,8 @@ lpfc_fdmi_hba_attr_drvr_ver(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t len, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	strncpy(ae->un.AttrString, lpfc_release_version,
 		sizeof(ae->un.AttrString));
@@ -2233,8 +2233,8 @@ lpfc_fdmi_hba_attr_rom_ver(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t len, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	if (phba->sli_rev == LPFC_SLI_REV4)
 		lpfc_decode_firmware_rev(phba, ae->un.AttrString, 1);
@@ -2258,8 +2258,8 @@ lpfc_fdmi_hba_attr_fmw_ver(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t len, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	lpfc_decode_firmware_rev(phba, ae->un.AttrString, 1);
 	len = strnlen(ae->un.AttrString,
@@ -2278,8 +2278,8 @@ lpfc_fdmi_hba_attr_os_ver(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t len, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	snprintf(ae->un.AttrString, sizeof(ae->un.AttrString), "%s %s %s",
 		 init_utsname()->sysname,
@@ -2301,7 +2301,7 @@ lpfc_fdmi_hba_attr_ct_len(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
+	ae = &ad->AttrValue;
 
 	ae->un.AttrInt =  cpu_to_be32(LPFC_MAX_CT_SIZE);
 	size = FOURBYTES + sizeof(uint32_t);
@@ -2317,8 +2317,8 @@ lpfc_fdmi_hba_attr_symbolic_name(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t len, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	len = lpfc_vport_symbolic_node_name(vport,
 				ae->un.AttrString, 256);
@@ -2336,7 +2336,7 @@ lpfc_fdmi_hba_attr_vendor_info(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
+	ae = &ad->AttrValue;
 
 	/* Nothing is defined for this currently */
 	ae->un.AttrInt =  cpu_to_be32(0);
@@ -2353,7 +2353,7 @@ lpfc_fdmi_hba_attr_num_ports(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
+	ae = &ad->AttrValue;
 
 	/* Each driver instance corresponds to a single port */
 	ae->un.AttrInt =  cpu_to_be32(1);
@@ -2370,8 +2370,8 @@ lpfc_fdmi_hba_attr_fabric_wwnn(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, sizeof(struct lpfc_name));
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	memcpy(&ae->un.AttrWWN, &vport->fabric_nodename,
 	       sizeof(struct lpfc_name));
@@ -2389,8 +2389,8 @@ lpfc_fdmi_hba_attr_bios_ver(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t len, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	strlcat(ae->un.AttrString, phba->BIOSVersion,
 		sizeof(ae->un.AttrString));
@@ -2410,7 +2410,7 @@ lpfc_fdmi_hba_attr_bios_state(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
+	ae = &ad->AttrValue;
 
 	/* Driver doesn't have access to this information */
 	ae->un.AttrInt =  cpu_to_be32(0);
@@ -2427,8 +2427,8 @@ lpfc_fdmi_hba_attr_vendor_id(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t len, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	strncpy(ae->un.AttrString, "EMULEX",
 		sizeof(ae->un.AttrString));
@@ -2450,8 +2450,8 @@ lpfc_fdmi_port_attr_fc4type(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 32);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	ae->un.AttrTypes[2] = 0x01; /* Type 0x8 - FCP */
 	ae->un.AttrTypes[7] = 0x01; /* Type 0x20 - CT */
@@ -2475,7 +2475,7 @@ lpfc_fdmi_port_attr_support_speed(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
+	ae = &ad->AttrValue;
 
 	ae->un.AttrInt = 0;
 	if (!(phba->hba_flag & HBA_FCOE_MODE)) {
@@ -2529,7 +2529,7 @@ lpfc_fdmi_port_attr_speed(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
+	ae = &ad->AttrValue;
 
 	if (!(phba->hba_flag & HBA_FCOE_MODE)) {
 		switch (phba->fc_linkspeed) {
@@ -2599,7 +2599,7 @@ lpfc_fdmi_port_attr_max_frame(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
+	ae = &ad->AttrValue;
 
 	hsp = (struct serv_parm *)&vport->fc_sparam;
 	ae->un.AttrInt = (((uint32_t) hsp->cmn.bbRcvSizeMsb & 0x0F) << 8) |
@@ -2619,8 +2619,8 @@ lpfc_fdmi_port_attr_os_devname(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t len, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	snprintf(ae->un.AttrString, sizeof(ae->un.AttrString),
 		 "/sys/class/scsi_host/host%d", shost->host_no);
@@ -2640,8 +2640,8 @@ lpfc_fdmi_port_attr_host_name(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t len, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	scnprintf(ae->un.AttrString, sizeof(ae->un.AttrString), "%s",
 		  vport->phba->os_host_name);
@@ -2661,8 +2661,8 @@ lpfc_fdmi_port_attr_wwnn(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0,  sizeof(struct lpfc_name));
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	memcpy(&ae->un.AttrWWN, &vport->fc_sparam.nodeName,
 	       sizeof(struct lpfc_name));
@@ -2679,8 +2679,8 @@ lpfc_fdmi_port_attr_wwpn(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0,  sizeof(struct lpfc_name));
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	memcpy(&ae->un.AttrWWN, &vport->fc_sparam.portName,
 	       sizeof(struct lpfc_name));
@@ -2697,8 +2697,8 @@ lpfc_fdmi_port_attr_symbolic_name(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t len, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	len = lpfc_vport_symbolic_port_name(vport, ae->un.AttrString, 256);
 	len += (len & 3) ? (4 - (len & 3)) : 4;
@@ -2716,7 +2716,7 @@ lpfc_fdmi_port_attr_port_type(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
+	ae = &ad->AttrValue;
 	if (phba->fc_topology == LPFC_TOPOLOGY_LOOP)
 		ae->un.AttrInt =  cpu_to_be32(LPFC_FDMI_PORTTYPE_NLPORT);
 	else
@@ -2734,7 +2734,7 @@ lpfc_fdmi_port_attr_class(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
+	ae = &ad->AttrValue;
 	ae->un.AttrInt = cpu_to_be32(FC_COS_CLASS2 | FC_COS_CLASS3);
 	size = FOURBYTES + sizeof(uint32_t);
 	ad->AttrLen = cpu_to_be16(size);
@@ -2749,8 +2749,8 @@ lpfc_fdmi_port_attr_fabric_wwpn(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0,  sizeof(struct lpfc_name));
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	memcpy(&ae->un.AttrWWN, &vport->fabric_portname,
 	       sizeof(struct lpfc_name));
@@ -2767,8 +2767,8 @@ lpfc_fdmi_port_attr_active_fc4type(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 32);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	ae->un.AttrTypes[2] = 0x01; /* Type 0x8 - FCP */
 	ae->un.AttrTypes[7] = 0x01; /* Type 0x20 - CT */
@@ -2790,7 +2790,7 @@ lpfc_fdmi_port_attr_port_state(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
+	ae = &ad->AttrValue;
 	/* Link Up - operational */
 	ae->un.AttrInt =  cpu_to_be32(LPFC_FDMI_PORTSTATE_ONLINE);
 	size = FOURBYTES + sizeof(uint32_t);
@@ -2806,7 +2806,7 @@ lpfc_fdmi_port_attr_num_disc(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
+	ae = &ad->AttrValue;
 	vport->fdmi_num_disc = lpfc_find_map_node(vport);
 	ae->un.AttrInt = cpu_to_be32(vport->fdmi_num_disc);
 	size = FOURBYTES + sizeof(uint32_t);
@@ -2822,7 +2822,7 @@ lpfc_fdmi_port_attr_nportid(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
+	ae = &ad->AttrValue;
 	ae->un.AttrInt =  cpu_to_be32(vport->fc_myDID);
 	size = FOURBYTES + sizeof(uint32_t);
 	ad->AttrLen = cpu_to_be16(size);
@@ -2837,8 +2837,8 @@ lpfc_fdmi_smart_attr_service(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t len, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	strncpy(ae->un.AttrString, "Smart SAN Initiator",
 		sizeof(ae->un.AttrString));
@@ -2858,8 +2858,8 @@ lpfc_fdmi_smart_attr_guid(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	memcpy(&ae->un.AttrString, &vport->fc_sparam.nodeName,
 	       sizeof(struct lpfc_name));
@@ -2879,8 +2879,8 @@ lpfc_fdmi_smart_attr_version(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t len, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	strncpy(ae->un.AttrString, "Smart SAN Version 2.0",
 		sizeof(ae->un.AttrString));
@@ -2901,8 +2901,8 @@ lpfc_fdmi_smart_attr_model(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t len, size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
-	memset(ae, 0, 256);
+	ae = &ad->AttrValue;
+	memset(ae, 0, sizeof(*ae));
 
 	strncpy(ae->un.AttrString, phba->ModelName,
 		sizeof(ae->un.AttrString));
@@ -2921,7 +2921,7 @@ lpfc_fdmi_smart_attr_port_info(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
+	ae = &ad->AttrValue;
 
 	/* SRIOV (type 3) is not supported */
 	if (vport->vpi)
@@ -2941,7 +2941,7 @@ lpfc_fdmi_smart_attr_qos(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
+	ae = &ad->AttrValue;
 	ae->un.AttrInt =  cpu_to_be32(0);
 	size = FOURBYTES + sizeof(uint32_t);
 	ad->AttrLen = cpu_to_be16(size);
@@ -2956,7 +2956,7 @@ lpfc_fdmi_smart_attr_security(struct lpfc_vport *vport,
 	struct lpfc_fdmi_attr_entry *ae;
 	uint32_t size;
 
-	ae = (struct lpfc_fdmi_attr_entry *)&ad->AttrValue;
+	ae = &ad->AttrValue;
 	ae->un.AttrInt =  cpu_to_be32(1);
 	size = FOURBYTES + sizeof(uint32_t);
 	ad->AttrLen = cpu_to_be16(size);
@@ -3104,7 +3104,8 @@ lpfc_fdmi_cmd(struct lpfc_vport *vport, struct lpfc_nodelist *ndlp,
 			/* Registered Port List */
 			/* One entry (port) per adapter */
 			rh->rpl.EntryCnt = cpu_to_be32(1);
-			memcpy(&rh->rpl.pe, &phba->pport->fc_sparam.portName,
+			memcpy(&rh->rpl.pe.PortName,
+			       &phba->pport->fc_sparam.portName,
 			       sizeof(struct lpfc_name));
 
 			/* point to the HBA attribute block */
drivers/scsi/lpfc/lpfc_hw.h +16 -20
index 436cdc8c5ef4..b5642c872593 100644
@@ -1340,25 +1340,8 @@ struct fc_rdp_res_frame {
 /* lpfc_sli_ct_request defines the CT_IU preamble for FDMI commands */
 #define  SLI_CT_FDMI_Subtypes     0x10	/* Management Service Subtype */
 
-/*
- * Registered Port List Format
- */
-struct lpfc_fdmi_reg_port_list {
-	uint32_t EntryCnt;
-	uint32_t pe;		/* Variable-length array */
-};
-
-
 /* Definitions for HBA / Port attribute entries */
 
-struct lpfc_fdmi_attr_def { /* Defined in TLV format */
-	/* Structure is in Big Endian format */
-	uint32_t AttrType:16;
-	uint32_t AttrLen:16;
-	uint32_t AttrValue;  /* Marks start of Value (ATTRIBUTE_ENTRY) */
-};
-
-
 /* Attribute Entry */
 struct lpfc_fdmi_attr_entry {
 	union {
@@ -1369,7 +1352,13 @@ struct lpfc_fdmi_attr_entry {
 	} un;
 };
 
-#define LPFC_FDMI_MAX_AE_SIZE	sizeof(struct lpfc_fdmi_attr_entry)
+struct lpfc_fdmi_attr_def { /* Defined in TLV format */
+	/* Structure is in Big Endian format */
+	uint32_t AttrType:16;
+	uint32_t AttrLen:16;
+	/* Marks start of Value (ATTRIBUTE_ENTRY) */
+	struct lpfc_fdmi_attr_entry AttrValue;
+} __packed;
 
 /*
  * HBA Attribute Block
@@ -1394,12 +1383,19 @@ struct lpfc_fdmi_hba_ident {
 };
 
 /*
+ * Registered Port List Format
+ */
+struct lpfc_fdmi_reg_port_list {
+	uint32_t EntryCnt;
+	struct lpfc_fdmi_port_entry pe;
+} __packed;
+
+/*
  * Register HBA(RHBA)
  */
 struct lpfc_fdmi_reg_hba {
 	struct lpfc_fdmi_hba_ident hi;
-	struct lpfc_fdmi_reg_port_list rpl;	/* variable-length array */
-/* struct lpfc_fdmi_attr_block   ab; */
+	struct lpfc_fdmi_reg_port_list rpl;
 };
 
 /*
Signature · 1 line
2.13.7
#12 lore raw

PATCH 8/12 lpfc: Remove handler for obsolete ELS - Read Port Status (RPS)

In reply to James Smart

There was report of an odd "Fix me..." log message, which was tracked down to the lpfc_els_rcv_rps() routine. This was in handling of a very old and obsolete ELS - Read Port Status. The RPS ELS was defined in FC-LS-1, but deprecated in FC-LS-2, and removed from all later FC-LS revisions. It was replaced by the Read Diagnostic Parameters (RDP) ELS and the Link Error Status Block descriptor.

There should be no support for the RSP ELS. Removed support from driver.

---
 drivers/scsi/lpfc/lpfc.h     |   1 -
 drivers/scsi/lpfc/lpfc_els.c | 193 ++-----------------------------------------
 drivers/scsi/lpfc/lpfc_hw.h  |  20 -----
 3 files changed, 5 insertions(+), 209 deletions(-)
drivers/scsi/lpfc/lpfc.h +0 -1
index 3f2cb17c4574..cebbad1b3e55 100644
@@ -262,7 +262,6 @@ struct lpfc_stats {
 	uint32_t elsRcvPRLI;
 	uint32_t elsRcvLIRR;
 	uint32_t elsRcvRLS;
-	uint32_t elsRcvRPS;
 	uint32_t elsRcvRPL;
 	uint32_t elsRcvRRQ;
 	uint32_t elsRcvRTV;
drivers/scsi/lpfc/lpfc_els.c +5 -188

234 lines not on this page · raw message

drivers/scsi/lpfc/lpfc_hw.h +0 -20
index b5642c872593..9a5979075646 100644
@@ -597,7 +597,6 @@ struct fc_vft_header {
 #define ELS_CMD_ADISC     0x52000000
 #define ELS_CMD_FARP      0x54000000
 #define ELS_CMD_FARPR     0x55000000
-#define ELS_CMD_RPS       0x56000000
 #define ELS_CMD_RPL       0x57000000
 #define ELS_CMD_FAN       0x60000000
 #define ELS_CMD_RSCN      0x61040000
@@ -639,7 +638,6 @@ struct fc_vft_header {
 #define ELS_CMD_ADISC     0x52
 #define ELS_CMD_FARP      0x54
 #define ELS_CMD_FARPR     0x55
-#define ELS_CMD_RPS       0x56
 #define ELS_CMD_RPL       0x57
 #define ELS_CMD_FAN       0x60
 #define ELS_CMD_RSCN      0x0461
@@ -919,24 +917,6 @@ typedef struct _RNID {		/* Structure is in Big Endian format */
 	} un;
 } __packed RNID;
 
-typedef struct  _RPS {		/* Structure is in Big Endian format */
-	union {
-		uint32_t portNum;
-		struct lpfc_name portName;
-	} un;
-} RPS;
-
-typedef struct  _RPS_RSP {	/* Structure is in Big Endian format */
-	uint16_t rsvd1;
-	uint16_t portStatus;
-	uint32_t linkFailureCnt;
-	uint32_t lossSyncCnt;
-	uint32_t lossSignalCnt;
-	uint32_t primSeqErrCnt;
-	uint32_t invalidXmitWord;
-	uint32_t crcCnt;
-} RPS_RSP;
-
 struct RLS {			/* Structure is in Big Endian format */
 	uint32_t rls;
 #define rls_rsvd_SHIFT		24
Signature · 1 line
2.13.7
#13 lore raw

PATCH 9/12 lpfc: Clean up hba max_lun_queue_depth checks

In reply to James Smart

The current code does some odd +1 over maximum xri count checks and requires that the lun_queue_count can't be bigger than maximum xri count divided by 8. These items are bogus.

Clean the code up to cap lun_queue_count to maximum xri count.

---
 drivers/scsi/lpfc/lpfc_attr.c |  3 ---
 drivers/scsi/lpfc/lpfc_init.c | 17 ++++-------------
 drivers/scsi/lpfc/lpfc_sli.c  |  9 ---------
 3 files changed, 4 insertions(+), 25 deletions(-)
drivers/scsi/lpfc/lpfc_attr.c +0 -3
index 46f56f30f77e..48b6c98ec922 100644
@@ -3869,9 +3869,6 @@ LPFC_VPORT_ATTR_R(enable_da_id, 1, 0, 1,
 /*
 # lun_queue_depth:  This parameter is used to limit the number of outstanding
 # commands per FCP LUN. Value range is [1,512]. Default value is 30.
-# If this parameter value is greater than 1/8th the maximum number of exchanges
-# supported by the HBA port, then the lun queue depth will be reduced to
-# 1/8th the maximum number of exchanges.
 */
 LPFC_VPORT_ATTR_R(lun_queue_depth, 30, 1, 512,
 		  "Max number of FCP commands we can queue to a specific LUN");
drivers/scsi/lpfc/lpfc_init.c +4 -13
index 9a6191818a23..6d571e0b74f0 100644
@@ -512,21 +512,12 @@ lpfc_config_port_post(struct lpfc_hba *phba)
 	lpfc_sli_read_link_ste(phba);
 
 	/* Reset the DFT_HBA_Q_DEPTH to the max xri  */
-	i = (mb->un.varRdConfig.max_xri + 1);
-	if (phba->cfg_hba_queue_depth > i) {
+	if (phba->cfg_hba_queue_depth > mb->un.varRdConfig.max_xri) {
 		lpfc_printf_log(phba, KERN_WARNING, LOG_INIT,
 				"3359 HBA queue depth changed from %d to %d\n",
-				phba->cfg_hba_queue_depth, i);
-		phba->cfg_hba_queue_depth = i;
-	}
-
-	/* Reset the DFT_LUN_Q_DEPTH to (max xri >> 3)  */
-	i = (mb->un.varRdConfig.max_xri >> 3);
-	if (phba->pport->cfg_lun_queue_depth > i) {
-		lpfc_printf_log(phba, KERN_WARNING, LOG_INIT,
-				"3360 LUN queue depth changed from %d to %d\n",
-				phba->pport->cfg_lun_queue_depth, i);
-		phba->pport->cfg_lun_queue_depth = i;
+				phba->cfg_hba_queue_depth,
+				mb->un.varRdConfig.max_xri);
+		phba->cfg_hba_queue_depth = mb->un.varRdConfig.max_xri;
 	}
 
 	phba->lmt = mb->un.varRdConfig.lmt;
drivers/scsi/lpfc/lpfc_sli.c +0 -9
index ab6f58bc80a4..a5fd043e9be4 100644
@@ -7371,15 +7371,6 @@ lpfc_sli4_hba_setup(struct lpfc_hba *phba)
 			phba->vpd.rev.fcphHigh, phba->vpd.rev.fcphLow,
 			phba->vpd.rev.feaLevelHigh, phba->vpd.rev.feaLevelLow);
 
-	/* Reset the DFT_LUN_Q_DEPTH to (max xri >> 3)  */
-	rc = (phba->sli4_hba.max_cfg_param.max_xri >> 3);
-	if (phba->pport->cfg_lun_queue_depth > rc) {
-		lpfc_printf_log(phba, KERN_WARNING, LOG_INIT,
-				"3362 LUN queue depth changed from %d to %d\n",
-				phba->pport->cfg_lun_queue_depth, rc);
-		phba->pport->cfg_lun_queue_depth = rc;
-	}
-
 	if (bf_get(lpfc_sli_intf_if_type, &phba->sli4_hba.sli_intf) ==
 	    LPFC_SLI_INTF_IF_TYPE_0) {
 		lpfc_set_features(phba, mboxq, LPFC_SET_UE_RECOVERY);
Signature · 1 line
2.13.7
#14 lore raw

PATCH 10/12 lpfc: Change lpfc_lun_queue_depth attribute to writable

In reply to James Smart

Change the lpfc_lun_queue_depth attribute to be writable. When written, will change the driver's value and calls the new scsi service routine shost_change_max_queue_depths() to set the maximum and queue depth of the luns on the shost to the new value.

---
This patch is dependent upon this series, which adds the new scsi service routine shost_change_max_queue_depths():
https://www.spinics.net/lists/linux-scsi/msg137981.html

---
 drivers/scsi/lpfc/lpfc.h      |  3 +++
 drivers/scsi/lpfc/lpfc_attr.c | 59 +++++++++++++++++++++++++++++++++++++++++--
 2 files changed, 60 insertions(+), 2 deletions(-)
drivers/scsi/lpfc/lpfc.h +3 -0
index cebbad1b3e55..d26ae94e6f1e 100644
@@ -69,6 +69,9 @@ struct lpfc_sli2_slim;
 #define LPFC_TGTQ_RAMPUP_PCENT	5	/* Target queue rampup in percentage */
 #define LPFC_MIN_TGT_QDEPTH	10
 #define LPFC_MAX_TGT_QDEPTH	0xFFFF
+#define LPFC_MIN_LUN_QDEPTH	1
+#define LPFC_DEF_LUN_QDEPTH	30
+#define LPFC_MAX_LUN_QDEPTH	512
 
 #define  LPFC_MAX_BUCKET_COUNT 20	/* Maximum no. of buckets for stat data
 					   collection. */
drivers/scsi/lpfc/lpfc_attr.c +57 -2

65 lines not on this page · raw message

Signature · 1 line
2.13.7
#15 lore raw

PATCH 11/12 lpfc: Update lpfc version to 12.6.0.4

In reply to James Smart

Update lpfc version to 12.6.0.4

---
 drivers/scsi/lpfc/lpfc_version.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/scsi/lpfc/lpfc_version.h +1 -1
index 9563c49f36ab..25193146ef20 100644
@@ -20,7 +20,7 @@
  * included with this package.                                     *
  *******************************************************************/
 
-#define LPFC_DRIVER_VERSION "12.6.0.3"
+#define LPFC_DRIVER_VERSION "12.6.0.4"
 #define LPFC_DRIVER_NAME		"lpfc"
 
 /* Used for SLI 2/3 */
Signature · 1 line
2.13.7
#16 lore raw

PATCH 12/12 lpfc: Copyright updates for 12.6.0.4 patches

In reply to James Smart

Update copyrights to 2020 for files modified in the 12.6.0.4 patch set.

---
 drivers/scsi/lpfc/lpfc.h         | 2 +-
 drivers/scsi/lpfc/lpfc_attr.c    | 2 +-
 drivers/scsi/lpfc/lpfc_ct.c      | 2 +-
 drivers/scsi/lpfc/lpfc_els.c     | 2 +-
 drivers/scsi/lpfc/lpfc_hbadisc.c | 2 +-
 drivers/scsi/lpfc/lpfc_hw.h      | 2 +-
 drivers/scsi/lpfc/lpfc_init.c    | 2 +-
 drivers/scsi/lpfc/lpfc_scsi.c    | 2 +-
 drivers/scsi/lpfc/lpfc_sli.c     | 2 +-
 drivers/scsi/lpfc/lpfc_version.h | 2 +-
 10 files changed, 10 insertions(+), 10 deletions(-)
drivers/scsi/lpfc/lpfc.h +1 -1
index d26ae94e6f1e..3d985581b470 100644
@@ -1,7 +1,7 @@
 /*******************************************************************
  * This file is part of the Emulex Linux Device Driver for         *
  * Fibre Channel Host Bus Adapters.                                *
- * Copyright (C) 2017-2019 Broadcom. All Rights Reserved. The term *
+ * Copyright (C) 2017-2020 Broadcom. All Rights Reserved. The term *
  * “Broadcom” refers to Broadcom Inc. and/or its subsidiaries.     *
  * Copyright (C) 2004-2016 Emulex.  All rights reserved.           *
  * EMULEX and SLI are trademarks of Emulex.                        *
drivers/scsi/lpfc/lpfc_attr.c +1 -1
index 127484061f18..b6224487909e 100644
@@ -1,7 +1,7 @@
 /*******************************************************************
  * This file is part of the Emulex Linux Device Driver for         *
  * Fibre Channel Host Bus Adapters.                                *
- * Copyright (C) 2017-2019 Broadcom. All Rights Reserved. The term *
+ * Copyright (C) 2017-2020 Broadcom. All Rights Reserved. The term *
  * “Broadcom” refers to Broadcom Inc. and/or its subsidiaries.  *
  * Copyright (C) 2004-2016 Emulex.  All rights reserved.           *
  * EMULEX and SLI are trademarks of Emulex.                        *
drivers/scsi/lpfc/lpfc_ct.c +1 -1
index 8db27e84263e..2aa578d20f8c 100644
@@ -1,7 +1,7 @@
 /*******************************************************************
  * This file is part of the Emulex Linux Device Driver for         *
  * Fibre Channel Host Bus Adapters.                                *
- * Copyright (C) 2017-2019 Broadcom. All Rights Reserved. The term *
+ * Copyright (C) 2017-2020 Broadcom. All Rights Reserved. The term *
  * “Broadcom” refers to Broadcom Inc. and/or its subsidiaries.     *
  * Copyright (C) 2004-2016 Emulex.  All rights reserved.           *
  * EMULEX and SLI are trademarks of Emulex.                        *
drivers/scsi/lpfc/lpfc_els.c +1 -1
index 371599d67eb4..8a38e6f7f853 100644
@@ -1,7 +1,7 @@
 /*******************************************************************
  * This file is part of the Emulex Linux Device Driver for         *
  * Fibre Channel Host Bus Adapters.                                *
- * Copyright (C) 2017-2019 Broadcom. All Rights Reserved. The term *
+ * Copyright (C) 2017-2020 Broadcom. All Rights Reserved. The term *
  * “Broadcom” refers to Broadcom Inc. and/or its subsidiaries.     *
  * Copyright (C) 2004-2016 Emulex.  All rights reserved.           *
  * EMULEX and SLI are trademarks of Emulex.                        *
drivers/scsi/lpfc/lpfc_hbadisc.c +1 -1
index 6a2bdae0e52a..e8937071c748 100644
@@ -1,7 +1,7 @@
 /*******************************************************************
  * This file is part of the Emulex Linux Device Driver for         *
  * Fibre Channel Host Bus Adapters.                                *
- * Copyright (C) 2017-2019 Broadcom. All Rights Reserved. The term *
+ * Copyright (C) 2017-2020 Broadcom. All Rights Reserved. The term *
  * “Broadcom” refers to Broadcom Inc. and/or its subsidiaries.     *
  * Copyright (C) 2004-2016 Emulex.  All rights reserved.           *
  * EMULEX and SLI are trademarks of Emulex.                        *
drivers/scsi/lpfc/lpfc_hw.h +1 -1
index 9a5979075646..68f62ae6ef4f 100644
@@ -1,7 +1,7 @@
 /*******************************************************************
  * This file is part of the Emulex Linux Device Driver for         *
  * Fibre Channel Host Bus Adapters.                                *
- * Copyright (C) 2017-2018 Broadcom. All Rights Reserved. The term *
+ * Copyright (C) 2017-2020 Broadcom. All Rights Reserved. The term *
  * “Broadcom” refers to Broadcom Inc. and/or its subsidiaries.     *
  * Copyright (C) 2004-2016 Emulex.  All rights reserved.           *
  * EMULEX and SLI are trademarks of Emulex.                        *
drivers/scsi/lpfc/lpfc_init.c +1 -1
index 6d571e0b74f0..9d03e9b71efb 100644
@@ -1,7 +1,7 @@
 /*******************************************************************
  * This file is part of the Emulex Linux Device Driver for         *
  * Fibre Channel Host Bus Adapters.                                *
- * Copyright (C) 2017-2019 Broadcom. All Rights Reserved. The term *
+ * Copyright (C) 2017-2020 Broadcom. All Rights Reserved. The term *
  * “Broadcom” refers to Broadcom Inc. and/or its subsidiaries.  *
  * Copyright (C) 2004-2016 Emulex.  All rights reserved.           *
  * EMULEX and SLI are trademarks of Emulex.                        *
drivers/scsi/lpfc/lpfc_scsi.c +1 -1
index 96ac4a154c58..0fc9a242bc65 100644
@@ -1,7 +1,7 @@
 /*******************************************************************
  * This file is part of the Emulex Linux Device Driver for         *
  * Fibre Channel Host Bus Adapters.                                *
- * Copyright (C) 2017-2019 Broadcom. All Rights Reserved. The term *
+ * Copyright (C) 2017-2020 Broadcom. All Rights Reserved. The term *
  * “Broadcom” refers to Broadcom Inc. and/or its subsidiaries.  *
  * Copyright (C) 2004-2016 Emulex.  All rights reserved.           *
  * EMULEX and SLI are trademarks of Emulex.                        *
drivers/scsi/lpfc/lpfc_sli.c +1 -1
index a5fd043e9be4..86ac10ecd65a 100644
@@ -1,7 +1,7 @@
 /*******************************************************************
  * This file is part of the Emulex Linux Device Driver for         *
  * Fibre Channel Host Bus Adapters.                                *
- * Copyright (C) 2017-2019 Broadcom. All Rights Reserved. The term *
+ * Copyright (C) 2017-2020 Broadcom. All Rights Reserved. The term *
  * “Broadcom” refers to Broadcom Inc. and/or its subsidiaries.  *
  * Copyright (C) 2004-2016 Emulex.  All rights reserved.           *
  * EMULEX and SLI are trademarks of Emulex.                        *
drivers/scsi/lpfc/lpfc_version.h +1 -1
index 25193146ef20..c4ab006e6ecc 100644
@@ -1,7 +1,7 @@
 /*******************************************************************
  * This file is part of the Emulex Linux Device Driver for         *
  * Fibre Channel Host Bus Adapters.                                *
- * Copyright (C) 2017-2019 Broadcom. All Rights Reserved. The term *
+ * Copyright (C) 2017-2020 Broadcom. All Rights Reserved. The term *
  * “Broadcom” refers to Broadcom Inc. and/or its subsidiaries.     *
  * Copyright (C) 2004-2016 Emulex.  All rights reserved.           *
  * EMULEX and SLI are trademarks of Emulex.                        *
Signature · 1 line
2.13.7
#17 lore raw
In reply to James Smart

James,

Quoted 3 lines

Update lpfc to revision 12.6.0.4

Patch set contains mainly fixes and a few cleanups.

I applied everything except patch #10 because I'd like to dig into the queue depth stuff a bit more. Especially given the recent concerns about device_busy contention.

Signature · 1 line
Martin K. Petersen	Oracle Linux Engineering
#18 lore raw
Quoted 10 lines · Martin K. Petersen

James,

Quoted 3 lines

Update lpfc to revision 12.6.0.4

Patch set contains mainly fixes and a few cleanups.

I applied everything except patch #10 because I'd like to dig into the queue depth stuff a bit more. Especially given the recent concerns about device_busy contention.

I replied to the other thread. It is independent of the discussion being used with the megaraid guys. Just a way for the lldd to tune the max for the existing algorithm at run time vs at 1st discovery.

-- james