Merge branch 'core/locking' into core/urgent
[linux-2.6-block.git] / drivers / scsi / a3000.h
CommitLineData
1da177e4
LT
1#ifndef A3000_H
2#define A3000_H
3
4/* $Id: a3000.h,v 1.4 1997/01/19 23:07:10 davem Exp $
5 *
6 * Header file for the Amiga 3000 built-in SCSI controller for Linux
7 *
8 * Written and (C) 1993, Hamish Macdonald, see a3000.c for more info
9 *
10 */
11
12#include <linux/types.h>
13
d0be4a7d 14int a3000_detect(struct scsi_host_template *);
1da177e4 15int a3000_release(struct Scsi_Host *);
1da177e4
LT
16
17#ifndef CMD_PER_LUN
18#define CMD_PER_LUN 2
19#endif
20
21#ifndef CAN_QUEUE
22#define CAN_QUEUE 16
23#endif
24
25/*
26 * if the transfer address ANDed with this results in a non-zero
27 * result, then we can't use DMA.
28 */
29#define A3000_XFER_MASK (0x00000003)
30
31typedef struct {
32 unsigned char pad1[2];
33 volatile unsigned short DAWR;
34 volatile unsigned int WTC;
35 unsigned char pad2[2];
36 volatile unsigned short CNTR;
37 volatile unsigned long ACR;
38 unsigned char pad3[2];
39 volatile unsigned short ST_DMA;
40 unsigned char pad4[2];
41 volatile unsigned short FLUSH;
42 unsigned char pad5[2];
43 volatile unsigned short CINT;
44 unsigned char pad6[2];
45 volatile unsigned short ISTR;
46 unsigned char pad7[30];
47 volatile unsigned short SP_DMA;
48 unsigned char pad8;
49 volatile unsigned char SASR;
50 unsigned char pad9;
51 volatile unsigned char SCMD;
52} a3000_scsiregs;
53
54#define DAWR_A3000 (3)
55
56/* CNTR bits. */
57#define CNTR_TCEN (1<<5)
58#define CNTR_PREST (1<<4)
59#define CNTR_PDMD (1<<3)
60#define CNTR_INTEN (1<<2)
61#define CNTR_DDIR (1<<1)
62#define CNTR_IO_DX (1<<0)
63
64/* ISTR bits. */
65#define ISTR_INTX (1<<8)
66#define ISTR_INT_F (1<<7)
67#define ISTR_INTS (1<<6)
68#define ISTR_E_INT (1<<5)
69#define ISTR_INT_P (1<<4)
70#define ISTR_UE_INT (1<<3)
71#define ISTR_OE_INT (1<<2)
72#define ISTR_FF_FLG (1<<1)
73#define ISTR_FE_FLG (1<<0)
74
75#endif /* A3000_H */