diff options
author | phk <phk@FreeBSD.org> | 2002-05-14 06:57:02 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 2002-05-14 06:57:02 +0000 |
commit | 15562e8000ab7f1effcc24ea1be176311ecb74be (patch) | |
tree | fd01367433763b7c78c39dc5a7675d7db89427ef /sys/i386 | |
parent | b1ec2af28468455025b871a34fd8907f557aca94 (diff) | |
download | FreeBSD-src-15562e8000ab7f1effcc24ea1be176311ecb74be.zip FreeBSD-src-15562e8000ab7f1effcc24ea1be176311ecb74be.tar.gz |
Move a few ancient minor-number definitions for tapedrives to the
only driver which uses them. Remove the rest.
Diffstat (limited to 'sys/i386')
-rw-r--r-- | sys/i386/isa/wt.c | 12 | ||||
-rw-r--r-- | sys/i386/isa/wtreg.h | 2 |
2 files changed, 8 insertions, 6 deletions
diff --git a/sys/i386/isa/wt.c b/sys/i386/isa/wt.c index b6a5b43..ab5d4c3 100644 --- a/sys/i386/isa/wt.c +++ b/sys/i386/isa/wt.c @@ -283,7 +283,7 @@ COMPAT_ISA_DRIVER(wt, wtdriver); static int wtopen (dev_t dev, int flag, int fmt, struct thread *td) { - int u = minor (dev) & T_UNIT; + int u = minor (dev) & WT_UNIT; wtinfo_t *t = wttab + u; int error; @@ -365,7 +365,7 @@ wtopen (dev_t dev, int flag, int fmt, struct thread *td) static int wtclose (dev_t dev, int flags, int fmt, struct thread *td) { - int u = minor (dev) & T_UNIT; + int u = minor (dev) & WT_UNIT; wtinfo_t *t = wttab + u; if (u >= NWT || t->type == UNKNOWN) @@ -377,7 +377,7 @@ wtclose (dev_t dev, int flags, int fmt, struct thread *td) /* If seek forward is pending and no rewind on close, do nothing */ if (t->flags & TPRMARK) { - if (minor (dev) & T_NOREWIND) + if (minor (dev) & WT_NOREWIND) goto done; /* If read file mark is going on, wait */ @@ -388,7 +388,7 @@ wtclose (dev_t dev, int flags, int fmt, struct thread *td) /* Tape was written. Write file mark. */ wtwritefm (t); - if (! (minor (dev) & T_NOREWIND)) { + if (! (minor (dev) & WT_NOREWIND)) { /* Rewind tape to beginning of tape. */ /* Don't wait until rewind, though. */ wtrewind (t); @@ -414,7 +414,7 @@ done: static int wtioctl (dev_t dev, u_long cmd, caddr_t arg, int flags, struct thread *td) { - int u = minor (dev) & T_UNIT; + int u = minor (dev) & WT_UNIT; wtinfo_t *t = wttab + u; int error, count, op; @@ -512,7 +512,7 @@ wtioctl (dev_t dev, u_long cmd, caddr_t arg, int flags, struct thread *td) static void wtstrategy (struct bio *bp) { - int u = minor (bp->bio_dev) & T_UNIT; + int u = minor (bp->bio_dev) & WT_UNIT; wtinfo_t *t = wttab + u; int s; diff --git a/sys/i386/isa/wtreg.h b/sys/i386/isa/wtreg.h index 33f0ee4..8972de1 100644 --- a/sys/i386/isa/wtreg.h +++ b/sys/i386/isa/wtreg.h @@ -114,3 +114,5 @@ #define WT_QIC150 0040 /* 150 megabytes */ #define WT_QIC300 0050 /* 300 megabytes? */ #define WT_QIC600 0060 /* 600 megabytes? */ +#define WT_UNIT 0003 /* unit selection */ +#define WT_NOREWIND 0004 /* no rewind on close */ |