Home | History | Annotate | Line # | Download | only in i2o
      1  1.11    andvar /*	$NetBSD: dptivar.h,v 1.11 2024/07/06 10:09:15 andvar Exp $	*/
      2   1.1        ad 
      3   1.1        ad /*-
      4   1.1        ad  * Copyright (c) 2001 The NetBSD Foundation, Inc.
      5   1.1        ad  * All rights reserved.
      6   1.1        ad  *
      7   1.1        ad  * This code is derived from software contributed to The NetBSD Foundation
      8   1.1        ad  * by Andrew Doran.
      9   1.1        ad  *
     10   1.1        ad  * Redistribution and use in source and binary forms, with or without
     11   1.1        ad  * modification, are permitted provided that the following conditions
     12   1.1        ad  * are met:
     13   1.1        ad  * 1. Redistributions of source code must retain the above copyright
     14   1.1        ad  *    notice, this list of conditions and the following disclaimer.
     15   1.1        ad  * 2. Redistributions in binary form must reproduce the above copyright
     16   1.1        ad  *    notice, this list of conditions and the following disclaimer in the
     17   1.1        ad  *    documentation and/or other materials provided with the distribution.
     18   1.1        ad  *
     19   1.1        ad  * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
     20   1.1        ad  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
     21   1.1        ad  * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
     22   1.1        ad  * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
     23   1.1        ad  * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
     24   1.1        ad  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
     25   1.1        ad  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
     26   1.1        ad  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
     27   1.1        ad  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
     28   1.1        ad  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
     29   1.1        ad  * POSSIBILITY OF SUCH DAMAGE.
     30   1.1        ad  */
     31   1.1        ad 
     32   1.1        ad /*
     33   1.1        ad  * Copyright (c) 1996-2000 Distributed Processing Technology Corporation
     34   1.1        ad  * Copyright (c) 2000 Adaptec Corporation
     35   1.1        ad  * All rights reserved.
     36   1.1        ad  *
     37   1.1        ad  * TERMS AND CONDITIONS OF USE
     38   1.1        ad  *
     39   1.1        ad  * Redistribution and use in source form, with or without modification, are
     40   1.1        ad  * permitted provided that redistributions of source code must retain the
     41   1.1        ad  * above copyright notice, this list of conditions and the following disclaimer.
     42   1.1        ad  *
     43   1.1        ad  * This software is provided `as is' by Adaptec and any express or implied
     44   1.1        ad  * warranties, including, but not limited to, the implied warranties of
     45   1.1        ad  * merchantability and fitness for a particular purpose, are disclaimed. In no
     46   1.1        ad  * event shall Adaptec be liable for any direct, indirect, incidental, special,
     47   1.1        ad  * exemplary or consequential damages (including, but not limited to,
     48   1.1        ad  * procurement of substitute goods or services; loss of use, data, or profits;
     49   1.1        ad  * or business interruptions) however caused and on any theory of liability,
     50   1.1        ad  * whether in contract, strict liability, or tort (including negligence or
     51   1.1        ad  * otherwise) arising in any way out of the use of this driver software, even
     52   1.1        ad  * if advised of the possibility of such damage.
     53   1.1        ad  */
     54   1.1        ad 
     55   1.1        ad #ifndef	_I2O_DPTIVAR_H_
     56   1.1        ad #define	_I2O_DPTIVAR_H_
     57   1.1        ad 
     58   1.2        ad #define	DPTI_MAX_SEGS	17
     59   1.2        ad 
     60   1.1        ad /*
     61   1.1        ad  * Runtime state.
     62   1.1        ad  */
     63   1.1        ad struct dpti_softc {
     64   1.9       chs 	device_t sc_dev;
     65   1.1        ad 	int	sc_blinkled;
     66   1.1        ad };
     67   1.1        ad 
     68   1.1        ad struct dpti_ptbuf {
     69   1.6  christos 	void *	db_ptr;
     70   1.1        ad 	struct	proc *db_proc;
     71   1.1        ad 	int	db_size;
     72   1.1        ad 	int	db_out;
     73   1.2        ad 	int	db_nfrag;
     74   1.2        ad 	struct	iovec db_frags[DPTI_MAX_SEGS];
     75   1.1        ad };
     76   1.1        ad 
     77   1.1        ad /*
     78   1.1        ad  * Constants used by the `signature'.
     79   1.1        ad  */
     80   1.4     perry 
     81   1.3        ad /* I2O */
     82   1.1        ad #define	DPTI_VERSION		1
     83   1.1        ad #define	DPTI_REVISION		0
     84   1.1        ad #define	DPTI_SUBREVISION	0
     85   1.1        ad 
     86   1.1        ad #define	DPTI_YEAR		1
     87   1.1        ad #define	DPTI_MONTH		9
     88   1.1        ad #define	DPTI_DAY		12
     89   1.1        ad 
     90   1.3        ad /* EATA */
     91   1.3        ad #define	DPT_VERSION		1
     92   1.3        ad #define	DPT_REVISION		0
     93   1.3        ad #define	DPT_SUBREVISION		0
     94   1.3        ad 
     95   1.3        ad #define	DPT_YEAR		1
     96   1.3        ad #define	DPT_MONTH		9
     97   1.3        ad #define	DPT_DAY			12
     98   1.3        ad 
     99   1.1        ad /*
    100   1.1        ad  * ioctls.  We define only the lower 16 bits, since the DPT utilities don't
    101   1.1        ad  * seem to obey the ioctl encoding conventions of each platform - the high
    102   1.1        ad  * 16 bits are relatively meaningless.
    103   1.1        ad  */
    104   1.1        ad #define	DPT_EATAUSRCMD		0x4441
    105   1.1        ad #define	DPT_DEBUG		0x4442
    106   1.1        ad #define	DPT_SIGNATURE		0x4443
    107   1.1        ad #define	DPT_NUMCTRLS		0x4444
    108   1.1        ad #define	DPT_CTRLINFO		0x4445
    109   1.1        ad #define	DPT_STATINFO		0x4446
    110   1.1        ad #define	DPT_CLRSTAT		0x4447
    111   1.1        ad #define	DPT_SYSINFO		0x4448
    112   1.1        ad #define	DPT_TIMEOUT		0x4449
    113   1.1        ad #define	DPT_CONFIG		0x444a
    114   1.1        ad #define	DPT_BLINKLED		0x444b
    115   1.1        ad #define	DPT_I2OUSRCMD		0x444c
    116   1.1        ad #define	DPT_I2ORESCANCMD	0x444d
    117   1.1        ad #define	DPT_I2ORESETCMD		0x444e
    118   1.1        ad #define	DPT_TARGET_BUSY		0x444f
    119   1.1        ad 
    120   1.1        ad /*
    121   1.1        ad  * Controller and system info structures.
    122   1.1        ad  */
    123   1.1        ad struct dpt_ctlrinfo {
    124   1.1        ad 	u_int16_t	length;
    125   1.1        ad 	u_int16_t	drvrHBAnum;
    126   1.1        ad 	u_int32_t	baseAddr;
    127   1.1        ad 	u_int16_t	blinkState;
    128   1.1        ad 	u_int8_t	pciBusNum;
    129   1.1        ad 	u_int8_t	pciDeviceNum;
    130   1.1        ad 	u_int16_t	hbaFlags;
    131   1.1        ad 	u_int16_t	Interrupt;
    132   1.1        ad 	u_int32_t	reserved1;
    133   1.1        ad 	u_int32_t	reserved2;
    134   1.1        ad 	u_int32_t	reserved3;
    135   1.1        ad };
    136   1.2        ad #define	FLG_OSD_PCI_VALID 0x0001
    137   1.2        ad #define	FLG_OSD_DMA       0x0002
    138   1.2        ad #define	FLG_OSD_I2O       0x0004
    139   1.3        ad 
    140   1.3        ad struct dpt_eata_ctlrinfo {
    141   1.3        ad 	u_int8_t	state;
    142   1.3        ad 	u_int8_t	id;
    143   1.3        ad 	int		vect;
    144   1.3        ad 	int		base;
    145   1.3        ad 	int		njobs;
    146   1.3        ad 	int		qdepth;
    147   1.3        ad 	int		wakebase;
    148   1.3        ad 	u_long		sgsize;
    149   1.3        ad 	u_int		heads;
    150   1.3        ad 	u_int		sectors;
    151   1.3        ad 	u_int8_t	do_drive32;
    152   1.3        ad 	u_int8_t	busquiet;
    153   1.3        ad 	u_int8_t	idpal[4];
    154   1.3        ad 	u_int8_t	primary;
    155   1.3        ad 	u_int8_t	eataVersion;
    156   1.3        ad 	u_long		cpLength;
    157   1.3        ad 	u_long		spLength;
    158   1.3        ad 	u_int8_t	drqNum;
    159   1.3        ad 	u_int8_t	flag1;
    160   1.3        ad 	u_int8_t	flag2;
    161   1.3        ad };
    162   1.1        ad 
    163   1.1        ad struct dpt_targetbusy {
    164   1.1        ad 	u_long		channel;
    165   1.1        ad 	u_long		id;
    166   1.1        ad 	u_long		lun;
    167   1.1        ad 	u_long		isbusy;
    168   1.1        ad };
    169   1.1        ad 
    170   1.1        ad #if (!defined(dsDescription_size))
    171   1.1        ad # define dsDescription_size 46
    172   1.1        ad #endif
    173   1.1        ad 
    174   1.1        ad struct dpt_sig {
    175   1.1        ad 	char		dsSignature[6];      /* ALWAYS "dPtSiG" */
    176   1.1        ad 	u_int8_t	dsSigVersion;        /* sig version (currently 1) */
    177   1.1        ad 	u_int8_t	dsProcessorFamily;   /* what type of processor */
    178   1.1        ad 	u_int8_t	dsProcessor;         /* precise processor */
    179   1.1        ad 	u_int8_t	dsFiletype;          /* type of file */
    180   1.1        ad 	u_int8_t	dsFiletypeFlags;     /* flags to specify type, etc. */
    181   1.1        ad 	u_int8_t	dsOEM;               /* OEM file was created for */
    182   1.1        ad 	u_int32_t	dsOS;                /* which Operating systems */
    183   1.1        ad 	u_int16_t	dsCapabilities;      /* RAID levels, etc. */
    184   1.1        ad 	u_int16_t	dsDeviceSupp;        /* SCSI device types supported */
    185   1.1        ad 	u_int16_t	dsAdapterSupp;       /* DPT HBA families supported */
    186   1.1        ad 	u_int16_t	dsApplication;       /* applications file is for */
    187   1.1        ad 	u_int8_t	dsRequirements;      /* Other driver dependencies */
    188   1.1        ad 	u_int8_t	dsVersion;           /* 1 */
    189   1.1        ad 	u_int8_t	dsRevision;          /* 'J' */
    190   1.1        ad 	u_int8_t	dsSubRevision;       /* '9'   ' ' if N/A */
    191   1.1        ad 	u_int8_t	dsMonth;             /* creation month */
    192   1.1        ad 	u_int8_t	dsDay;               /* creation day */
    193   1.1        ad 	u_int8_t	dsYear;              /* creation year since 1980 (1993=13) */
    194   1.1        ad 	char		dsDescription[dsDescription_size];
    195   1.1        ad };
    196   1.1        ad 
    197   1.2        ad struct dpt_dparam {
    198   1.2        ad 	u_int16_t	cylinders;      /* Upto 1024 */
    199   1.2        ad 	u_int8_t	heads;          /* Upto 255 */
    200   1.2        ad 	u_int8_t	sectors;        /* Upto 63 */
    201   1.2        ad };
    202   1.2        ad 
    203   1.2        ad struct dpt_sysinfo {
    204   1.2        ad 	u_int8_t	drive0CMOS;             /* CMOS Drive 0 Type */
    205   1.2        ad 	u_int8_t	drive1CMOS;             /* CMOS Drive 1 Type */
    206   1.2        ad 	u_int8_t	numDrives;              /* 0040:0075 contents */
    207   1.2        ad 	u_int8_t	processorFamily;        /* Same as DPTSIG's defs */
    208   1.2        ad 	u_int8_t	processorType;          /* Same as DPTSIG's defs */
    209   1.2        ad 	u_int8_t	smartROMMajorVersion;
    210   1.2        ad 	u_int8_t	smartROMMinorVersion;   /* SmartROM version */
    211   1.2        ad 	u_int8_t	smartROMRevision;
    212   1.2        ad 	u_int16_t	flags;                  /* See bit definitions above */
    213   1.2        ad 	u_int16_t	conventionalMemSize;    /* in KB */
    214   1.2        ad 	u_int32_t	extendedMemSize;        /* in KB */
    215   1.2        ad 	u_int32_t	osType;                 /* Same as DPTSIG's defs */
    216   1.2        ad 	u_int8_t	osMajorVersion;
    217   1.2        ad 	u_int8_t	osMinorVersion;         /* The OS version */
    218   1.2        ad 	u_int8_t	osRevision;
    219   1.2        ad 	u_int8_t	osSubRevision;
    220  1.11    andvar 	u_int8_t	busType;                /* See definitions above */
    221   1.2        ad 	u_int8_t	pad[3];                 /* For alignment */
    222   1.2        ad 	struct	dpt_dparam drives[16];		/* SmartROM Logical Drives */
    223   1.2        ad };
    224   1.2        ad 
    225   1.2        ad /*
    226   1.2        ad  * Defs pertaining to dpt_sysinfo.
    227   1.2        ad  */
    228   1.2        ad 
    229   1.2        ad #define	SI_CMOS_Valid		0x0001
    230   1.2        ad #define	SI_NumDrivesValid	0x0002
    231   1.2        ad #define	SI_ProcessorValid	0x0004
    232   1.2        ad #define	SI_MemorySizeValid	0x0008
    233   1.2        ad #define	SI_DriveParamsValid	0x0010
    234   1.2        ad #define	SI_SmartROMverValid	0x0020
    235   1.2        ad #define	SI_OSversionValid	0x0040
    236   1.2        ad #define	SI_OSspecificValid	0x0080
    237   1.2        ad #define	SI_BusTypeValid		0x0100
    238   1.2        ad #define	SI_ALL_VALID            0x0FFF
    239   1.2        ad #define	SI_NO_SmartROM          0x8000
    240   1.2        ad 
    241   1.2        ad #define	SI_ISA_BUS	0x00
    242   1.2        ad #define	SI_MCA_BUS	0x01
    243   1.2        ad #define	SI_EISA_BUS	0x02
    244   1.2        ad #define	SI_PCI_BUS	0x04
    245   1.2        ad 
    246   1.2        ad 
    247   1.1        ad /*
    248   1.2        ad  * Defs pertaining to dpt_sig.
    249   1.1        ad  */
    250   1.1        ad 
    251   1.1        ad /* Current Signature Version - u_int8_t dsSigVersion; */
    252   1.1        ad /* ------------------------------------------------------------------ */
    253   1.2        ad #define	SIG_VERSION 1
    254   1.1        ad 
    255   1.1        ad /* Processor Family - u_int8_t dsProcessorFamily;  DISTINCT VALUES */
    256   1.1        ad /* ------------------------------------------------------------------ */
    257   1.1        ad /* What type of processor the file is meant to run on. */
    258   1.1        ad /* This will let us know whether to read u_int16_ts as high/low or low/high. */
    259   1.2        ad #define	PROC_INTEL      0x00    /* Intel 80x86 */
    260   1.2        ad #define	PROC_MOTOROLA   0x01    /* Motorola 68K */
    261   1.2        ad #define	PROC_MIPS4000   0x02    /* MIPS RISC 4000 */
    262   1.2        ad #define	PROC_MIPS       0x02	/* MIPS RISC */
    263   1.2        ad #define	PROC_ALPHA      0x03    /* DEC Alpha */
    264   1.2        ad #define	PROC_POWERPC    0x04    /* IBM Power PC */
    265   1.2        ad #define	PROC_i960       0x05    /* Intel i960 */
    266   1.2        ad #define	PROC_ULTRASPARC 0x06    /* SPARC processor */
    267   1.1        ad 
    268  1.10    andvar /* Specific Minimum Processor - u_int8_t dsProcessor;    FLAG BITS */
    269   1.1        ad /* ------------------------------------------------------------------ */
    270   1.1        ad /* Different bit definitions dependent on processor_family */
    271   1.1        ad 
    272   1.1        ad /* PROC_INTEL: */
    273   1.2        ad #define	PROC_8086       0x01    /* Intel 8086 */
    274   1.2        ad #define	PROC_286        0x02    /* Intel 80286 */
    275   1.2        ad #define	PROC_386        0x04    /* Intel 80386 */
    276   1.2        ad #define	PROC_486        0x08    /* Intel 80486 */
    277   1.2        ad #define	PROC_PENTIUM    0x10    /* Intel 586 aka P5 aka Pentium */
    278   1.2        ad #define	PROC_SEXIUM     0x20    /* Intel 686 aka P6 aka Pentium Pro or MMX */
    279   1.1        ad 
    280   1.1        ad /* PROC_i960: */
    281   1.2        ad #define	PROC_960RX      0x01    /* Intel 80960RP/RD */
    282   1.2        ad #define	PROC_960HX      0x02    /* Intel 80960HA/HD/HT */
    283   1.2        ad #define	PROC_960RN      0x03    /* Intel 80960RN/RM */
    284   1.2        ad #define	PROC_960RS      0x04    /* Intel 80960RS */
    285   1.1        ad 
    286   1.1        ad /* PROC_MOTOROLA: */
    287   1.2        ad #define	PROC_68000      0x01    /* Motorola 68000 */
    288   1.2        ad #define	PROC_68010      0x02    /* Motorola 68010 */
    289   1.2        ad #define	PROC_68020      0x04    /* Motorola 68020 */
    290   1.2        ad #define	PROC_68030      0x08    /* Motorola 68030 */
    291   1.2        ad #define	PROC_68040      0x10    /* Motorola 68040 */
    292   1.1        ad 
    293   1.1        ad /* PROC_POWERPC */
    294   1.2        ad #define	PROC_PPC601             0x01    /* PowerPC 601 */
    295   1.2        ad #define	PROC_PPC603             0x02    /* PowerPC 603 */
    296   1.2        ad #define	PROC_PPC604             0x04    /* PowerPC 604 */
    297   1.1        ad 
    298   1.1        ad /* PROC_MIPS */
    299   1.2        ad #define	PROC_R4000      0x01    /* MIPS R4000 */
    300   1.2        ad #define	PROC_RM7000     0x02    /* MIPS RM7000 */
    301   1.1        ad 
    302   1.1        ad /* Filetype - u_int8_t dsFiletype;       DISTINCT VALUES */
    303   1.1        ad /* ------------------------------------------------------------------ */
    304   1.2        ad #define	FT_EXECUTABLE   0       /* Executable Program */
    305   1.2        ad #define	FT_SCRIPT       1       /* Script/Batch File??? */
    306   1.2        ad #define	FT_HBADRVR      2       /* HBA Driver */
    307   1.2        ad #define	FT_OTHERDRVR    3       /* Other Driver */
    308   1.2        ad #define	FT_IFS          4       /* Installable Filesystem Driver */
    309   1.2        ad #define	FT_ENGINE       5       /* DPT Engine */
    310   1.2        ad #define	FT_COMPDRVR     6       /* Compressed Driver Disk */
    311   1.2        ad #define	FT_LANGUAGE     7       /* Foreign Language file */
    312   1.2        ad #define	FT_FIRMWARE     8       /* Downloadable or actual Firmware */
    313   1.2        ad #define	FT_COMMMODL     9       /* Communications Module */
    314   1.2        ad #define	FT_INT13        10      /* INT 13 style HBA Driver */
    315   1.2        ad #define	FT_HELPFILE     11      /* Help file */
    316   1.2        ad #define	FT_LOGGER       12      /* Event Logger */
    317   1.2        ad #define	FT_INSTALL      13      /* An Install Program */
    318   1.2        ad #define	FT_LIBRARY      14      /* Storage Manager Real-Mode Calls */
    319   1.2        ad #define	FT_RESOURCE     15      /* Storage Manager Resource File */
    320   1.2        ad #define	FT_MODEM_DB     16      /* Storage Manager Modem Database */
    321   1.1        ad 
    322   1.1        ad /* Filetype flags - u_int8_t dsFiletypeFlags;    FLAG BITS */
    323   1.1        ad /* ------------------------------------------------------------------ */
    324   1.2        ad #define	FTF_DLL         0x01    /* Dynamic Link Library */
    325   1.2        ad #define	FTF_NLM         0x02    /* Netware Loadable Module */
    326   1.2        ad #define	FTF_OVERLAYS    0x04    /* Uses overlays */
    327   1.2        ad #define	FTF_DEBUG       0x08    /* Debug version */
    328   1.2        ad #define	FTF_TSR         0x10    /* TSR */
    329   1.2        ad #define	FTF_SYS         0x20    /* DOS Loadable driver */
    330   1.2        ad #define	FTF_PROTECTED   0x40    /* Runs in protected mode */
    331   1.2        ad #define	FTF_APP_SPEC    0x80    /* Application Specific */
    332   1.2        ad #define	FTF_ROM         (FTF_SYS|FTF_TSR)       /* Special Case */
    333   1.1        ad 
    334   1.1        ad /* OEM - u_int8_t dsOEM;         DISTINCT VALUES */
    335   1.1        ad /* ------------------------------------------------------------------ */
    336   1.2        ad #define	OEM_DPT         0       /* DPT */
    337   1.2        ad #define	OEM_ATT         1       /* ATT */
    338   1.2        ad #define	OEM_NEC         2       /* NEC */
    339   1.2        ad #define	OEM_ALPHA       3       /* Alphatronix */
    340   1.2        ad #define	OEM_AST         4       /* AST */
    341   1.2        ad #define	OEM_OLIVETTI    5       /* Olivetti */
    342   1.2        ad #define	OEM_SNI         6       /* Siemens/Nixdorf */
    343   1.2        ad #define	OEM_SUN         7       /* SUN Microsystems */
    344   1.2        ad #define	OEM_ADAPTEC     8       /* Adaptec */
    345   1.1        ad 
    346   1.1        ad /* Operating System  - u_int32_t dsOS;    FLAG BITS */
    347   1.1        ad /* ------------------------------------------------------------------ */
    348   1.2        ad #define	OS_DOS          0x00000001 /* PC/MS-DOS                         */
    349   1.2        ad #define	OS_WINDOWS      0x00000002 /* Microsoft Windows 3.x             */
    350   1.2        ad #define	OS_WINDOWS_NT   0x00000004 /* Microsoft Windows NT              */
    351   1.2        ad #define	OS_OS2M         0x00000008 /* OS/2 1.2.x,MS 1.3.0,IBM 1.3.x - Monolithic */
    352   1.2        ad #define	OS_OS2L         0x00000010 /* Microsoft OS/2 1.301 - LADDR      */
    353   1.2        ad #define	OS_OS22x        0x00000020 /* IBM OS/2 2.x                      */
    354   1.2        ad #define	OS_NW286        0x00000040 /* Novell NetWare 286                */
    355   1.2        ad #define	OS_NW386        0x00000080 /* Novell NetWare 386                */
    356   1.2        ad #define	OS_GEN_UNIX     0x00000100 /* Generic Unix                      */
    357   1.2        ad #define	OS_SCO_UNIX     0x00000200 /* SCO Unix                          */
    358   1.2        ad #define	OS_ATT_UNIX     0x00000400 /* ATT Unix                          */
    359   1.2        ad #define	OS_UNIXWARE     0x00000800 /* USL Unix                          */
    360   1.2        ad #define	OS_INT_UNIX     0x00001000 /* Interactive Unix                  */
    361   1.2        ad #define	OS_SOLARIS      0x00002000 /* SunSoft Solaris                   */
    362   1.2        ad #define	OS_QNX          0x00004000 /* QNX for Tom Moch                  */
    363   1.2        ad #define	OS_NEXTSTEP     0x00008000 /* NeXTSTEP/OPENSTEP/MACH            */
    364   1.2        ad #define	OS_BANYAN       0x00010000 /* Banyan Vines                      */
    365   1.2        ad #define	OS_OLIVETTI_UNIX 0x00020000/* Olivetti Unix                     */
    366   1.2        ad #define	OS_MAC_OS       0x00040000 /* Mac OS                    	*/
    367   1.2        ad #define	OS_WINDOWS_95   0x00080000 /* Microsoft Windows '95             */
    368   1.2        ad #define	OS_NW4x         0x00100000 /* Novell Netware 4.x        	*/
    369   1.2        ad #define	OS_BSDI_UNIX    0x00200000 /* BSDi Unix BSD/OS 2.0 and up       */
    370   1.2        ad #define	OS_AIX_UNIX     0x00400000 /* AIX Unix                          */
    371   1.2        ad #define	OS_FREE_BSD     0x00800000 /* FreeBSD Unix              	*/
    372   1.2        ad #define	OS_LINUX        0x01000000 /* Linux                    	 	*/
    373   1.2        ad #define	OS_DGUX_UNIX    0x02000000 /* Data General Unix                 */
    374   1.2        ad #define	OS_SINIX_N      0x04000000 /* SNI SINIX-N                       */
    375   1.2        ad #define	OS_PLAN9        0x08000000 /* ATT Plan 9             		*/
    376   1.2        ad #define	OS_TSX          0x10000000 /* SNH TSX-32              	  	*/
    377   1.2        ad #define	OS_WINDOWS_98   0x20000000 /* Microsoft Windows '98    		*/
    378   1.1        ad 
    379   1.2        ad #define	OS_OTHER        0x80000000 /* Other                             */
    380   1.1        ad 
    381   1.1        ad /* Capabilities - u_int16_t dsCapabilities;        FLAG BITS */
    382   1.1        ad /* ------------------------------------------------------------------ */
    383   1.2        ad #define	CAP_RAID0       0x0001  /* RAID-0 */
    384   1.2        ad #define	CAP_RAID1       0x0002  /* RAID-1 */
    385   1.2        ad #define	CAP_RAID3       0x0004  /* RAID-3 */
    386   1.2        ad #define	CAP_RAID5       0x0008  /* RAID-5 */
    387   1.2        ad #define	CAP_SPAN        0x0010  /* Spanning */
    388   1.2        ad #define	CAP_PASS        0x0020  /* Provides passthrough */
    389   1.2        ad #define	CAP_OVERLAP     0x0040  /* Passthrough supports overlapped commands */
    390   1.2        ad #define	CAP_ASPI        0x0080  /* Supports ASPI Command Requests */
    391   1.2        ad #define	CAP_ABOVE16MB   0x0100  /* ISA Driver supports greater than 16MB */
    392   1.2        ad #define	CAP_EXTEND      0x8000  /* Extended info appears after description */
    393   1.1        ad #ifdef SNI_MIPS
    394   1.2        ad #define	CAP_CACHEMODE   0x1000  /* dpt_force_cache is set in driver */
    395   1.1        ad #endif
    396   1.1        ad 
    397   1.1        ad /* Devices Supported - u_int16_t dsDeviceSupp;    FLAG BITS */
    398   1.1        ad /* ------------------------------------------------------------------ */
    399   1.2        ad #define	DEV_DASD        0x0001  /* DASD (hard drives) */
    400   1.2        ad #define	DEV_TAPE        0x0002  /* Tape drives */
    401   1.2        ad #define	DEV_PRINTER     0x0004  /* Printers */
    402   1.2        ad #define	DEV_PROC        0x0008  /* Processors */
    403   1.2        ad #define	DEV_WORM        0x0010  /* WORM drives */
    404   1.2        ad #define	DEV_CDROM       0x0020  /* CD-ROM drives */
    405   1.2        ad #define	DEV_SCANNER     0x0040  /* Scanners */
    406   1.2        ad #define	DEV_OPTICAL     0x0080  /* Optical Drives */
    407   1.2        ad #define	DEV_JUKEBOX     0x0100  /* Jukebox */
    408   1.2        ad #define	DEV_COMM        0x0200  /* Communications Devices */
    409   1.2        ad #define	DEV_OTHER       0x0400  /* Other Devices */
    410   1.2        ad #define	DEV_ALL         0xFFFF  /* All SCSI Devices */
    411   1.1        ad 
    412   1.1        ad /* Adapters Families Supported - u_int16_t dsAdapterSupp; FLAG BITS */
    413   1.1        ad /* ------------------------------------------------------------------ */
    414   1.2        ad #define	ADF_2001        0x0001  /* PM2001           */
    415   1.2        ad #define	ADF_2012A       0x0002  /* PM2012A          */
    416   1.2        ad #define	ADF_PLUS_ISA    0x0004  /* PM2011,PM2021    */
    417   1.2        ad #define	ADF_PLUS_EISA   0x0008  /* PM2012B,PM2022   */
    418   1.2        ad #define	ADF_SC3_ISA     0x0010  /* PM2021           */
    419   1.2        ad #define	ADF_SC3_EISA    0x0020  /* PM2022,PM2122, etc */
    420   1.2        ad #define	ADF_SC3_PCI     0x0040  /* SmartCache III PCI */
    421   1.2        ad #define	ADF_SC4_ISA     0x0080  /* SmartCache IV ISA */
    422   1.2        ad #define	ADF_SC4_EISA    0x0100  /* SmartCache IV EISA */
    423   1.2        ad #define	ADF_SC4_PCI     0x0200  /* SmartCache IV PCI */
    424   1.2        ad #define	ADF_SC5_PCI     0x0400  /* Fifth Generation I2O products */
    425   1.1        ad /*
    426   1.1        ad  *      Combinations of products
    427   1.1        ad  */
    428   1.2        ad #define	ADF_ALL_2000    (ADF_2001|ADF_2012A)
    429   1.2        ad #define	ADF_ALL_PLUS    (ADF_PLUS_ISA|ADF_PLUS_EISA)
    430   1.2        ad #define	ADF_ALL_SC3     (ADF_SC3_ISA|ADF_SC3_EISA|ADF_SC3_PCI)
    431   1.2        ad #define	ADF_ALL_SC4     (ADF_SC4_ISA|ADF_SC4_EISA|ADF_SC4_PCI)
    432   1.2        ad #define	ADF_ALL_SC5     (ADF_SC5_PCI)
    433   1.1        ad /* All EATA Cacheing Products */
    434   1.2        ad #define	ADF_ALL_CACHE   (ADF_ALL_PLUS|ADF_ALL_SC3|ADF_ALL_SC4)
    435   1.1        ad /* All EATA Bus Mastering Products */
    436   1.2        ad #define	ADF_ALL_MASTER  (ADF_2012A|ADF_ALL_CACHE)
    437   1.1        ad /* All EATA Adapter Products */
    438   1.2        ad #define	ADF_ALL_EATA    (ADF_2001|ADF_ALL_MASTER)
    439   1.2        ad #define	ADF_ALL         ADF_ALL_EATA
    440   1.1        ad 
    441   1.1        ad /* Application - u_int16_t dsApplication;         FLAG BITS */
    442   1.1        ad /* ------------------------------------------------------------------ */
    443   1.2        ad #define	APP_DPTMGR      0x0001  /* DPT Storage Manager */
    444   1.2        ad #define	APP_ENGINE      0x0002  /* DPT Engine */
    445   1.2        ad #define	APP_SYTOS       0x0004  /* Sytron Sytos Plus */
    446   1.2        ad #define	APP_CHEYENNE    0x0008  /* Cheyenne ARCServe + ARCSolo */
    447   1.2        ad #define	APP_MSCDEX      0x0010  /* Microsoft CD-ROM extensions */
    448   1.2        ad #define	APP_NOVABACK    0x0020  /* NovaStor Novaback */
    449   1.2        ad #define	APP_AIM         0x0040  /* Archive Information Manager */
    450   1.1        ad 
    451   1.1        ad /* Requirements - u_int8_t dsRequirements;         FLAG BITS            */
    452   1.1        ad /* ------------------------------------------------------------------   */
    453   1.2        ad #define	REQ_SMARTROM    0x01    /* Requires SmartROM to be present      */
    454   1.2        ad #define	REQ_DPTDDL      0x02    /* Requires DPTDDL.SYS to be loaded     */
    455   1.2        ad #define	REQ_HBA_DRIVER  0x04    /* Requires an HBA driver to be loaded  */
    456   1.2        ad #define	REQ_ASPI_TRAN   0x08    /* Requires an ASPI Transport Modules   */
    457   1.2        ad #define	REQ_ENGINE      0x10    /* Requires a DPT Engine to be loaded   */
    458   1.2        ad #define	REQ_COMM_ENG    0x20    /* Requires a DPT Communications Engine */
    459   1.1        ad 
    460   1.1        ad /* ------------------------------------------------------------------   */
    461   1.1        ad /* Requirements - u_int16_t dsFirmware;         FLAG BITS               */
    462   1.1        ad /* ------------------------------------------------------------------   */
    463   1.2        ad #define	dsFirmware dsApplication
    464   1.2        ad #define	FW_DNLDSIZE0      0x0000    /* 0..2 DownLoader Size - NONE      */
    465   1.2        ad #define	FW_DNLDSIZE16     0x0001    /* 0..2 DownLoader Size 16K         */
    466   1.2        ad #define	FW_DNLDSIZE32     0x0002    /* 0..2 DownLoader Size 32K         */
    467   1.2        ad #define	FW_DNLDSIZE64     0x0004    /* 0..2 DownLoader Size 64K         */
    468   1.2        ad 
    469   1.2        ad #define	FW_LOAD_BTM       0x2000        /* 13 Load Offset (1=Btm, 0=Top)    */
    470   1.2        ad #define	FW_LOAD_TOP       0x0000        /* 13 Load Offset (1=Btm, 0=Top)    */
    471   1.2        ad #define	FW_SIG_VERSION1   0x0000        /* 15..14 Version Bits 0=Ver1       */
    472   1.1        ad 
    473   1.1        ad #endif	/* !_I2O_DPTIVAR_H_ */
    474