summaryrefslogtreecommitdiffstats
path: root/sys/scsi/st.c
diff options
context:
space:
mode:
authordufault <dufault@FreeBSD.org>1995-05-03 18:09:20 +0000
committerdufault <dufault@FreeBSD.org>1995-05-03 18:09:20 +0000
commit9d5087634af5b60fb1b35e627b1e09dd5c178413 (patch)
tree1681cda3a482fda605182f6fe8d420efbc5839e6 /sys/scsi/st.c
parentda1f0a96f4ab656828dada409b64a653945a70cb (diff)
downloadFreeBSD-src-9d5087634af5b60fb1b35e627b1e09dd5c178413.zip
FreeBSD-src-9d5087634af5b60fb1b35e627b1e09dd5c178413.tar.gz
Moved unit definitions out of scsiconf.h;
Added CONTROL device that only does user-ioctl and nothing else; Added protection so user-ioctl requires write access; Clean up scsiconf.h a little. It needs more work.
Diffstat (limited to 'sys/scsi/st.c')
-rw-r--r--sys/scsi/st.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/scsi/st.c b/sys/scsi/st.c
index b43f0c5..f8c168f 100644
--- a/sys/scsi/st.c
+++ b/sys/scsi/st.c
@@ -12,7 +12,7 @@
* on the understanding that TFS is not responsible for the correct
* functioning of this software in any circumstances.
*
- * $Id: st.c,v 1.33 1995/04/23 22:07:54 gibbs Exp $
+ * $Id: st.c,v 1.34 1995/04/29 21:30:29 joerg Exp $
*/
/*
@@ -53,11 +53,14 @@ u_int32 ststrats, stqueues;
#define DEF_FIXED_BSIZE 512
#define ST_RETRIES 4 /* only on non IO commands */
+#define STUNIT(DEV) ((minor(DEV)&0xF0) >> 4) /* 4 bit unit. */
+#define STSETUNIT(DEV, U) makedev(major(DEV), ((U) << 4))
+
#define MODE(z) ( (minor(z) & 0x03) )
#define DSTY(z) ( ((minor(z) >> 2) & 0x03) )
#define CTLMODE 3
-#define IS_CTLMODE(DEV) (MODE(DEV) == CTLMODE || SCSI_SUPER(DEV))
+#define IS_CTLMODE(DEV) (MODE(DEV) == CTLMODE)
#define SCSI_2_MAX_DENSITY_CODE 0x17 /* maximum density code specified
* in SCSI II spec. */
OpenPOWER on IntegriCloud