Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Typedefs
tmscsim.h File Reference
#include <linux/types.h>

Go to the source code of this file.

Data Structures

struct  dc390_srb
 
struct  dc390_dcb
 
struct  dc390_acb
 
struct  dc390_cmd_scp_t
 
struct  _EEprom
 

Macros

#define SCSI_IRQ_NONE   255
 
#define MAX_ADAPTER_NUM   4
 
#define MAX_SG_LIST_BUF   16 /* Not used */
 
#define MAX_SCSI_ID   8
 
#define MAX_SRB_CNT   50 /* Max number of started commands */
 
#define SEL_TIMEOUT   153 /* 250 ms selection timeout (@ 40 MHz) */
 
#define BIT31   0x80000000
 
#define BIT30   0x40000000
 
#define BIT29   0x20000000
 
#define BIT28   0x10000000
 
#define BIT27   0x08000000
 
#define BIT26   0x04000000
 
#define BIT25   0x02000000
 
#define BIT24   0x01000000
 
#define BIT23   0x00800000
 
#define BIT22   0x00400000
 
#define BIT21   0x00200000
 
#define BIT20   0x00100000
 
#define BIT19   0x00080000
 
#define BIT18   0x00040000
 
#define BIT17   0x00020000
 
#define BIT16   0x00010000
 
#define BIT15   0x00008000
 
#define BIT14   0x00004000
 
#define BIT13   0x00002000
 
#define BIT12   0x00001000
 
#define BIT11   0x00000800
 
#define BIT10   0x00000400
 
#define BIT9   0x00000200
 
#define BIT8   0x00000100
 
#define BIT7   0x00000080
 
#define BIT6   0x00000040
 
#define BIT5   0x00000020
 
#define BIT4   0x00000010
 
#define BIT3   0x00000008
 
#define BIT2   0x00000004
 
#define BIT1   0x00000002
 
#define BIT0   0x00000001
 
#define UNIT_ALLOCATED   BIT0
 
#define UNIT_INFO_CHANGED   BIT1
 
#define FORMATING_MEDIA   BIT2
 
#define UNIT_RETRY   BIT3
 
#define DASD_SUPPORT   BIT0
 
#define SCSI_SUPPORT   BIT1
 
#define ASPI_SUPPORT   BIT2
 
#define SRB_FREE   0
 
#define SRB_WAIT   BIT0
 
#define SRB_READY   BIT1
 
#define SRB_MSGOUT   BIT2 /*;arbitration+msg_out 1st byte*/
 
#define SRB_MSGIN   BIT3
 
#define SRB_MSGIN_MULTI   BIT4
 
#define SRB_COMMAND   BIT5
 
#define SRB_START_   BIT6 /*;arbitration+msg_out+command_out*/
 
#define SRB_DISCONNECT   BIT7
 
#define SRB_DATA_XFER   BIT8
 
#define SRB_XFERPAD   BIT9
 
#define SRB_STATUS   BIT10
 
#define SRB_COMPLETED   BIT11
 
#define SRB_ABORT_SENT   BIT12
 
#define DO_SYNC_NEGO   BIT13
 
#define SRB_UNEXPECT_RESEL   BIT14
 
#define SRB_OK   BIT0
 
#define ABORTION   BIT1
 
#define OVER_RUN   BIT2
 
#define UNDER_RUN   BIT3
 
#define PARITY_ERROR   BIT4
 
#define SRB_ERROR   BIT5
 
#define RESET_DEV   BIT0
 
#define RESET_DETECT   BIT1
 
#define RESET_DONE   BIT2
 
#define ABORT_DEV_   BIT0
 
#define DATAOUT   BIT7
 
#define DATAIN   BIT6
 
#define RESIDUAL_VALID   BIT5
 
#define ENABLE_TIMER   BIT4
 
#define RESET_DEV0   BIT2
 
#define ABORT_DEV   BIT1
 
#define AUTO_REQSENSE   BIT0
 
#define H_STATUS_GOOD   0
 
#define H_SEL_TIMEOUT   0x11
 
#define H_OVER_UNDER_RUN   0x12
 
#define H_UNEXP_BUS_FREE   0x13
 
#define H_TARGET_PHASE_F   0x14
 
#define H_INVALID_CCB_OP   0x16
 
#define H_LINK_CCB_BAD   0x17
 
#define H_BAD_TARGET_DIR   0x18
 
#define H_DUPLICATE_CCB   0x19
 
#define H_BAD_CCB_OR_SG   0x1A
 
#define H_ABORT   0x0FF
 
#define RES_TARGET   0x000000FF /* Target State */
 
#define RES_TARGET_LNX   STATUS_MASK /* Only official ... */
 
#define RES_ENDMSG   0x0000FF00 /* End Message */
 
#define RES_DID   0x00FF0000 /* DID_ codes */
 
#define RES_DRV   0xFF000000 /* DRIVER_ codes */
 
#define MK_RES(drv, did, msg, tgt)   ((int)(drv)<<24 | (int)(did)<<16 | (int)(msg)<<8 | (int)(tgt))
 
#define MK_RES_LNX(drv, did, msg, tgt)   ((int)(drv)<<24 | (int)(did)<<16 | (int)(msg)<<8 | (int)(tgt))
 
#define SET_RES_TARGET(who, tgt)   do { who &= ~RES_TARGET; who |= (int)(tgt); } while (0)
 
#define SET_RES_TARGET_LNX(who, tgt)   do { who &= ~RES_TARGET_LNX; who |= (int)(tgt) << 1; } while (0)
 
#define SET_RES_MSG(who, msg)   do { who &= ~RES_ENDMSG; who |= (int)(msg) << 8; } while (0)
 
#define SET_RES_DID(who, did)   do { who &= ~RES_DID; who |= (int)(did) << 16; } while (0)
 
#define SET_RES_DRV(who, drv)   do { who &= ~RES_DRV; who |= (int)(drv) << 24; } while (0)
 
#define SYNC_DISABLE   0
 
#define SYNC_ENABLE   BIT0
 
#define SYNC_NEGO_DONE   BIT1
 
#define WIDE_ENABLE   BIT2 /* Not used ;-) */
 
#define WIDE_NEGO_DONE   BIT3 /* Not used ;-) */
 
#define EN_TAG_QUEUEING   BIT4
 
#define EN_ATN_STOP   BIT5
 
#define SYNC_NEGO_OFFSET   15
 
#define SCSI_DATA_OUT   0
 
#define SCSI_DATA_IN   1
 
#define SCSI_COMMAND   2
 
#define SCSI_STATUS_   3
 
#define SCSI_NOP0   4
 
#define SCSI_NOP1   5
 
#define SCSI_MSG_OUT   6
 
#define SCSI_MSG_IN   7
 
#define ABORT_TAG   0x0d
 
#define REAL_EE_ADAPT_SCSI_ID   64
 
#define REAL_EE_MODE2   65
 
#define REAL_EE_DELAY   66
 
#define REAL_EE_TAG_CMD_NUM   67
 
#define EE_ADAPT_SCSI_ID   32
 
#define EE_MODE2   33
 
#define EE_DELAY   34
 
#define EE_TAG_CMD_NUM   35
 
#define EE_LEN   40
 
#define PARITY_CHK_   BIT0
 
#define SYNC_NEGO_   BIT1
 
#define EN_DISCONNECT_   BIT2
 
#define SEND_START_   BIT3
 
#define TAG_QUEUEING_   BIT4
 
#define MORE2_DRV   BIT0
 
#define GREATER_1G   BIT1
 
#define RST_SCSI_BUS   BIT2
 
#define ACTIVE_NEGATION   BIT3
 
#define NO_SEEK   BIT4
 
#define LUN_CHECK   BIT5
 
#define ENABLE_CE   1
 
#define DISABLE_CE   0
 
#define EEPROM_READ   0x80
 
#define DMA_COMMAND   BIT7
 
#define NOP_CMD   0
 
#define CLEAR_FIFO_CMD   1
 
#define RST_DEVICE_CMD   2
 
#define RST_SCSI_BUS_CMD   3
 
#define INFO_XFER_CMD   0x10
 
#define INITIATOR_CMD_CMPLTE   0x11
 
#define MSG_ACCEPTED_CMD   0x12
 
#define XFER_PAD_BYTE   0x18
 
#define SET_ATN_CMD   0x1A
 
#define RESET_ATN_CMD   0x1B
 
#define SEL_WO_ATN   0x41 /* currently not used */
 
#define SEL_W_ATN   0x42
 
#define SEL_W_ATN_STOP   0x43
 
#define SEL_W_ATN3   0x46
 
#define EN_SEL_RESEL   0x44
 
#define DIS_SEL_RESEL   0x45 /* currently not used */
 
#define RESEL   0x40 /* " */
 
#define RESEL_ATN3   0x47 /* " */
 
#define DATA_XFER_CMD   INFO_XFER_CMD
 
#define INTERRUPT   BIT7
 
#define ILLEGAL_OP_ERR   BIT6
 
#define PARITY_ERR   BIT5
 
#define COUNT_2_ZERO   BIT4
 
#define GROUP_CODE_VALID   BIT3
 
#define SCSI_PHASE_MASK   (BIT2+BIT1+BIT0)
 
#define SCSI_RESET   BIT7
 
#define INVALID_CMD   BIT6
 
#define DISCONNECTED   BIT5
 
#define SERVICE_REQUEST   BIT4
 
#define SUCCESSFUL_OP   BIT3
 
#define RESELECTED   BIT2
 
#define SEL_ATTENTION   BIT1
 
#define SELECTED   BIT0
 
#define SYNC_OFFSET_FLAG   BIT3
 
#define INTRN_STATE_MASK   (BIT2+BIT1+BIT0)
 
#define CLK_FREQ_40MHZ   0
 
#define CLK_FREQ_35MHZ   (BIT2+BIT1+BIT0)
 
#define CLK_FREQ_30MHZ   (BIT2+BIT1)
 
#define CLK_FREQ_25MHZ   (BIT2+BIT0)
 
#define CLK_FREQ_20MHZ   BIT2
 
#define CLK_FREQ_15MHZ   (BIT1+BIT0)
 
#define CLK_FREQ_10MHZ   BIT1
 
#define EXTENDED_TIMING   BIT7
 
#define DIS_INT_ON_SCSI_RST   BIT6
 
#define PARITY_ERR_REPO   BIT4
 
#define SCSI_ID_ON_BUS   (BIT2+BIT1+BIT0) /* host adapter ID */
 
#define EN_FEATURE   BIT6
 
#define EN_SCSI2_CMD   BIT3
 
#define ID_MSG_CHECK   BIT7
 
#define EN_QTAG_MSG   BIT6
 
#define EN_GRP2_CMD   BIT5
 
#define FAST_SCSI   BIT4 /* ;10MB/SEC */
 
#define FAST_CLK   BIT3 /* ;25 - 40 MHZ */
 
#define EATER_12NS   0
 
#define EATER_25NS   BIT7
 
#define EATER_35NS   BIT6
 
#define EATER_0NS   (BIT7+BIT6)
 
#define REDUCED_POWER   BIT5
 
#define CTRL4_RESERVED   BIT4 /* must be 1 acc. to AM53C974.c */
 
#define NEGATE_REQACKDATA   BIT2
 
#define NEGATE_REQACK   BIT3
 
#define GLITCH_TO_NS(x)   (((~x>>6 & 2) >> 1) | ((x>>6 & 1) << 1 ^ (x>>6 & 2)))
 
#define NS_TO_GLITCH(y)   (((~y<<7) | ~((y<<6) ^ ((y<<5 & 1<<6) | ~0x40))) & 0xc0)
 
#define READ_DIRECTION   BIT7
 
#define WRITE_DIRECTION   0
 
#define EN_DMA_INT   BIT6
 
#define EN_PAGE_INT   BIT5 /* page transfer interrupt enable */
 
#define MAP_TO_MDL   BIT4
 
#define DIAGNOSTIC   BIT2
 
#define DMA_IDLE_CMD   0
 
#define DMA_BLAST_CMD   BIT0
 
#define DMA_ABORT_CMD   BIT1
 
#define DMA_START_CMD   (BIT1+BIT0)
 
#define PCI_MS_ABORT   BIT6
 
#define BLAST_COMPLETE   BIT5
 
#define SCSI_INTERRUPT   BIT4
 
#define DMA_XFER_DONE   BIT3
 
#define DMA_XFER_ABORT   BIT2
 
#define DMA_XFER_ERROR   BIT1
 
#define POWER_DOWN   BIT0
 
#define EN_INT_ON_PCI_ABORT   BIT25
 
#define WRT_ERASE_DMA_STAT   BIT24
 
#define PW_DOWN_CTRL   BIT21
 
#define SCSI_BUSY   BIT20
 
#define SCLK   BIT19
 
#define SCAM   BIT18
 
#define SCSI_LINES   0x0003ffff
 
#define CtcReg_Low   0x00 /* r curr. transfer count */
 
#define CtcReg_Mid   0x04 /* r */
 
#define CtcReg_High   0x38 /* r */
 
#define ScsiFifo   0x08
 
#define ScsiCmd   0x0C
 
#define Scsi_Status   0x10 /* r */
 
#define INT_Status   0x14 /* r */
 
#define Sync_Period   0x18 /* w */
 
#define Sync_Offset   0x1C /* w */
 
#define Clk_Factor   0x24 /* w */
 
#define CtrlReg1   0x20
 
#define CtrlReg2   0x2C
 
#define CtrlReg3   0x30
 
#define CtrlReg4   0x34
 
#define DMA_Cmd   0x40
 
#define DMA_XferCnt   0x44 /* rw starting transfer count (32 bit) */
 
#define DMA_XferAddr   0x48 /* rw starting physical address (32 bit) */
 
#define DMA_Wk_ByteCntr   0x4C /* r working byte counter */
 
#define DMA_Wk_AddrCntr   0x50 /* r working address counter */
 
#define DMA_Status   0x54 /* r */
 
#define DMA_MDL_Addr   0x58 /* rw starting MDL address */
 
#define DMA_Wk_MDL_Cntr   0x5C /* r working MDL counter */
 
#define DMA_ScsiBusCtrl   0x70 /* rw SCSI Bus, PCI/DMA Ctrl */
 
#define StcReg_Low   CtcReg_Low /* w start transfer count */
 
#define StcReg_Mid   CtcReg_Mid /* w */
 
#define StcReg_High   CtcReg_High /* w */
 
#define Scsi_Dest_ID   Scsi_Status /* w */
 
#define Scsi_TimeOut   INT_Status /* w */
 
#define Intern_State   Sync_Period /* r */
 
#define Current_Fifo   Sync_Offset /* r Curr. FIFO / int. state */
 
#define DC390_read8(address)   (inb (pACB->IOPortBase + (address)))
 
#define DC390_read8_(address, base)   (inb ((u16)(base) + (address)))
 
#define DC390_read16(address)   (inw (pACB->IOPortBase + (address)))
 
#define DC390_read32(address)   (inl (pACB->IOPortBase + (address)))
 
#define DC390_write8(address, value)   outb ((value), pACB->IOPortBase + (address))
 
#define DC390_write8_(address, value, base)   outb ((value), (u16)(base) + (address))
 
#define DC390_write16(address, value)   outw ((value), pACB->IOPortBase + (address))
 
#define DC390_write32(address, value)   outl ((value), pACB->IOPortBase + (address))
 

Typedefs

typedef struct _EEprom EEprom
 
typedef struct _EEpromPEEprom
 

Macro Definition Documentation

#define ABORT_DEV   BIT1

Definition at line 244 of file tmscsim.h.

#define ABORT_DEV_   BIT0

Definition at line 236 of file tmscsim.h.

#define ABORT_TAG   0x0d

Definition at line 298 of file tmscsim.h.

#define ABORTION   BIT1

Definition at line 224 of file tmscsim.h.

#define ACTIVE_NEGATION   BIT3

Definition at line 343 of file tmscsim.h.

#define ASPI_SUPPORT   BIT2

Definition at line 202 of file tmscsim.h.

#define AUTO_REQSENSE   BIT0

Definition at line 245 of file tmscsim.h.

#define BIT0   0x00000001

Definition at line 191 of file tmscsim.h.

#define BIT1   0x00000002

Definition at line 190 of file tmscsim.h.

#define BIT10   0x00000400

Definition at line 181 of file tmscsim.h.

#define BIT11   0x00000800

Definition at line 180 of file tmscsim.h.

#define BIT12   0x00001000

Definition at line 179 of file tmscsim.h.

#define BIT13   0x00002000

Definition at line 178 of file tmscsim.h.

#define BIT14   0x00004000

Definition at line 177 of file tmscsim.h.

#define BIT15   0x00008000

Definition at line 176 of file tmscsim.h.

#define BIT16   0x00010000

Definition at line 175 of file tmscsim.h.

#define BIT17   0x00020000

Definition at line 174 of file tmscsim.h.

#define BIT18   0x00040000

Definition at line 173 of file tmscsim.h.

#define BIT19   0x00080000

Definition at line 172 of file tmscsim.h.

#define BIT2   0x00000004

Definition at line 189 of file tmscsim.h.

#define BIT20   0x00100000

Definition at line 171 of file tmscsim.h.

#define BIT21   0x00200000

Definition at line 170 of file tmscsim.h.

#define BIT22   0x00400000

Definition at line 169 of file tmscsim.h.

#define BIT23   0x00800000

Definition at line 168 of file tmscsim.h.

#define BIT24   0x01000000

Definition at line 167 of file tmscsim.h.

#define BIT25   0x02000000

Definition at line 166 of file tmscsim.h.

#define BIT26   0x04000000

Definition at line 165 of file tmscsim.h.

#define BIT27   0x08000000

Definition at line 164 of file tmscsim.h.

#define BIT28   0x10000000

Definition at line 163 of file tmscsim.h.

#define BIT29   0x20000000

Definition at line 162 of file tmscsim.h.

#define BIT3   0x00000008

Definition at line 188 of file tmscsim.h.

#define BIT30   0x40000000

Definition at line 161 of file tmscsim.h.

#define BIT31   0x80000000

Definition at line 160 of file tmscsim.h.

#define BIT4   0x00000010

Definition at line 187 of file tmscsim.h.

#define BIT5   0x00000020

Definition at line 186 of file tmscsim.h.

#define BIT6   0x00000040

Definition at line 185 of file tmscsim.h.

#define BIT7   0x00000080

Definition at line 184 of file tmscsim.h.

#define BIT8   0x00000100

Definition at line 183 of file tmscsim.h.

#define BIT9   0x00000200

Definition at line 182 of file tmscsim.h.

#define BLAST_COMPLETE   BIT5

Definition at line 470 of file tmscsim.h.

#define CLEAR_FIFO_CMD   1

Definition at line 365 of file tmscsim.h.

#define Clk_Factor   0x24 /* w */

Definition at line 501 of file tmscsim.h.

#define CLK_FREQ_10MHZ   BIT1

Definition at line 419 of file tmscsim.h.

#define CLK_FREQ_15MHZ   (BIT1+BIT0)

Definition at line 418 of file tmscsim.h.

#define CLK_FREQ_20MHZ   BIT2

Definition at line 417 of file tmscsim.h.

#define CLK_FREQ_25MHZ   (BIT2+BIT0)

Definition at line 416 of file tmscsim.h.

#define CLK_FREQ_30MHZ   (BIT2+BIT1)

Definition at line 415 of file tmscsim.h.

#define CLK_FREQ_35MHZ   (BIT2+BIT1+BIT0)

Definition at line 414 of file tmscsim.h.

#define CLK_FREQ_40MHZ   0

Definition at line 413 of file tmscsim.h.

#define COUNT_2_ZERO   BIT4

Definition at line 392 of file tmscsim.h.

#define CtcReg_High   0x38 /* r */

Definition at line 494 of file tmscsim.h.

#define CtcReg_Low   0x00 /* r curr. transfer count */

Definition at line 492 of file tmscsim.h.

#define CtcReg_Mid   0x04 /* r */

Definition at line 493 of file tmscsim.h.

#define CTRL4_RESERVED   BIT4 /* must be 1 acc. to AM53C974.c */

Definition at line 444 of file tmscsim.h.

#define CtrlReg1   0x20

Definition at line 502 of file tmscsim.h.

#define CtrlReg2   0x2C

Definition at line 503 of file tmscsim.h.

#define CtrlReg3   0x30

Definition at line 504 of file tmscsim.h.

#define CtrlReg4   0x34

Definition at line 505 of file tmscsim.h.

#define Current_Fifo   Sync_Offset /* r Curr. FIFO / int. state */

Definition at line 522 of file tmscsim.h.

#define DASD_SUPPORT   BIT0

Definition at line 200 of file tmscsim.h.

#define DATA_XFER_CMD   INFO_XFER_CMD

Definition at line 385 of file tmscsim.h.

#define DATAIN   BIT6

Definition at line 240 of file tmscsim.h.

#define DATAOUT   BIT7

Definition at line 239 of file tmscsim.h.

#define DC390_read16 (   address)    (inw (pACB->IOPortBase + (address)))

Definition at line 531 of file tmscsim.h.

#define DC390_read32 (   address)    (inl (pACB->IOPortBase + (address)))

Definition at line 534 of file tmscsim.h.

#define DC390_read8 (   address)    (inb (pACB->IOPortBase + (address)))

Definition at line 525 of file tmscsim.h.

#define DC390_read8_ (   address,
  base 
)    (inb ((u16)(base) + (address)))

Definition at line 528 of file tmscsim.h.

#define DC390_write16 (   address,
  value 
)    outw ((value), pACB->IOPortBase + (address))

Definition at line 543 of file tmscsim.h.

#define DC390_write32 (   address,
  value 
)    outl ((value), pACB->IOPortBase + (address))

Definition at line 546 of file tmscsim.h.

#define DC390_write8 (   address,
  value 
)    outb ((value), pACB->IOPortBase + (address))

Definition at line 537 of file tmscsim.h.

#define DC390_write8_ (   address,
  value,
  base 
)    outb ((value), (u16)(base) + (address))

Definition at line 540 of file tmscsim.h.

#define DIAGNOSTIC   BIT2

Definition at line 462 of file tmscsim.h.

#define DIS_INT_ON_SCSI_RST   BIT6

Definition at line 423 of file tmscsim.h.

#define DIS_SEL_RESEL   0x45 /* currently not used */

Definition at line 381 of file tmscsim.h.

#define DISABLE_CE   0

Definition at line 348 of file tmscsim.h.

#define DISCONNECTED   BIT5

Definition at line 400 of file tmscsim.h.

#define DMA_ABORT_CMD   BIT1

Definition at line 465 of file tmscsim.h.

#define DMA_BLAST_CMD   BIT0

Definition at line 464 of file tmscsim.h.

#define DMA_Cmd   0x40

Definition at line 506 of file tmscsim.h.

#define DMA_COMMAND   BIT7

Definition at line 363 of file tmscsim.h.

#define DMA_IDLE_CMD   0

Definition at line 463 of file tmscsim.h.

#define DMA_MDL_Addr   0x58 /* rw starting MDL address */

Definition at line 512 of file tmscsim.h.

#define DMA_ScsiBusCtrl   0x70 /* rw SCSI Bus, PCI/DMA Ctrl */

Definition at line 514 of file tmscsim.h.

#define DMA_START_CMD   (BIT1+BIT0)

Definition at line 466 of file tmscsim.h.

#define DMA_Status   0x54 /* r */

Definition at line 511 of file tmscsim.h.

#define DMA_Wk_AddrCntr   0x50 /* r working address counter */

Definition at line 510 of file tmscsim.h.

#define DMA_Wk_ByteCntr   0x4C /* r working byte counter */

Definition at line 509 of file tmscsim.h.

#define DMA_Wk_MDL_Cntr   0x5C /* r working MDL counter */

Definition at line 513 of file tmscsim.h.

#define DMA_XFER_ABORT   BIT2

Definition at line 473 of file tmscsim.h.

#define DMA_XFER_DONE   BIT3

Definition at line 472 of file tmscsim.h.

#define DMA_XFER_ERROR   BIT1

Definition at line 474 of file tmscsim.h.

#define DMA_XferAddr   0x48 /* rw starting physical address (32 bit) */

Definition at line 508 of file tmscsim.h.

#define DMA_XferCnt   0x44 /* rw starting transfer count (32 bit) */

Definition at line 507 of file tmscsim.h.

#define DO_SYNC_NEGO   BIT13

Definition at line 219 of file tmscsim.h.

#define EATER_0NS   (BIT7+BIT6)

Definition at line 442 of file tmscsim.h.

#define EATER_12NS   0

Definition at line 439 of file tmscsim.h.

#define EATER_25NS   BIT7

Definition at line 440 of file tmscsim.h.

#define EATER_35NS   BIT6

Definition at line 441 of file tmscsim.h.

#define EE_ADAPT_SCSI_ID   32

Definition at line 325 of file tmscsim.h.

#define EE_DELAY   34

Definition at line 327 of file tmscsim.h.

#define EE_LEN   40

Definition at line 330 of file tmscsim.h.

#define EE_MODE2   33

Definition at line 326 of file tmscsim.h.

#define EE_TAG_CMD_NUM   35

Definition at line 328 of file tmscsim.h.

#define EEPROM_READ   0x80

Definition at line 349 of file tmscsim.h.

#define EN_ATN_STOP   BIT5

Definition at line 283 of file tmscsim.h.

#define EN_DISCONNECT_   BIT2

Definition at line 335 of file tmscsim.h.

#define EN_DMA_INT   BIT6

Definition at line 459 of file tmscsim.h.

#define EN_FEATURE   BIT6

Definition at line 428 of file tmscsim.h.

#define EN_GRP2_CMD   BIT5

Definition at line 434 of file tmscsim.h.

#define EN_INT_ON_PCI_ABORT   BIT25

Definition at line 478 of file tmscsim.h.

#define EN_PAGE_INT   BIT5 /* page transfer interrupt enable */

Definition at line 460 of file tmscsim.h.

#define EN_QTAG_MSG   BIT6

Definition at line 433 of file tmscsim.h.

#define EN_SCSI2_CMD   BIT3

Definition at line 429 of file tmscsim.h.

#define EN_SEL_RESEL   0x44

Definition at line 380 of file tmscsim.h.

#define EN_TAG_QUEUEING   BIT4

Definition at line 282 of file tmscsim.h.

#define ENABLE_CE   1

Definition at line 347 of file tmscsim.h.

#define ENABLE_TIMER   BIT4

Definition at line 242 of file tmscsim.h.

#define EXTENDED_TIMING   BIT7

Definition at line 422 of file tmscsim.h.

#define FAST_CLK   BIT3 /* ;25 - 40 MHZ */

Definition at line 436 of file tmscsim.h.

#define FAST_SCSI   BIT4 /* ;10MB/SEC */

Definition at line 435 of file tmscsim.h.

#define FORMATING_MEDIA   BIT2

Definition at line 196 of file tmscsim.h.

#define GLITCH_TO_NS (   x)    (((~x>>6 & 2) >> 1) | ((x>>6 & 1) << 1 ^ (x>>6 & 2)))

Definition at line 448 of file tmscsim.h.

#define GREATER_1G   BIT1

Definition at line 341 of file tmscsim.h.

#define GROUP_CODE_VALID   BIT3

Definition at line 393 of file tmscsim.h.

#define H_ABORT   0x0FF

Definition at line 258 of file tmscsim.h.

#define H_BAD_CCB_OR_SG   0x1A

Definition at line 257 of file tmscsim.h.

#define H_BAD_TARGET_DIR   0x18

Definition at line 255 of file tmscsim.h.

#define H_DUPLICATE_CCB   0x19

Definition at line 256 of file tmscsim.h.

#define H_INVALID_CCB_OP   0x16

Definition at line 253 of file tmscsim.h.

#define H_LINK_CCB_BAD   0x17

Definition at line 254 of file tmscsim.h.

#define H_OVER_UNDER_RUN   0x12

Definition at line 250 of file tmscsim.h.

#define H_SEL_TIMEOUT   0x11

Definition at line 249 of file tmscsim.h.

#define H_STATUS_GOOD   0

Definition at line 248 of file tmscsim.h.

#define H_TARGET_PHASE_F   0x14

Definition at line 252 of file tmscsim.h.

#define H_UNEXP_BUS_FREE   0x13

Definition at line 251 of file tmscsim.h.

#define ID_MSG_CHECK   BIT7

Definition at line 432 of file tmscsim.h.

#define ILLEGAL_OP_ERR   BIT6

Definition at line 390 of file tmscsim.h.

#define INFO_XFER_CMD   0x10

Definition at line 369 of file tmscsim.h.

#define INITIATOR_CMD_CMPLTE   0x11

Definition at line 370 of file tmscsim.h.

#define INT_Status   0x14 /* r */

Definition at line 498 of file tmscsim.h.

#define Intern_State   Sync_Period /* r */

Definition at line 521 of file tmscsim.h.

#define INTERRUPT   BIT7

Definition at line 389 of file tmscsim.h.

#define INTRN_STATE_MASK   (BIT2+BIT1+BIT0)

Definition at line 409 of file tmscsim.h.

#define INVALID_CMD   BIT6

Definition at line 399 of file tmscsim.h.

#define LUN_CHECK   BIT5

Definition at line 345 of file tmscsim.h.

#define MAP_TO_MDL   BIT4

Definition at line 461 of file tmscsim.h.

#define MAX_ADAPTER_NUM   4

Definition at line 15 of file tmscsim.h.

#define MAX_SCSI_ID   8

Definition at line 17 of file tmscsim.h.

#define MAX_SG_LIST_BUF   16 /* Not used */

Definition at line 16 of file tmscsim.h.

#define MAX_SRB_CNT   50 /* Max number of started commands */

Definition at line 18 of file tmscsim.h.

#define MK_RES (   drv,
  did,
  msg,
  tgt 
)    ((int)(drv)<<24 | (int)(did)<<16 | (int)(msg)<<8 | (int)(tgt))

Definition at line 267 of file tmscsim.h.

#define MK_RES_LNX (   drv,
  did,
  msg,
  tgt 
)    ((int)(drv)<<24 | (int)(did)<<16 | (int)(msg)<<8 | (int)(tgt))

Definition at line 268 of file tmscsim.h.

#define MORE2_DRV   BIT0

Definition at line 340 of file tmscsim.h.

#define MSG_ACCEPTED_CMD   0x12

Definition at line 371 of file tmscsim.h.

#define NEGATE_REQACK   BIT3

Definition at line 446 of file tmscsim.h.

#define NEGATE_REQACKDATA   BIT2

Definition at line 445 of file tmscsim.h.

#define NO_SEEK   BIT4

Definition at line 344 of file tmscsim.h.

#define NOP_CMD   0

Definition at line 364 of file tmscsim.h.

#define NS_TO_GLITCH (   y)    (((~y<<7) | ~((y<<6) ^ ((y<<5 & 1<<6) | ~0x40))) & 0xc0)

Definition at line 449 of file tmscsim.h.

#define OVER_RUN   BIT2

Definition at line 225 of file tmscsim.h.

#define PARITY_CHK_   BIT0

Definition at line 333 of file tmscsim.h.

#define PARITY_ERR   BIT5

Definition at line 391 of file tmscsim.h.

#define PARITY_ERR_REPO   BIT4

Definition at line 424 of file tmscsim.h.

#define PARITY_ERROR   BIT4

Definition at line 227 of file tmscsim.h.

#define PCI_MS_ABORT   BIT6

Definition at line 469 of file tmscsim.h.

#define POWER_DOWN   BIT0

Definition at line 475 of file tmscsim.h.

#define PW_DOWN_CTRL   BIT21

Definition at line 480 of file tmscsim.h.

#define READ_DIRECTION   BIT7

Definition at line 457 of file tmscsim.h.

#define REAL_EE_ADAPT_SCSI_ID   64

Definition at line 320 of file tmscsim.h.

#define REAL_EE_DELAY   66

Definition at line 322 of file tmscsim.h.

#define REAL_EE_MODE2   65

Definition at line 321 of file tmscsim.h.

#define REAL_EE_TAG_CMD_NUM   67

Definition at line 323 of file tmscsim.h.

#define REDUCED_POWER   BIT5

Definition at line 443 of file tmscsim.h.

#define RES_DID   0x00FF0000 /* DID_ codes */

Definition at line 264 of file tmscsim.h.

#define RES_DRV   0xFF000000 /* DRIVER_ codes */

Definition at line 265 of file tmscsim.h.

#define RES_ENDMSG   0x0000FF00 /* End Message */

Definition at line 263 of file tmscsim.h.

#define RES_TARGET   0x000000FF /* Target State */

Definition at line 261 of file tmscsim.h.

#define RES_TARGET_LNX   STATUS_MASK /* Only official ... */

Definition at line 262 of file tmscsim.h.

#define RESEL   0x40 /* " */

Definition at line 382 of file tmscsim.h.

#define RESEL_ATN3   0x47 /* " */

Definition at line 383 of file tmscsim.h.

#define RESELECTED   BIT2

Definition at line 403 of file tmscsim.h.

#define RESET_ATN_CMD   0x1B

Definition at line 374 of file tmscsim.h.

#define RESET_DETECT   BIT1

Definition at line 232 of file tmscsim.h.

#define RESET_DEV   BIT0

Definition at line 231 of file tmscsim.h.

#define RESET_DEV0   BIT2

Definition at line 243 of file tmscsim.h.

#define RESET_DONE   BIT2

Definition at line 233 of file tmscsim.h.

#define RESIDUAL_VALID   BIT5

Definition at line 241 of file tmscsim.h.

#define RST_DEVICE_CMD   2

Definition at line 366 of file tmscsim.h.

#define RST_SCSI_BUS   BIT2

Definition at line 342 of file tmscsim.h.

#define RST_SCSI_BUS_CMD   3

Definition at line 367 of file tmscsim.h.

#define SCAM   BIT18

Definition at line 483 of file tmscsim.h.

#define SCLK   BIT19

Definition at line 482 of file tmscsim.h.

#define SCSI_BUSY   BIT20

Definition at line 481 of file tmscsim.h.

#define SCSI_COMMAND   2

Definition at line 290 of file tmscsim.h.

#define SCSI_DATA_IN   1

Definition at line 289 of file tmscsim.h.

#define SCSI_DATA_OUT   0

Definition at line 288 of file tmscsim.h.

#define Scsi_Dest_ID   Scsi_Status /* w */

Definition at line 519 of file tmscsim.h.

#define SCSI_ID_ON_BUS   (BIT2+BIT1+BIT0) /* host adapter ID */

Definition at line 425 of file tmscsim.h.

#define SCSI_INTERRUPT   BIT4

Definition at line 471 of file tmscsim.h.

#define SCSI_IRQ_NONE   255

Definition at line 13 of file tmscsim.h.

#define SCSI_LINES   0x0003ffff

Definition at line 484 of file tmscsim.h.

#define SCSI_MSG_IN   7

Definition at line 295 of file tmscsim.h.

#define SCSI_MSG_OUT   6

Definition at line 294 of file tmscsim.h.

#define SCSI_NOP0   4

Definition at line 292 of file tmscsim.h.

#define SCSI_NOP1   5

Definition at line 293 of file tmscsim.h.

#define SCSI_PHASE_MASK   (BIT2+BIT1+BIT0)

Definition at line 394 of file tmscsim.h.

#define SCSI_RESET   BIT7

Definition at line 398 of file tmscsim.h.

#define Scsi_Status   0x10 /* r */

Definition at line 497 of file tmscsim.h.

#define SCSI_STATUS_   3

Definition at line 291 of file tmscsim.h.

#define SCSI_SUPPORT   BIT1

Definition at line 201 of file tmscsim.h.

#define Scsi_TimeOut   INT_Status /* w */

Definition at line 520 of file tmscsim.h.

#define ScsiCmd   0x0C

Definition at line 496 of file tmscsim.h.

#define ScsiFifo   0x08

Definition at line 495 of file tmscsim.h.

#define SEL_ATTENTION   BIT1

Definition at line 404 of file tmscsim.h.

#define SEL_TIMEOUT   153 /* 250 ms selection timeout (@ 40 MHz) */

Definition at line 20 of file tmscsim.h.

#define SEL_W_ATN   0x42

Definition at line 377 of file tmscsim.h.

#define SEL_W_ATN3   0x46

Definition at line 379 of file tmscsim.h.

#define SEL_W_ATN_STOP   0x43

Definition at line 378 of file tmscsim.h.

#define SEL_WO_ATN   0x41 /* currently not used */

Definition at line 376 of file tmscsim.h.

#define SELECTED   BIT0

Definition at line 405 of file tmscsim.h.

#define SEND_START_   BIT3

Definition at line 336 of file tmscsim.h.

#define SERVICE_REQUEST   BIT4

Definition at line 401 of file tmscsim.h.

#define SET_ATN_CMD   0x1A

Definition at line 373 of file tmscsim.h.

#define SET_RES_DID (   who,
  did 
)    do { who &= ~RES_DID; who |= (int)(did) << 16; } while (0)

Definition at line 273 of file tmscsim.h.

#define SET_RES_DRV (   who,
  drv 
)    do { who &= ~RES_DRV; who |= (int)(drv) << 24; } while (0)

Definition at line 274 of file tmscsim.h.

#define SET_RES_MSG (   who,
  msg 
)    do { who &= ~RES_ENDMSG; who |= (int)(msg) << 8; } while (0)

Definition at line 272 of file tmscsim.h.

#define SET_RES_TARGET (   who,
  tgt 
)    do { who &= ~RES_TARGET; who |= (int)(tgt); } while (0)

Definition at line 270 of file tmscsim.h.

#define SET_RES_TARGET_LNX (   who,
  tgt 
)    do { who &= ~RES_TARGET_LNX; who |= (int)(tgt) << 1; } while (0)

Definition at line 271 of file tmscsim.h.

#define SRB_ABORT_SENT   BIT12

Definition at line 218 of file tmscsim.h.

#define SRB_COMMAND   BIT5

Definition at line 211 of file tmscsim.h.

#define SRB_COMPLETED   BIT11

Definition at line 217 of file tmscsim.h.

#define SRB_DATA_XFER   BIT8

Definition at line 214 of file tmscsim.h.

#define SRB_DISCONNECT   BIT7

Definition at line 213 of file tmscsim.h.

#define SRB_ERROR   BIT5

Definition at line 228 of file tmscsim.h.

#define SRB_FREE   0

Definition at line 205 of file tmscsim.h.

#define SRB_MSGIN   BIT3

Definition at line 209 of file tmscsim.h.

#define SRB_MSGIN_MULTI   BIT4

Definition at line 210 of file tmscsim.h.

#define SRB_MSGOUT   BIT2 /*;arbitration+msg_out 1st byte*/

Definition at line 208 of file tmscsim.h.

#define SRB_OK   BIT0

Definition at line 223 of file tmscsim.h.

#define SRB_READY   BIT1

Definition at line 207 of file tmscsim.h.

#define SRB_START_   BIT6 /*;arbitration+msg_out+command_out*/

Definition at line 212 of file tmscsim.h.

#define SRB_STATUS   BIT10

Definition at line 216 of file tmscsim.h.

#define SRB_UNEXPECT_RESEL   BIT14

Definition at line 220 of file tmscsim.h.

#define SRB_WAIT   BIT0

Definition at line 206 of file tmscsim.h.

#define SRB_XFERPAD   BIT9

Definition at line 215 of file tmscsim.h.

#define StcReg_High   CtcReg_High /* w */

Definition at line 518 of file tmscsim.h.

#define StcReg_Low   CtcReg_Low /* w start transfer count */

Definition at line 516 of file tmscsim.h.

#define StcReg_Mid   CtcReg_Mid /* w */

Definition at line 517 of file tmscsim.h.

#define SUCCESSFUL_OP   BIT3

Definition at line 402 of file tmscsim.h.

#define SYNC_DISABLE   0

Definition at line 277 of file tmscsim.h.

#define SYNC_ENABLE   BIT0

Definition at line 278 of file tmscsim.h.

#define SYNC_NEGO_   BIT1

Definition at line 334 of file tmscsim.h.

#define SYNC_NEGO_DONE   BIT1

Definition at line 279 of file tmscsim.h.

#define SYNC_NEGO_OFFSET   15

Definition at line 285 of file tmscsim.h.

#define Sync_Offset   0x1C /* w */

Definition at line 500 of file tmscsim.h.

#define SYNC_OFFSET_FLAG   BIT3

Definition at line 408 of file tmscsim.h.

#define Sync_Period   0x18 /* w */

Definition at line 499 of file tmscsim.h.

#define TAG_QUEUEING_   BIT4

Definition at line 337 of file tmscsim.h.

#define UNDER_RUN   BIT3

Definition at line 226 of file tmscsim.h.

#define UNIT_ALLOCATED   BIT0

Definition at line 194 of file tmscsim.h.

#define UNIT_INFO_CHANGED   BIT1

Definition at line 195 of file tmscsim.h.

#define UNIT_RETRY   BIT3

Definition at line 197 of file tmscsim.h.

#define WIDE_ENABLE   BIT2 /* Not used ;-) */

Definition at line 280 of file tmscsim.h.

#define WIDE_NEGO_DONE   BIT3 /* Not used ;-) */

Definition at line 281 of file tmscsim.h.

#define WRITE_DIRECTION   0

Definition at line 458 of file tmscsim.h.

#define WRT_ERASE_DMA_STAT   BIT24

Definition at line 479 of file tmscsim.h.

#define XFER_PAD_BYTE   0x18

Definition at line 372 of file tmscsim.h.

Typedef Documentation

typedef struct _EEprom * PEEprom