summaryrefslogtreecommitdiffstats
path: root/sys/geom/geom_ccd.c
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>1999-05-07 07:03:47 +0000
committerphk <phk@FreeBSD.org>1999-05-07 07:03:47 +0000
commit7f79e0b14a5e8b99418d156f26b7b4026a163eca (patch)
tree64910f3b88102ea4099d5b4c903f873d9a777b12 /sys/geom/geom_ccd.c
parent87d0bb82afc01a49a3747975f2dda83e9e025bd1 (diff)
downloadFreeBSD-src-7f79e0b14a5e8b99418d156f26b7b4026a163eca.zip
FreeBSD-src-7f79e0b14a5e8b99418d156f26b7b4026a163eca.tar.gz
Introduce two functions: physread() and physwrite() and use these directly
in *devsw[] rather than the 46 local copies of the same functions. (grog will do the same for vinum when he has time)
Diffstat (limited to 'sys/geom/geom_ccd.c')
-rw-r--r--sys/geom/geom_ccd.c18
1 files changed, 2 insertions, 16 deletions
diff --git a/sys/geom/geom_ccd.c b/sys/geom/geom_ccd.c
index 8b1436d..f2e9525 100644
--- a/sys/geom/geom_ccd.c
+++ b/sys/geom/geom_ccd.c
@@ -1,4 +1,4 @@
-/* $Id: ccd.c,v 1.43 1999/03/11 18:50:39 dg Exp $ */
+/* $Id: ccd.c,v 1.44 1999/05/06 19:19:30 phk Exp $ */
/* $NetBSD: ccd.c,v 1.22 1995/12/08 19:13:26 thorpej Exp $ */
@@ -164,8 +164,6 @@ struct ccdbuf {
(makedev(major((dev)), dkmakeminor(ccdunit((dev)), 0, RAW_PART)))
static d_open_t ccdopen;
-static d_read_t ccdread;
-static d_write_t ccdwrite;
static d_close_t ccdclose;
static d_strategy_t ccdstrategy;
static d_ioctl_t ccdioctl;
@@ -176,7 +174,7 @@ static d_psize_t ccdsize;
#define BDEV_MAJOR 21
static struct cdevsw ccd_cdevsw = {
- ccdopen, ccdclose, ccdread, ccdwrite,
+ ccdopen, ccdclose, physread, physwrite,
ccdioctl, nostop, nullreset, nodevtotty,
seltrue, nommap, ccdstrategy, "ccd",
NULL, -1, ccddump, ccdsize,
@@ -713,18 +711,6 @@ ccdclose(dev, flags, fmt, p)
return (0);
}
-static int
-ccdread(dev_t dev, struct uio *uio, int ioflag)
-{
- return (physio(ccdstrategy, NULL, dev, 1, minphys, uio));
-}
-
-static int
-ccdwrite(dev_t dev, struct uio *uio, int ioflag)
-{
- return (physio(ccdstrategy, NULL, dev, 0, minphys, uio));
-}
-
static void
ccdstrategy(bp)
register struct buf *bp;
OpenPOWER on IntegriCloud