diff options
author | phk <phk@FreeBSD.org> | 2002-10-05 13:12:10 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 2002-10-05 13:12:10 +0000 |
commit | 80931223ac7f88364544082f3900b5c0bb218668 (patch) | |
tree | 5bd114e5fdb7f5451de2db8e0f9ad264a206734e /tools/regression | |
parent | faad129ed6caf62350e5d3c92678a7529f6335bf (diff) | |
download | FreeBSD-src-80931223ac7f88364544082f3900b5c0bb218668.zip FreeBSD-src-80931223ac7f88364544082f3900b5c0bb218668.tar.gz |
Match the new g_io_deliver() API in the kernel.
Sponsored by: DARPA & NAI Labs.
Diffstat (limited to 'tools/regression')
-rw-r--r-- | tools/regression/geom/geom_simdisk.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/tools/regression/geom/geom_simdisk.c b/tools/regression/geom/geom_simdisk.c index c04c4a9..c2757dd 100644 --- a/tools/regression/geom/geom_simdisk.c +++ b/tools/regression/geom/geom_simdisk.c @@ -83,14 +83,12 @@ g_simdisk_start(struct bio *bp) dsp = g_simdisk_findsector(sc, off, 1); ot = lseek(sc->fd, off, SEEK_SET); if (ot != off) { - bp->bio_error = EIO; - g_io_deliver(bp); + g_io_deliver(bp, EIO); return; } i = read(sc->fd, dsp->data, sc->sectorsize); if (i < 0) { - bp->bio_error = errno; - g_io_deliver(bp); + g_io_deliver(bp, errno); return; } if (i == 0) @@ -102,7 +100,7 @@ g_simdisk_start(struct bio *bp) op += sc->sectorsize; nsec--; } - g_io_deliver(bp); + g_io_deliver(bp, 0); return; } if (bp->bio_cmd == BIO_GETATTR) { @@ -117,8 +115,7 @@ g_simdisk_start(struct bio *bp) if (g_handleattr_off_t(bp, "GEOM::mediasize", sc->mediasize)) return; } - bp->bio_error = EOPNOTSUPP; - g_io_deliver(bp); + g_io_deliver(bp, EOPNOTSUPP); } void |