summaryrefslogtreecommitdiffstats
path: root/sys/kern
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2000-04-25 10:51:18 +0000
committerphk <phk@FreeBSD.org>2000-04-25 10:51:18 +0000
commita708c222de7b2882a8f9e471911f7768d353532c (patch)
tree845969f3fdfdd9a87c329c4f057492cffe310673 /sys/kern
parent7dbc44ea9253465e587b32df22ba4bef4b564e19 (diff)
downloadFreeBSD-src-a708c222de7b2882a8f9e471911f7768d353532c.zip
FreeBSD-src-a708c222de7b2882a8f9e471911f7768d353532c.tar.gz
Clone the {b|bio}_offset field, and make sure it is always initialized
in struct bio. Eventually, bio_offset will probably obsolete the bio_blkno and bio_pblkno fields. Remove the special hack in atapi-cd.c to determine of bio_offset was valid.
Diffstat (limited to 'sys/kern')
-rw-r--r--sys/kern/subr_disk.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/kern/subr_disk.c b/sys/kern/subr_disk.c
index 0838056..cf25c1b 100644
--- a/sys/kern/subr_disk.c
+++ b/sys/kern/subr_disk.c
@@ -201,6 +201,8 @@ diskstrategy(struct bio *bp)
return;
}
+ KASSERT(dp->d_devsw != NULL, ("NULL devsw"));
+ KASSERT(dp->d_devsw->d_strategy != NULL, ("NULL d_strategy"));
dp->d_devsw->d_strategy(bp);
return;
OpenPOWER on IntegriCloud