aboutsummaryrefslogtreecommitdiff
path: root/sys/miscfs
diff options
context:
space:
mode:
authorPoul-Henning Kamp <phk@FreeBSD.org>2000-03-20 10:44:49 +0000
committerPoul-Henning Kamp <phk@FreeBSD.org>2000-03-20 10:44:49 +0000
commit21144e3bf1f416a758f6546bfabfa8e4e8cba507 (patch)
treec87da548b12fd12c48f1e5c89d087ddfa088ee78 /sys/miscfs
parent44bdcfa638d9ca31180090798a88116220f7f625 (diff)
Notes
Diffstat (limited to 'sys/miscfs')
-rw-r--r--sys/miscfs/devfs/devfs_vnops.c6
-rw-r--r--sys/miscfs/specfs/spec_vnops.c8
-rw-r--r--sys/miscfs/union/union_vnops.c2
3 files changed, 8 insertions, 8 deletions
diff --git a/sys/miscfs/devfs/devfs_vnops.c b/sys/miscfs/devfs/devfs_vnops.c
index 85351ba716e9..9be35c6ffea7 100644
--- a/sys/miscfs/devfs/devfs_vnops.c
+++ b/sys/miscfs/devfs/devfs_vnops.c
@@ -1569,7 +1569,7 @@ devfs_strategy(struct vop_strategy_args *ap)
return error;
- if (((bp->b_flags & B_READ) == 0) &&
+ if ((bp->b_iocmd == BIO_WRITE) &&
(LIST_FIRST(&bp->b_dep)) != NULL && bioops.io_start)
(*bioops.io_start)(bp);
switch (vp->v_type) {
@@ -1606,7 +1606,7 @@ devfs_freeblks(struct vop_freeblks_args *ap)
if ((bsw->d_flags & D_CANFREE) == 0)
return (0);
bp = geteblk(ap->a_length);
- bp->b_flags |= B_FREEBUF;
+ bp->b_iocmd = BIO_DELETE;
bp->b_dev = vp->v_rdev;
bp->b_blkno = ap->a_addr;
bp->b_offset = dbtob(ap->a_addr);
@@ -1834,7 +1834,7 @@ devfs_getpages(struct vop_getpages_args *ap)
pmap_qenter(kva, ap->a_m, pcount);
/* Build a minimal buffer header. */
- bp->b_flags = B_READ | B_CALL;
+ bp->b_iocmd = BIO_READ;
bp->b_iodone = devfs_getpages_iodone;
/* B_PHYS is not set, but it is nice to fill this in. */
diff --git a/sys/miscfs/specfs/spec_vnops.c b/sys/miscfs/specfs/spec_vnops.c
index a9a711e1c859..f48c0c1265f8 100644
--- a/sys/miscfs/specfs/spec_vnops.c
+++ b/sys/miscfs/specfs/spec_vnops.c
@@ -407,7 +407,7 @@ spec_strategy(ap)
struct mount *mp;
bp = ap->a_bp;
- if (((bp->b_flags & B_READ) == 0) &&
+ if ((bp->b_iocmd == BIO_WRITE) &&
(LIST_FIRST(&bp->b_dep)) != NULL && bioops.io_start)
(*bioops.io_start)(bp);
@@ -417,7 +417,7 @@ spec_strategy(ap)
*/
vp = ap->a_vp;
if (vn_isdisk(vp, NULL) && (mp = vp->v_specmountpoint) != NULL) {
- if ((bp->b_flags & B_READ) == 0) {
+ if (bp->b_iocmd == BIO_WRITE) {
if (bp->b_lock.lk_lockholder == LK_KERNPROC)
mp->mnt_stat.f_asyncwrites++;
else
@@ -458,7 +458,7 @@ spec_freeblks(ap)
if ((bsw->d_flags & D_CANFREE) == 0)
return (0);
bp = geteblk(ap->a_length);
- bp->b_flags |= B_FREEBUF;
+ bp->b_iocmd = BIO_DELETE;
bp->b_dev = ap->a_vp->v_rdev;
bp->b_blkno = ap->a_addr;
bp->b_offset = dbtob(ap->a_addr);
@@ -657,7 +657,7 @@ spec_getpages(ap)
pmap_qenter(kva, ap->a_m, pcount);
/* Build a minimal buffer header. */
- bp->b_flags = B_READ | B_CALL;
+ bp->b_iocmd = BIO_READ;
bp->b_iodone = spec_getpages_iodone;
/* B_PHYS is not set, but it is nice to fill this in. */
diff --git a/sys/miscfs/union/union_vnops.c b/sys/miscfs/union/union_vnops.c
index 03d41a01e0d8..38c190b84723 100644
--- a/sys/miscfs/union/union_vnops.c
+++ b/sys/miscfs/union/union_vnops.c
@@ -1923,7 +1923,7 @@ union_strategy(ap)
#ifdef DIAGNOSTIC
if (othervp == NULLVP)
panic("union_strategy: nil vp");
- if (((bp->b_flags & B_READ) == 0) &&
+ if ((bp->b_iocmd == BIO_WRITE) &&
(othervp == LOWERVP(bp->b_vp)))
panic("union_strategy: writing to lowervp");
#endif