summaryrefslogtreecommitdiffstats
path: root/sys/scsi/scsi_disk.h
diff options
context:
space:
mode:
authorrgrimes <rgrimes@FreeBSD.org>1993-08-20 09:23:30 +0000
committerrgrimes <rgrimes@FreeBSD.org>1993-08-20 09:23:30 +0000
commitcf0a4c9f207124f943e290bcc365b75f8deea2c6 (patch)
tree5dcbce83587cfd32b34f8a919c3f679ce971a405 /sys/scsi/scsi_disk.h
parent2970641bb3922023009c2b42e8d0074196806195 (diff)
downloadFreeBSD-src-cf0a4c9f207124f943e290bcc365b75f8deea2c6.zip
FreeBSD-src-cf0a4c9f207124f943e290bcc365b75f8deea2c6.tar.gz
Update scsi code to the latest from Julian. This code is now identical
to the last copy from Julian. After this commit I will be commiting the local fixes and makeing diffs to send back to Julian so he can update his code. ---- From julian@jules.DIALix.oz.au Thu Aug 5 09:25:23 1993 To: hd@world.std.com, julian@jules.DIALix.oz.au Cc: nate@bsd.coe.montana.edu Subject: Re: new scsi ---- From julian@jules.DIALix.oz.au Sat Aug 7 04:13:17 1993 To: hd@world.std.com (HD Associates) Cc: nate@bsd.coe.montana.edu Subject: Re: timeout diffs Here are the diffs to take the scsi stuff to my latest tree from what Nate and you received.. the changes remove all the local timeout stuff and use (un)timeout(), ---- From julian@jules.DIALix.oz.au Sat Aug 7 04:13:45 1993 To: hd@world.std.com (HD Associates) Cc: nate@bsd.coe.montana.edu, briggs@csugrad.cs.vt.edu here is a fix for a silly bug in the scsiconf I just sent out and a similar fix for st.c
Diffstat (limited to 'sys/scsi/scsi_disk.h')
-rw-r--r--sys/scsi/scsi_disk.h85
1 files changed, 41 insertions, 44 deletions
diff --git a/sys/scsi/scsi_disk.h b/sys/scsi/scsi_disk.h
index 75f8150..38e53c5 100644
--- a/sys/scsi/scsi_disk.h
+++ b/sys/scsi/scsi_disk.h
@@ -1,16 +1,29 @@
-
/*
* HISTORY
* $Log: scsi_disk.h,v $
- * Revision 1.1.1.1 1993/06/12 14:57:27 rgrimes
- * Initial import, 0.1 + pk 0.2.4-B1
- *
+ * Revision 1.3 93/08/05 21:38:11 julian
+ * fix the definitionof the last byte of each scsi command.
+ *
+ * Revision 1.2 93/07/31 22:52:42 julian
+ * removed all bitfields
+ *
+ * Revision 1.1 93/04/12 21:51:04 root
+ * checkin for 'jules'
+ *
* Revision 1.2 1992/10/13 03:14:21 julian
* added the load-eject field in 'start/stop' for removable devices.
*
* Revision 1.1 1992/09/26 22:11:29 julian
* Initial revision
*
+ *
+ * PATCHES MAGIC LEVEL PATCH THAT GOT US HERE
+ * -------------------- ----- ----------------------
+ * CURRENT PATCH LEVEL: 1 00098
+ * -------------------- ----- ----------------------
+ *
+ * 16 Feb 93 Julian Elischer ADDED for SCSI system
+ *
*/
/*
@@ -73,73 +86,58 @@
struct scsi_reassign_blocks
{
u_char op_code;
- u_char :5;
- u_char lun:3;
+ u_char byte2;
u_char unused[3];
- u_char link:1;
- u_char flag:1;
- u_char :6;
+ u_char control;
};
struct scsi_rw
{
u_char op_code;
- u_char addr_2:5; /* Most significant */
- u_char lun:3;
+ u_char addr_2; /* Most significant */
+#define SRW_TOPADDR 0x1F /* only 5 bits here */
u_char addr_1;
u_char addr_0; /* least significant */
u_char length;
- u_char link:1;
- u_char flag:1;
- u_char :6;
+ u_char control;
};
struct scsi_rw_big
{
u_char op_code;
- u_char rel_addr:1;
- u_char :4; /* Most significant */
- u_char lun:3;
- u_char addr_3;
+ u_char byte2;
+#define SRWB_RELADDR 0x01
+ u_char addr_3; /* Most significant */
u_char addr_2;
u_char addr_1;
u_char addr_0; /* least significant */
u_char reserved;;
u_char length2;
u_char length1;
- u_char link:1;
- u_char flag:1;
- u_char :4;
- u_char vendor:2;
+ u_char control;
};
struct scsi_read_capacity
{
u_char op_code;
- u_char :5;
- u_char lun:3;
+ u_char byte2;
u_char addr_3; /* Most Significant */
u_char addr_2;
u_char addr_1;
u_char addr_0; /* Least Significant */
u_char unused[3];
- u_char link:1;
- u_char flag:1;
- u_char :6;
+ u_char control;
};
struct scsi_start_stop
{
u_char op_code;
- u_char :5;
- u_char lun:3;
+ u_char byte2;
u_char unused[2];
- u_char start:1;
- u_char loej:1;
- u_char :6;
- u_char link:1;
- u_char flag:1;
- u_char :6;
+ u_char how;
+#define SSS_START 0x01
+#define SSS_LOEJ 0x02
+ u_char control;
};
@@ -190,8 +188,8 @@ struct scsi_reassign_blocks_data
union disk_pages /* this is the structure copied from osf */
{
struct page_disk_format {
- u_char pg_code:6; /* page code (should be 3) */
- u_char :2;
+ u_char pg_code; /* page code (should be 3) */
+#define DISK_PGCODE 0x3F /* only 6 bits valid */
u_char pg_length; /* page length (should be 0x16) */
u_char trk_z_1; /* tracks per zone (MSB) */
u_char trk_z_0; /* tracks per zone (LSB) */
@@ -211,17 +209,16 @@ union disk_pages /* this is the structure copied from osf */
u_char trk_skew_0; /* track skew factor (LSB) */
u_char cyl_skew_1; /* cylinder skew (MSB) */
u_char cyl_skew_0; /* cylinder skew (LSB) */
- u_char reserved1:4;
- u_char surf:1;
- u_char rmb:1;
- u_char hsec:1;
- u_char ssec:1;
+ u_char flags; /* various */
+#define DISK_FMT_SURF 0x10
+#define DISK_FMT_RMB 0x20
+#define DISK_FMT_HSEC 0x40
+#define DISK_FMT_SSEC 0x80
u_char reserved2;
u_char reserved3;
} disk_format;
struct page_rigid_geometry {
- u_char pg_code:7; /* page code (should be 4) */
- u_char mbone:1; /* must be one */
+ u_char pg_code; /* page code (should be 4) */
u_char pg_length; /* page length (should be 0x16) */
u_char ncyl_2; /* number of cylinders (MSB) */
u_char ncyl_1; /* number of cylinders */
OpenPOWER on IntegriCloud