blob: 6e7bb068220f469cdaa04076466d457b9510ff0f [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001/*
2 * scsi.h Copyright (C) 1992 Drew Eckhardt
3 * Copyright (C) 1993, 1994, 1995, 1998, 1999 Eric Youngdale
4 * generic SCSI package header file by
5 * Initial versions: Drew Eckhardt
6 * Subsequent revisions: Eric Youngdale
7 *
8 * <drew@colorado.edu>
9 *
10 * Modified by Eric Youngdale eric@andante.org to
11 * add scatter-gather, multiple outstanding request, and other
12 * enhancements.
13 */
14/*
15 * NOTE: this file only contains compatibility glue for old drivers. All
16 * these wrappers will be removed sooner or later. For new code please use
17 * the interfaces declared in the headers in include/scsi/
18 */
19
20#ifndef _SCSI_H
21#define _SCSI_H
22
23#include <linux/config.h> /* for CONFIG_SCSI_LOGGING */
24
25#include <scsi/scsi_cmnd.h>
Linus Torvalds1da177e2005-04-16 15:20:36 -070026#include <scsi/scsi_device.h>
27#include <scsi/scsi_eh.h>
28#include <scsi/scsi_request.h>
29#include <scsi/scsi_tcq.h>
30#include <scsi/scsi.h>
31
32/*
33 * Some defs, in case these are not defined elsewhere.
34 */
35#ifndef TRUE
36#define TRUE 1
37#endif
38#ifndef FALSE
39#define FALSE 0
40#endif
41
42struct Scsi_Host;
43struct scsi_cmnd;
44struct scsi_device;
45struct scsi_target;
46struct scatterlist;
47
48/*
49 * Legacy dma direction interfaces.
50 *
51 * This assumes the pci/sbus dma mapping flags have the same numercial
52 * values as the generic dma-mapping ones. Currently they have but there's
53 * no way to check. Better don't use these interfaces!
54 */
55#define SCSI_DATA_UNKNOWN (DMA_BIDIRECTIONAL)
56#define SCSI_DATA_WRITE (DMA_TO_DEVICE)
57#define SCSI_DATA_READ (DMA_FROM_DEVICE)
58#define SCSI_DATA_NONE (DMA_NONE)
59
60#define scsi_to_pci_dma_dir(scsi_dir) ((int)(scsi_dir))
61#define scsi_to_sbus_dma_dir(scsi_dir) ((int)(scsi_dir))
62
63/*
Linus Torvalds1da177e2005-04-16 15:20:36 -070064 * This is the crap from the old error handling code. We have it in a special
65 * place so that we can more easily delete it later on.
66 */
67#include "scsi_obsolete.h"
68
69/* obsolete typedef junk. */
70#include "scsi_typedefs.h"
71
72#endif /* _SCSI_H */