1 /* $NetBSD: scsi_all.h,v 1.19.2.2 2005/03/04 16:50:33 skrll Exp $ */
4 * SCSI-specific interface description.
8 * Largely written by Julian Elischer (julian@tfs.com)
9 * for TRW Financial Systems.
11 * TRW Financial Systems, in accordance with their agreement with Carnegie
12 * Mellon University, makes this software available to CMU to distribute
13 * or use in any manner that they see fit as long as this message is kept with
14 * the software. For this reason TFS also grants any other persons or
15 * organisations permission to use or modify this software.
17 * TFS supplies this software to be publicly redistributed
18 * on the understanding that TFS is not responsible for the correct
19 * functioning of this software in any circumstances.
21 * Ported to run under 386BSD by Julian Elischer (julian@tfs.com) Sept 1992
24 #ifndef _DEV_SCSIPI_SCSI_ALL_H_
25 #define _DEV_SCSIPI_SCSI_ALL_H_
28 * Define dome bits that are in ALL (or a lot of) scsi commands
30 #define SCSI_CTL_LINK 0x01
31 #define SCSI_CTL_FLAG 0x02
32 #define SCSI_CTL_VENDOR 0xC0
36 * Some old SCSI devices need the LUN to be set in the top 3 bits of the
37 * second byte of the CDB.
39 #define SCSI_CMD_LUN_MASK 0xe0
40 #define SCSI_CMD_LUN_SHIFT 5
42 #define SCSI_CHANGE_DEFINITION 0x40
43 struct scsi_changedef
{
52 #define SC_SCSI_1 0x01
53 #define SC_SCSI_2 0x03
59 #define SCSI_CHECK 0x02
60 #define SCSI_BUSY 0x08
61 #define SCSI_INTERM 0x10
62 #define SCSI_RESV_CONFLICT 0x18
63 #define SCSI_TERMINATED 0x22
64 #define SCSI_QUEUE_FULL 0x28
65 #define SCSI_ACA_ACTIVE 0x30
67 #endif /* _DEV_SCSIPI_SCSI_ALL_H_ */