diff options
author | mjacob <mjacob@FreeBSD.org> | 2012-06-17 21:39:40 +0000 |
---|---|---|
committer | mjacob <mjacob@FreeBSD.org> | 2012-06-17 21:39:40 +0000 |
commit | 7d8c797417eb7311f4b225492e224770c214e9c8 (patch) | |
tree | 30dc205475a6a53b266d8114b1a736d1af717ef3 /sys/dev/isp/isp_pci.c | |
parent | 0118c8606277dc863307564505e6b7a9e2400e79 (diff) | |
download | FreeBSD-src-7d8c797417eb7311f4b225492e224770c214e9c8.zip FreeBSD-src-7d8c797417eb7311f4b225492e224770c214e9c8.tar.gz |
Prepare for FC-Tape support. This involved doing a lot of little cleanups
and crosschecks against firmware documentation. We now check and report
FC firmware attributes and at least are now prepared for the upper 48 bits
of f/w attributes (which are probably for the 8100 or later cards). This
involed changing how inbits and outbits are calculated for varios commands,
hopefully clearer and cleaner. This also caused me to clean up the actual
mailbox register usage. Finally, we are now unconditionally using a CRN
for initiator mode.
A longstanding issue with the 2400/2500 is that they do *not* support
a "Prefer PTP followed by loop", which explains why enabling that
caused the f/w to crash.
A slightly more invasive change is to let the firmware load entirely
drive whether multi_id support is enabled or not.
Sponsored by: Spectralogic
MFC after: 1 week
Diffstat (limited to 'sys/dev/isp/isp_pci.c')
-rw-r--r-- | sys/dev/isp/isp_pci.c | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/sys/dev/isp/isp_pci.c b/sys/dev/isp/isp_pci.c index 3764287..1dc12ee 100644 --- a/sys/dev/isp/isp_pci.c +++ b/sys/dev/isp/isp_pci.c @@ -496,11 +496,6 @@ isp_get_generic_options(device_t dev, ispsoftc_t *isp, int *nvp) tval = 7; (void) resource_int_value(device_get_name(dev), device_get_unit(dev), "quickboot_time", &tval); isp_quickboot_time = tval; - - tval = 0; - if (resource_int_value(device_get_name(dev), device_get_unit(dev), "forcemulti", &tval) == 0 && tval != 0) { - isp->isp_osinfo.forcemulti = 1; - } } static void @@ -865,7 +860,7 @@ isp_pci_attach(device_t dev) if (IS_SCSI(isp) && (ISP_SPI_PC(isp, 0)->def_role & ISP_ROLE_TARGET)) { snprintf(fwname, sizeof (fwname), "isp_%04x_it", did); isp->isp_osinfo.fw = firmware_get(fwname); - } else if (IS_24XX(isp) && (isp->isp_nchan > 1 || isp->isp_osinfo.forcemulti)) { + } else if (IS_24XX(isp)) { snprintf(fwname, sizeof (fwname), "isp_%04x_multi", did); isp->isp_osinfo.fw = firmware_get(fwname); } @@ -874,12 +869,12 @@ isp_pci_attach(device_t dev) isp->isp_osinfo.fw = firmware_get(fwname); } if (isp->isp_osinfo.fw != NULL) { + isp_prt(isp, ISP_LOGCONFIG, "loaded firmware %s", fwname); isp->isp_mdvec->dv_ispfw = isp->isp_osinfo.fw->data; } /* - * Make sure that SERR, PERR, WRITE INVALIDATE and BUSMASTER - * are set. + * Make sure that SERR, PERR, WRITE INVALIDATE and BUSMASTER are set. */ cmd |= PCIM_CMD_SEREN | PCIM_CMD_PERRESPEN | PCIM_CMD_BUSMASTEREN | PCIM_CMD_INVEN; @@ -903,7 +898,7 @@ isp_pci_attach(device_t dev) */ data = pci_read_config(dev, PCIR_CACHELNSZ, 1); if (data == 0 || (linesz != PCI_DFLT_LNSZ && data != linesz)) { - isp_prt(isp, ISP_LOGCONFIG, "set PCI line size to %d from %d", linesz, data); + isp_prt(isp, ISP_LOGDEBUG0, "set PCI line size to %d from %d", linesz, data); data = linesz; pci_write_config(dev, PCIR_CACHELNSZ, data, 1); } @@ -914,7 +909,7 @@ isp_pci_attach(device_t dev) data = pci_read_config(dev, PCIR_LATTIMER, 1); if (data < PCI_DFLT_LTNCY) { data = PCI_DFLT_LTNCY; - isp_prt(isp, ISP_LOGCONFIG, "set PCI latency to %d", data); + isp_prt(isp, ISP_LOGDEBUG0, "set PCI latency to %d", data); pci_write_config(dev, PCIR_LATTIMER, data, 1); } |