File: cumana_2.h

package info (click to toggle)
kernel-source-sparc-2.2.1 2.2.1
  • links: PTS
  • area: main
  • in suites: slink
  • size: 62,800 kB
  • ctags: 188,320
  • sloc: ansic: 1,114,164; asm: 49,922; makefile: 8,272; sh: 1,831; perl: 1,584; tcl: 409; lisp: 218; cpp: 186; awk: 133; sed: 72
file content (80 lines) | stat: -rw-r--r-- 1,895 bytes parent folder | download | duplicates (9)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
/*
 * Cumana SCSI II driver
 *
 * Copyright (C) 1997-1998 Russell King
 */
#ifndef CUMANA_2_H
#define CUMANA_2_H

extern int cumanascsi_2_detect (Scsi_Host_Template *);
extern int cumanascsi_2_release (struct Scsi_Host *);
extern const char *cumanascsi_2_info (struct Scsi_Host *);
extern int cumanascsi_2_proc_info (char *buffer, char **start, off_t offset,
					int length, int hostno, int inout);

#ifndef NULL
#define NULL ((void *)0)
#endif

#ifndef CAN_QUEUE
/*
 * Default queue size
 */
#define CAN_QUEUE	1
#endif

#ifndef SCSI_ID
/*
 * Default SCSI host ID
 */
#define SCSI_ID		7
#endif

#include <scsi/scsicam.h>

#ifndef HOSTS_C
#include "fas216.h"
#endif

#define CUMANASCSI_2 {							\
proc_info:		cumanascsi_2_proc_info,				\
name:			"Cumana SCSI II",				\
detect:			cumanascsi_2_detect,	/* detect		*/	\
release:		cumanascsi_2_release,	/* release		*/	\
info:			cumanascsi_2_info,	/* info			*/	\
command:		fas216_command,		/* command		*/	\
queuecommand:		fas216_queue_command,	/* queuecommand		*/	\
abort:			fas216_abort,		/* abort		*/	\
reset:			fas216_reset,		/* reset		*/	\
bios_param:		scsicam_bios_param,	/* biosparam		*/	\
can_queue:		CAN_QUEUE,		/* can queue		*/	\
this_id:		SCSI_ID,		/* scsi host id		*/	\
sg_tablesize:		SG_ALL,			/* sg_tablesize		*/	\
cmd_per_lun:		CAN_QUEUE,		/* cmd per lun		*/	\
unchecked_isa_dma:	0,			/* unchecked isa dma	*/	\
use_clustering:		DISABLE_CLUSTERING					\
	}

#ifndef HOSTS_C

#include <asm/dma.h>

#define NR_SG	256

typedef struct {
	FAS216_Info info;

	/* other info... */
	unsigned int	status;		/* card status register	*/
	unsigned int	alatch;		/* Control register	*/
	unsigned int	terms;		/* Terminator state	*/
	unsigned int	dmaarea;	/* Pseudo DMA area	*/
	dmasg_t		dmasg[NR_SG];	/* Scatter DMA list	*/
} CumanaScsi2_Info;

#define CSTATUS_IRQ	(1 << 0)
#define CSTATUS_DRQ	(1 << 1)

#endif /* HOSTS_C */

#endif /* CUMANASCSI_2_H */