Deleted Added
sdiff udiff text old ( 63457 ) new ( 63944 )
full compact
1/*
2 * Product specific probe and attach routines for:
3 * 3940, 2940, aic7895, aic7890, aic7880,
4 * aic7870, aic7860 and aic7850 SCSI controllers
5 *
6 * Copyright (c) 1995, 1996, 1997, 1998, 1999, 2000 Justin T. Gibbs
7 * All rights reserved.
8 *

--- 16 unchanged lines hidden (view full) ---

25 * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31 * SUCH DAMAGE.
32 *
33 * $FreeBSD: head/sys/dev/aic7xxx/ahc_pci.c 63944 2000-07-27 23:17:52Z gibbs $
34 */
35
36#include <sys/param.h>
37#include <sys/systm.h>
38#include <sys/kernel.h>
39#include <sys/module.h>
40#include <sys/bus.h>
41

--- 730 unchanged lines hidden (view full) ---

772 dscommand0 |= MPARCKEN;
773 if ((ahc->features & AHC_ULTRA2) != 0) {
774
775 /*
776 * DPARCKEN doesn't work correctly on
777 * some MBs so don't use it.
778 */
779 dscommand0 &= ~DPARCKEN;
780 /*
781 * We default to using 32byte SCBs
782 * and using cacheline streaming.
783 * If external SCB ram is detected,
784 * we'll switch to using 64 byte SCBs.
785 */
786 dscommand0 |= CACHETHEN|USCBSIZE32;
787 }
788 /*
789 * Handle chips that must have cache line
790 * streaming (dis/en)abled.
791 */
792 if ((ahc->bugs & AHC_CACHETHEN_DIS_BUG) != 0)
793 dscommand0 |= CACHETHEN;
794
795 if ((ahc->bugs & AHC_CACHETHEN_BUG) != 0)
796 dscommand0 &= ~CACHETHEN;
797
798 ahc_outb(ahc, DSCOMMAND0, dscommand0);
799
800 /* See if we have a SEEPROM and perform auto-term */
801 check_extport(ahc, &sxfrctl1);
802
803 /*
804 * Take the LED out of diagnostic mode
805 */

--- 1060 unchanged lines hidden (view full) ---

1866static int
1867ahc_aic7890_setup(device_t dev, struct ahc_probe_config *probe_config)
1868{
1869 probe_config->channel = 'A';
1870 probe_config->chip = AHC_AIC7890;
1871 probe_config->features = AHC_AIC7890_FE;
1872 probe_config->flags |= AHC_NEWEEPROM_FMT;
1873 if (pci_get_revid(dev) == 0)
1874 probe_config->bugs |= AHC_AUTOFLUSH_BUG|AHC_CACHETHEN_BUG;
1875 return (0);
1876}
1877
1878static int
1879ahc_aic7892_setup(device_t dev, struct ahc_probe_config *probe_config)
1880{
1881 probe_config->channel = 'A';
1882 probe_config->chip = AHC_AIC7892;

--- 24 unchanged lines hidden (view full) ---

1907
1908static int
1909ahc_aic7896_setup(device_t dev, struct ahc_probe_config *probe_config)
1910{
1911 probe_config->channel = pci_get_function(dev) == 1 ? 'B' : 'A';
1912 probe_config->chip = AHC_AIC7896;
1913 probe_config->features = AHC_AIC7896_FE;
1914 probe_config->flags |= AHC_NEWEEPROM_FMT;
1915 probe_config->bugs |= AHC_CACHETHEN_DIS_BUG;
1916 return (0);
1917}
1918
1919static int
1920ahc_aic7899_setup(device_t dev, struct ahc_probe_config *probe_config)
1921{
1922 probe_config->channel = pci_get_function(dev) == 1 ? 'B' : 'A';
1923 probe_config->chip = AHC_AIC7899;

--- 80 unchanged lines hidden ---