Patchwork [1/3] Support for PCI Express reset type

login
register
mail settings
Submitter Andrew Vasquez
Date July 31, 2009, 4:47 p.m.
Message ID <20090731164700.GC23800@n5105in79bv1s.qlogic.org>
Download mbox | patch
Permalink /patch/30432/
State Not Applicable
Headers show

Comments

Andrew Vasquez - July 31, 2009, 4:47 p.m.
On Fri, 31 Jul 2009, Andi Kleen wrote:

> Mike Mason <mmlnx@us.ibm.com> writes:
> >
> > These patches supersede the previously submitted patch that
> > implemented a fundamental reset bit field. 
> >
> > Please review and let me know of any concerns.
> 
> Any plans to implement that for x86 too? Right now it seems to be a PPC
> specific hack.

Are there any non-PPC platforms which support EEH slot-reset?

> And where is the driver that is using it?

That would be the qla2xxx (FC/FCoE storage) and qlge (10gb NIC
) drivers.  Changes to the drivers could look something like:



once the infrastructure changes were hashed out.

-- av

Patch

Index: b/drivers/net/qlge/qlge_main.c
===================================================================
--- a/drivers/net/qlge/qlge_main.c
+++ b/drivers/net/qlge/qlge_main.c
@@ -4289,6 +4289,9 @@  static int __devinit qlge_probe(struct p
 		return err;
 	}
 
+	/* Set EEH reset type to fundamental for this device */
+	pdev->needs_freset = 1;
+
 	qdev = netdev_priv(ndev);
 	SET_NETDEV_DEV(ndev, &pdev->dev);
 	ndev->features = (0
Index: b/drivers/scsi/qla2xxx/qla_os.c
===================================================================
--- a/drivers/scsi/qla2xxx/qla_os.c
+++ b/drivers/scsi/qla2xxx/qla_os.c
@@ -1773,6 +1773,10 @@  qla2x00_probe_one(struct pci_dev *pdev, 
 	/* Set ISP-type information. */
 	qla2x00_set_isp_flags(ha);
 
+	/* Set EEH reset type to fundamental if required by hba  */
+	if (IS_QLA24XX(ha) || IS_QLA25XX(ha) || IS_QLA81XX(ha))
+		pdev->needs_freset = 1;
+
 	/* Configure PCI I/O space */
 	ret = qla2x00_iospace_config(ha);
 	if (ret)