Commit 52aca51a authored by Justin T. Gibbs's avatar Justin T. Gibbs

Merge http://linux.bkbits.net/linux-2.5

into overdrive.btc.adaptec.com:/usr/home/gibbs/bk/linux-2.5
parents 2140dbb5 5861e19e
...@@ -5,43 +5,80 @@ ...@@ -5,43 +5,80 @@
subdir- += aicasm subdir- += aicasm
obj-$(CONFIG_SCSI_AIC7XXX) += aic7xxx.o obj-$(CONFIG_SCSI_AIC7XXX) += aic7xxx.o
ifeq ($(CONFIG_PCI),y)
obj-$(CONFIG_SCSI_AIC79XX) += aic79xx.o
endif
# Core files # Core files
aic7xxx-objs += aic7xxx_core.o aic7xxx_93cx6.o aic7770.o aic7xxx-objs += aic7xxx_core.o aic7xxx_93cx6.o aic7770.o
# Platform Specific Files # Platform Specific Files
aic7xxx-objs += aic7xxx_linux.o aic7xxx_proc.o aic7770_linux.o aic7xxx-objs += aic7xxx_osm.o aic7xxx_proc.o aic7770_osm.o
ifeq ($(CONFIG_AIC7XXX_REG_PRETTY_PRINT),y)
aic7xxx-objs += aic7xxx_reg_print.o
endif
# PCI Specific Files # PCI Specific Files
ifeq ($(CONFIG_PCI),y) ifeq ($(CONFIG_PCI),y)
# Core PCI files # Core PCI files
aic7xxx-objs += aic7xxx_pci.o aic7xxx-objs += aic7xxx_pci.o
# Platform Specific PCI Files # Platform Specific PCI Files
aic7xxx-objs += aic7xxx_linux_pci.o aic7xxx-objs += aic7xxx_osm_pci.o
endif
# Platform Specific U320 Files
aic79xx-objs = aic79xx_osm.o aic79xx_proc.o aic79xx_osm_pci.o
# Core Files
aic79xx-objs += aic79xx_core.o aic79xx_pci.o
ifeq ($(CONFIG_AIC79XX_REG_PRETTY_PRINT),y)
aic79xx-objs += aic79xx_reg_print.o
endif endif
EXTRA_CFLAGS += -I$(src)/..
#EXTRA_CFLAGS += -g #EXTRA_CFLAGS += -g
# Files generated that shall be removed upon make clean # Files generated that shall be removed upon make clean
clean-files := aic7xxx_seq.h aic7xxx_reg.h clean-files := aic7xxx_seq.h aic7xxx_reg.h aic7xxx_reg_print.c
clean-files += aic79xx_seq.h aic79xx_reg.h aic79xx_reg_print.c
# Dependencies for generated files need to be listed explicitly # Dependencies for generated files need to be listed explicitly
$(obj)/aic7xxx_core.o: $(obj)/aic7xxx_seq.h $(obj)/aic7xxx_core.o: $(obj)/aic7xxx_seq.h
$(obj)/aic79xx_core.o: $(obj)/aic79xx_seq.h
$(addprefix $(obj)/,$(aic7xxx-objs)): $(obj)/aic7xxx_reg.h $(addprefix $(obj)/,$(aic7xxx-objs)): $(obj)/aic7xxx_reg.h
$(addprefix $(obj)/,$(aic79xx-objs)): $(obj)/aic79xx_reg.h
ifeq ($(CONFIG_AIC7XXX_BUILD_FIRMWARE),y) ifeq ($(CONFIG_AIC7XXX_BUILD_FIRMWARE),y)
aic7xxx_gen = $(obj)/aic7xxx_seq.h $(obj)/aic7xxx_reg.h
$(obj)/aic7xxx_seq.h: $(src)/aic7xxx.seq $(src)/aic7xxx.reg \ ifeq ($(CONFIG_AIC7XXX_REG_PRETTY_PRINT),y)
$(obj)/aicasm/aicasm aic7xxx_gen += $(obj)/aic7xxx_reg_print.c
$(obj)/aicasm/aicasm -I$(obj) -r $(obj)/aic7xxx_reg.h \ aic7xxx_asm_cmd = $(obj)/aicasm/aicasm -I$(src) -r $(obj)/aic7xxx_reg.h \
-p aic7xxx_reg_print.c -i aic7xxx_osm.h \
-o $(obj)/aic7xxx_seq.h $(src)/aic7xxx.seq -o $(obj)/aic7xxx_seq.h $(src)/aic7xxx.seq
else
aic7xxx_asm_cmd = $(obj)/aicasm/aicasm -I$(src) -r $(obj)/aic7xxx_reg.h \
-o $(obj)/aic7xxx_seq.h $(src)/aic7xxx.seq
endif
$(obj)/aic7xxx_reg.h: $(obj)/aic7xxx_seq.h $(aic7xxx_gen): $(src)/aic7xxx.seq $(src)/aic7xxx.reg $(obj)/aicasm/aicasm
$(aic7xxx_asm_cmd)
$(obj)/aicasm/aicasm: $(src)/aicasm/*.[chyl] endif
$(MAKE) -C $(src)/aicasm
ifeq ($(CONFIG_AIC79XX_BUILD_FIRMWARE),y)
aic79xx_gen = $(obj)/aic79xx_seq.h $(obj)/aic79xx_reg.h
ifeq ($(CONFIG_AIC79XX_REG_PRETTY_PRINT),y)
aic79xx_gen += $(obj)/aic79xx_reg_print.c
aic79xx_asm_cmd = $(obj)/aicasm/aicasm -I$(src) -r $(obj)/aic79xx_reg.h \
-p aic79xx_reg_print.c -i aic79xx_osm.h \
-o $(obj)/aic79xx_seq.h $(src)/aic79xx.seq
else
aic79xx_asm_cmd = $(obj)/aicasm/aicasm -I$(src) -r $(obj)/aic79xx_reg.h \
-o $(obj)/aic79xx_seq.h $(src)/aic79xx.seq
endif
$(aic79xx_gen): $(src)/aic79xx.seq $(src)/aic79xx.reg $(obj)/aicasm/aicasm
$(aic79xx_asm_cmd)
endif endif
$(obj)/aicasm/aicasm: $(src)/aicasm/*.[chyl]
$(MAKE) -C $(src)/aicasm
This diff is collapsed.
This diff is collapsed.
...@@ -37,14 +37,20 @@ ...@@ -37,14 +37,20 @@
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGES. * POSSIBILITY OF SUCH DAMAGES.
* *
* $Id: //depot/aic7xxx/aic7xxx/aic7770.c#14 $ * $Id: //depot/aic7xxx/aic7xxx/aic7770.c#25 $
* *
* $FreeBSD: src/sys/dev/aic7xxx/aic7770.c,v 1.1 2000/09/16 20:02:27 gibbs Exp $ * $FreeBSD$
*/ */
#ifdef __linux__
#include "aic7xxx_osm.h" #include "aic7xxx_osm.h"
#include "aic7xxx_inline.h" #include "aic7xxx_inline.h"
#include "aic7xxx_93cx6.h" #include "aic7xxx_93cx6.h"
#else
#include <dev/aic7xxx/aic7xxx_osm.h>
#include <dev/aic7xxx/aic7xxx_inline.h>
#include <dev/aic7xxx/aic7xxx_93cx6.h>
#endif
#define ID_AIC7770 0x04907770 #define ID_AIC7770 0x04907770
#define ID_AHA_274x 0x04907771 #define ID_AHA_274x 0x04907771
...@@ -52,7 +58,7 @@ ...@@ -52,7 +58,7 @@
#define ID_AHA_284x 0x04907757 /* BIOS disabled*/ #define ID_AHA_284x 0x04907757 /* BIOS disabled*/
#define ID_AIC_7782 0x04907782 #define ID_AIC_7782 0x04907782
static void aha2840_load_seeprom(struct ahc_softc *ahc); static int aha2840_load_seeprom(struct ahc_softc *ahc);
static ahc_device_setup_t ahc_aic7770_VL_setup; static ahc_device_setup_t ahc_aic7770_VL_setup;
static ahc_device_setup_t ahc_aic7770_EISA_setup;; static ahc_device_setup_t ahc_aic7770_EISA_setup;;
static ahc_device_setup_t ahc_aic7770_setup; static ahc_device_setup_t ahc_aic7770_setup;
...@@ -104,21 +110,32 @@ aic7770_find_device(uint32_t id) ...@@ -104,21 +110,32 @@ aic7770_find_device(uint32_t id)
} }
int int
aic7770_config(struct ahc_softc *ahc, struct aic7770_identity *entry) aic7770_config(struct ahc_softc *ahc, struct aic7770_identity *entry, u_int io)
{ {
u_long l;
int error; int error;
int have_seeprom;
u_int hostconf; u_int hostconf;
u_int irq; u_int irq;
u_int intdef; u_int intdef;
error = entry->setup(ahc); error = entry->setup(ahc);
have_seeprom = 0;
if (error != 0) if (error != 0)
return (error); return (error);
error = aic7770_map_registers(ahc); error = aic7770_map_registers(ahc, io);
if (error != 0) if (error != 0)
return (error); return (error);
/*
* Before we continue probing the card, ensure that
* its interrupts are *disabled*. We don't want
* a misstep to hang the machine in an interrupt
* storm.
*/
ahc_intr_enable(ahc, FALSE);
ahc->description = entry->name; ahc->description = entry->name;
error = ahc_softc_init(ahc); error = ahc_softc_init(ahc);
...@@ -176,21 +193,22 @@ aic7770_config(struct ahc_softc *ahc, struct aic7770_identity *entry) ...@@ -176,21 +193,22 @@ aic7770_config(struct ahc_softc *ahc, struct aic7770_identity *entry)
ahc->flags |= AHC_TERM_ENB_B; ahc->flags |= AHC_TERM_ENB_B;
} }
} }
/* if ((ahc_inb(ahc, HA_274_BIOSGLOBAL) & HA_274_EXTENDED_TRANS))
* We have no way to tell, so assume extended
* translation is enabled.
*/
ahc->flags |= AHC_EXTENDED_TRANS_A|AHC_EXTENDED_TRANS_B; ahc->flags |= AHC_EXTENDED_TRANS_A|AHC_EXTENDED_TRANS_B;
break; break;
} }
case AHC_VL: case AHC_VL:
{ {
aha2840_load_seeprom(ahc); have_seeprom = aha2840_load_seeprom(ahc);
break; break;
} }
default: default:
break; break;
} }
if (have_seeprom == 0) {
free(ahc->seep_config, M_DEVBUF);
ahc->seep_config = NULL;
}
/* /*
* Ensure autoflush is enabled * Ensure autoflush is enabled
...@@ -209,24 +227,22 @@ aic7770_config(struct ahc_softc *ahc, struct aic7770_identity *entry) ...@@ -209,24 +227,22 @@ aic7770_config(struct ahc_softc *ahc, struct aic7770_identity *entry)
if (error != 0) if (error != 0)
return (error); return (error);
error = aic7770_map_int(ahc, irq);
if (error != 0)
return (error);
ahc_list_lock(&l);
/* /*
* Link this softc in with all other ahc instances. * Link this softc in with all other ahc instances.
*/ */
ahc_softc_insert(ahc); ahc_softc_insert(ahc);
error = aic7770_map_int(ahc, irq);
if (error != 0)
return (error);
/* /*
* Enable the board's BUS drivers * Enable the board's BUS drivers
*/ */
ahc_outb(ahc, BCTL, ENABLE); ahc_outb(ahc, BCTL, ENABLE);
/* ahc_list_unlock(&l);
* Allow interrupts.
*/
ahc_intr_enable(ahc, TRUE);
return (0); return (0);
} }
...@@ -234,14 +250,13 @@ aic7770_config(struct ahc_softc *ahc, struct aic7770_identity *entry) ...@@ -234,14 +250,13 @@ aic7770_config(struct ahc_softc *ahc, struct aic7770_identity *entry)
/* /*
* Read the 284x SEEPROM. * Read the 284x SEEPROM.
*/ */
static void static int
aha2840_load_seeprom(struct ahc_softc *ahc) aha2840_load_seeprom(struct ahc_softc *ahc)
{ {
struct seeprom_descriptor sd; struct seeprom_descriptor sd;
struct seeprom_config sc; struct seeprom_config *sc;
uint16_t checksum = 0;
uint8_t scsi_conf;
int have_seeprom; int have_seeprom;
uint8_t scsi_conf;
sd.sd_ahc = ahc; sd.sd_ahc = ahc;
sd.sd_control_offset = SEECTL_2840; sd.sd_control_offset = SEECTL_2840;
...@@ -254,23 +269,16 @@ aha2840_load_seeprom(struct ahc_softc *ahc) ...@@ -254,23 +269,16 @@ aha2840_load_seeprom(struct ahc_softc *ahc)
sd.sd_CK = CK_2840; sd.sd_CK = CK_2840;
sd.sd_DO = DO_2840; sd.sd_DO = DO_2840;
sd.sd_DI = DI_2840; sd.sd_DI = DI_2840;
sc = ahc->seep_config;
if (bootverbose) if (bootverbose)
printf("%s: Reading SEEPROM...", ahc_name(ahc)); printf("%s: Reading SEEPROM...", ahc_name(ahc));
have_seeprom = read_seeprom(&sd, have_seeprom = ahc_read_seeprom(&sd, (uint16_t *)&sc,
(uint16_t *)&sc, /*start_addr*/0, sizeof(sc)/2);
/*start_addr*/0,
sizeof(sc)/2);
if (have_seeprom) { if (have_seeprom) {
/* Check checksum */
int i;
int maxaddr = (sizeof(sc)/2) - 1;
uint16_t *scarray = (uint16_t *)&sc;
for (i = 0; i < maxaddr; i++) if (ahc_verify_cksum(sc) == 0) {
checksum = checksum + scarray[i];
if (checksum != sc.checksum) {
if(bootverbose) if(bootverbose)
printf ("checksum error\n"); printf ("checksum error\n");
have_seeprom = 0; have_seeprom = 0;
...@@ -289,40 +297,43 @@ aha2840_load_seeprom(struct ahc_softc *ahc) ...@@ -289,40 +297,43 @@ aha2840_load_seeprom(struct ahc_softc *ahc)
* where ahc_init will find it. * where ahc_init will find it.
*/ */
int i; int i;
int max_targ = (ahc->features & AHC_WIDE) != 0 ? 16 : 8; int max_targ;
uint16_t discenable; uint16_t discenable;
max_targ = (ahc->features & AHC_WIDE) != 0 ? 16 : 8;
discenable = 0; discenable = 0;
for (i = 0; i < max_targ; i++){ for (i = 0; i < max_targ; i++){
uint8_t target_settings; uint8_t target_settings;
target_settings = (sc.device_flags[i] & CFXFER) << 4;
if (sc.device_flags[i] & CFSYNCH) target_settings = (sc->device_flags[i] & CFXFER) << 4;
if (sc->device_flags[i] & CFSYNCH)
target_settings |= SOFS; target_settings |= SOFS;
if (sc.device_flags[i] & CFWIDEB) if (sc->device_flags[i] & CFWIDEB)
target_settings |= WIDEXFER; target_settings |= WIDEXFER;
if (sc.device_flags[i] & CFDISC) if (sc->device_flags[i] & CFDISC)
discenable |= (0x01 << i); discenable |= (0x01 << i);
ahc_outb(ahc, TARG_SCSIRATE + i, target_settings); ahc_outb(ahc, TARG_SCSIRATE + i, target_settings);
} }
ahc_outb(ahc, DISC_DSB, ~(discenable & 0xff)); ahc_outb(ahc, DISC_DSB, ~(discenable & 0xff));
ahc_outb(ahc, DISC_DSB + 1, ~((discenable >> 8) & 0xff)); ahc_outb(ahc, DISC_DSB + 1, ~((discenable >> 8) & 0xff));
ahc->our_id = sc.brtime_id & CFSCSIID; ahc->our_id = sc->brtime_id & CFSCSIID;
scsi_conf = (ahc->our_id & 0x7); scsi_conf = (ahc->our_id & 0x7);
if (sc.adapter_control & CFSPARITY) if (sc->adapter_control & CFSPARITY)
scsi_conf |= ENSPCHK; scsi_conf |= ENSPCHK;
if (sc.adapter_control & CFRESETB) if (sc->adapter_control & CFRESETB)
scsi_conf |= RESET_SCSI; scsi_conf |= RESET_SCSI;
if (sc.bios_control & CF284XEXTEND) if (sc->bios_control & CF284XEXTEND)
ahc->flags |= AHC_EXTENDED_TRANS_A; ahc->flags |= AHC_EXTENDED_TRANS_A;
/* Set SCSICONF info */ /* Set SCSICONF info */
ahc_outb(ahc, SCSICONF, scsi_conf); ahc_outb(ahc, SCSICONF, scsi_conf);
if (sc.adapter_control & CF284XSTERM) if (sc->adapter_control & CF284XSTERM)
ahc->flags |= AHC_TERM_ENB_A; ahc->flags |= AHC_TERM_ENB_A;
} }
return (have_seeprom);
} }
static int static int
......
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGES. * POSSIBILITY OF SUCH DAMAGES.
* *
* $Id: //depot/aic7xxx/linux/drivers/scsi/aic7xxx/aic7770_linux.c#9 $ * $Id: //depot/aic7xxx/linux/drivers/scsi/aic7xxx/aic7770_osm.c#11 $
*/ */
#include "aic7xxx_osm.h" #include "aic7xxx_osm.h"
...@@ -55,9 +55,6 @@ aic7770_linux_probe(Scsi_Host_Template *template) ...@@ -55,9 +55,6 @@ aic7770_linux_probe(Scsi_Host_Template *template)
int eisaBase; int eisaBase;
int found; int found;
if (aic7xxx_no_probe)
return (0);
eisaBase = 0x1000 + AHC_EISA_SLOT_OFFSET; eisaBase = 0x1000 + AHC_EISA_SLOT_OFFSET;
found = 0; found = 0;
for (slot = 1; slot < NUMSLOTS; eisaBase+=0x1000, slot++) { for (slot = 1; slot < NUMSLOTS; eisaBase+=0x1000, slot++) {
...@@ -103,10 +100,9 @@ aic7770_linux_probe(Scsi_Host_Template *template) ...@@ -103,10 +100,9 @@ aic7770_linux_probe(Scsi_Host_Template *template)
*/ */
break; break;
} }
ahc->tag = BUS_SPACE_PIO; error = aic7770_config(ahc, entry, eisaBase);
ahc->bsh.ioport = eisaBase;
error = aic7770_config(ahc, entry);
if (error != 0) { if (error != 0) {
ahc->bsh.ioport = 0;
ahc_free(ahc); ahc_free(ahc);
continue; continue;
} }
...@@ -120,18 +116,19 @@ aic7770_linux_probe(Scsi_Host_Template *template) ...@@ -120,18 +116,19 @@ aic7770_linux_probe(Scsi_Host_Template *template)
} }
int int
aic7770_map_registers(struct ahc_softc *ahc) aic7770_map_registers(struct ahc_softc *ahc, u_int port)
{ {
/* /*
* Lock out other contenders for our i/o space. * Lock out other contenders for our i/o space.
*/ */
#if LINUX_VERSION_CODE < KERNEL_VERSION(2,4,0) #if LINUX_VERSION_CODE < KERNEL_VERSION(2,4,0)
request_region(ahc->bsh.ioport, AHC_EISA_IOSIZE, "aic7xxx"); request_region(port, AHC_EISA_IOSIZE, "aic7xxx");
#else #else
if (request_region(ahc->bsh.ioport, AHC_EISA_IOSIZE, "aic7xxx") == 0) if (request_region(port, AHC_EISA_IOSIZE, "aic7xxx") == 0)
return (ENOMEM); return (ENOMEM);
#endif #endif
ahc->tag = BUS_SPACE_PIO;
ahc->bsh.ioport = port;
return (0); return (0);
} }
...@@ -145,9 +142,9 @@ aic7770_map_int(struct ahc_softc *ahc, u_int irq) ...@@ -145,9 +142,9 @@ aic7770_map_int(struct ahc_softc *ahc, u_int irq)
if ((ahc->flags & AHC_EDGE_INTERRUPT) == 0) if ((ahc->flags & AHC_EDGE_INTERRUPT) == 0)
shared = SA_SHIRQ; shared = SA_SHIRQ;
error = request_irq(irq, ahc_linux_isr, shared, "aic7xxx", ahc);
if (error == 0)
ahc->platform_data->irq = irq; ahc->platform_data->irq = irq;
error = request_irq(ahc->platform_data->irq, ahc_linux_isr,
shared, "aic7xxx", ahc);
return (-error); return (-error);
} }
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
/*
* Adaptec AIC79xx device driver host template for Linux.
*
* Copyright (c) 2000-2001 Adaptec Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions, and the following disclaimer,
* without modification.
* 2. Redistributions in binary form must reproduce at minimum a disclaimer
* substantially similar to the "NO WARRANTY" disclaimer below
* ("Disclaimer") and any redistribution must be conditioned upon
* including a substantially similar Disclaimer requirement for further
* binary redistribution.
* 3. Neither the names of the above-listed copyright holders nor the names
* of any contributors may be used to endorse or promote products derived
* from this software without specific prior written permission.
*
* Alternatively, this software may be distributed under the terms of the
* GNU General Public License ("GPL") version 2 as published by the Free
* Software Foundation.
*
* NO WARRANTY
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGES.
*
* $Id: //depot/aic7xxx/linux/drivers/scsi/aic7xxx/aic79xx_host.h#7 $
*/
#ifndef _AIC79XX_LINUX_HOST_H_
#define _AIC79XX_LINUX_HOST_H_
int ahd_linux_proc_info(char *, char **, off_t, int, int, int);
int ahd_linux_queue(Scsi_Cmnd *, void (*)(Scsi_Cmnd *));
int ahd_linux_detect(Scsi_Host_Template *);
int ahd_linux_release(struct Scsi_Host *);
const char *ahd_linux_info(struct Scsi_Host *);
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0)
int ahd_linux_biosparam(Disk *, struct block_device *, int[]);
#else
int ahd_linux_biosparam(Disk *, kdev_t, int[]);
#endif
int ahd_linux_bus_reset(Scsi_Cmnd *);
int ahd_linux_dev_reset(Scsi_Cmnd *);
int ahd_linux_abort(Scsi_Cmnd *);
#if defined(__i386__)
# define AIC79XX_BIOSPARAM ahd_linux_biosparam
#else
# define AIC79XX_BIOSPARAM NULL
#endif
/*
* Scsi_Host_Template (see hosts.h) for AIC-79xx - some fields
* to do with card config are filled in after the card is detected.
*/
#define AIC79XX_TEMPLATE_CORE \
next: NULL, \
module: NULL, \
proc_dir: NULL, \
proc_info: ahd_linux_proc_info, \
name: NULL, \
detect: ahd_linux_detect, \
release: ahd_linux_release, \
info: ahd_linux_info, \
command: NULL, \
queuecommand: ahd_linux_queue, \
eh_strategy_handler: NULL, \
eh_abort_handler: ahd_linux_abort, \
eh_device_reset_handler: ahd_linux_dev_reset, \
eh_bus_reset_handler: ahd_linux_bus_reset, \
eh_host_reset_handler: NULL, \
abort: NULL, \
reset: NULL, \
slave_attach: NULL, \
bios_param: AIC79XX_BIOSPARAM, \
can_queue: AHD_MAX_QUEUE,/* max simultaneous cmds */\
this_id: -1, /* scsi id of host adapter */\
sg_tablesize: AHD_NSEG, /* max scatter-gather cmds */\
cmd_per_lun: 2, /* cmds per lun */\
present: 0, /* number of 7xxx's present */\
unchecked_isa_dma: 0, /* no memory DMA restrictions*/\
use_clustering: ENABLE_CLUSTERING
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0)
#define AIC79XX { \
AIC79XX_TEMPLATE_CORE \
}
#else
#define AIC79XX { \
AIC79XX_TEMPLATE_CORE, \
use_new_eh_code: 1 \
}
#endif
#endif /* _AIC79XX_LINUX_HOST_H_ */
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
...@@ -38,9 +38,9 @@ ...@@ -38,9 +38,9 @@
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGES. * POSSIBILITY OF SUCH DAMAGES.
* *
* $Id: //depot/aic7xxx/aic7xxx/aic7xxx_93cx6.h#7 $ * $Id: //depot/aic7xxx/aic7xxx/aic7xxx_93cx6.h#12 $
* *
* $FreeBSD: src/sys/dev/aic7xxx/aic7xxx_93cx6.h,v 1.8 2000/11/10 20:13:41 gibbs Exp $ * $FreeBSD$
*/ */
#ifndef _AIC7XXX_93CX6_H_ #ifndef _AIC7XXX_93CX6_H_
#define _AIC7XXX_93CX6_H_ #define _AIC7XXX_93CX6_H_
...@@ -93,8 +93,10 @@ do { \ ...@@ -93,8 +93,10 @@ do { \
#define SEEPROM_DATA_INB(sd) \ #define SEEPROM_DATA_INB(sd) \
ahc_inb(sd->sd_ahc, sd->sd_dataout_offset) ahc_inb(sd->sd_ahc, sd->sd_dataout_offset)
int read_seeprom(struct seeprom_descriptor *sd, uint16_t *buf, int ahc_read_seeprom(struct seeprom_descriptor *sd, uint16_t *buf,
u_int start_addr, u_int count); u_int start_addr, u_int count);
int verify_cksum(struct seeprom_config *sc); int ahc_write_seeprom(struct seeprom_descriptor *sd, uint16_t *buf,
u_int start_addr, u_int count);
int ahc_verify_cksum(struct seeprom_config *sc);
#endif /* _AIC7XXX_93CX6_H_ */ #endif /* _AIC7XXX_93CX6_H_ */
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* Assembler for the sequencer program downloaded to Aic7xxx SCSI host adapters * Assembler for the sequencer program downloaded to Aic7xxx SCSI host adapters
* *
* Copyright (c) 1997 Justin T. Gibbs. * Copyright (c) 1997 Justin T. Gibbs.
* Copyright (c) 2001 Adaptec Inc. * Copyright (c) 2001, 2002 Adaptec Inc.
* All rights reserved. * All rights reserved.
* *
* Redistribution and use in source and binary forms, with or without * Redistribution and use in source and binary forms, with or without
...@@ -37,9 +37,9 @@ ...@@ -37,9 +37,9 @@
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGES. * POSSIBILITY OF SUCH DAMAGES.
* *
* $Id: //depot/aic7xxx/aic7xxx/aicasm/aicasm.h#7 $ * $Id: //depot/aic7xxx/aic7xxx/aicasm/aicasm.h#14 $
* *
* $FreeBSD: src/sys/dev/aic7xxx/aicasm/aicasm.h,v 1.11 2000/09/22 22:19:54 gibbs Exp $ * $FreeBSD$
*/ */
#ifdef __linux__ #ifdef __linux__
...@@ -76,12 +76,19 @@ extern struct scope_list scope_stack; ...@@ -76,12 +76,19 @@ extern struct scope_list scope_stack;
extern struct symlist patch_functions; extern struct symlist patch_functions;
extern int includes_search_curdir; /* False if we've seen -I- */ extern int includes_search_curdir; /* False if we've seen -I- */
extern char *appname; extern char *appname;
extern char *stock_include_file;
extern int yylineno; extern int yylineno;
extern char *yyfilename; extern char *yyfilename;
extern char *prefix;
extern char *patch_arg_list;
extern char *versions; extern char *versions;
extern int src_mode;
extern int dst_mode;
struct symbol;
void stop(const char *errstring, int err_code); void stop(const char *errstring, int err_code);
void include_file(char *file_name, include_type type); void include_file(char *file_name, include_type type);
void expand_macro(struct symbol *macro_symbol);
struct instruction *seq_alloc(void); struct instruction *seq_alloc(void);
struct critical_section *cs_alloc(void); struct critical_section *cs_alloc(void);
struct scope *scope_alloc(void); struct scope *scope_alloc(void);
......
This diff is collapsed.
...@@ -37,9 +37,9 @@ ...@@ -37,9 +37,9 @@
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGES. * POSSIBILITY OF SUCH DAMAGES.
* *
* $Id: //depot/aic7xxx/aic7xxx/aicasm/aicasm_insformat.h#7 $ * $Id: //depot/aic7xxx/aic7xxx/aicasm/aicasm_insformat.h#10 $
* *
* $FreeBSD: src/sys/dev/aic7xxx/aicasm/aicasm_insformat.h,v 1.3 2000/09/22 22:19:54 gibbs Exp $ * $FreeBSD: src/sys/dev/aic7xxx/aicasm/aicasm_insformat.h,v 1.3.2.3 2002/04/29 19:36:36 gibbs Exp $
*/ */
struct ins_format1 { struct ins_format1 {
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment