diff options
author | phk <phk@FreeBSD.org> | 1999-05-07 07:03:47 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 1999-05-07 07:03:47 +0000 |
commit | 7f79e0b14a5e8b99418d156f26b7b4026a163eca (patch) | |
tree | 64910f3b88102ea4099d5b4c903f873d9a777b12 /sys/vm/vm_swap.c | |
parent | 87d0bb82afc01a49a3747975f2dda83e9e025bd1 (diff) | |
download | FreeBSD-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/vm/vm_swap.c')
-rw-r--r-- | sys/vm/vm_swap.c | 18 |
1 files changed, 2 insertions, 16 deletions
diff --git a/sys/vm/vm_swap.c b/sys/vm/vm_swap.c index 30ae7e7..0f3ad71 100644 --- a/sys/vm/vm_swap.c +++ b/sys/vm/vm_swap.c @@ -31,7 +31,7 @@ * SUCH DAMAGE. * * @(#)vm_swap.c 8.5 (Berkeley) 2/17/94 - * $Id: vm_swap.c,v 1.62 1999/04/27 11:18:52 phk Exp $ + * $Id: vm_swap.c,v 1.63 1999/04/28 10:54:24 dt Exp $ */ #include "opt_devfs.h" @@ -70,14 +70,12 @@ */ static d_strategy_t swstrategy; -static d_read_t swread; -static d_write_t swwrite; #define CDEV_MAJOR 4 #define BDEV_MAJOR 26 static struct cdevsw sw_cdevsw = - { nullopen, nullclose, swread, swwrite, /*4*/ + { nullopen, nullclose, physread, physwrite, /*4*/ noioc, nostop, noreset, nodevtotty,/* swap */ seltrue, nommap, swstrategy, "sw", NULL, -1, nodump, nopsize, @@ -99,18 +97,6 @@ static int nswap; /* first block after the interleaved devs */ static int nswdev = NSWAPDEV; int vm_swap_size; -static int -swread(dev_t dev, struct uio *uio, int ioflag) -{ - return (physio(swstrategy, NULL, dev, 1, minphys, uio)); -} - -static int -swwrite(dev_t dev, struct uio *uio, int ioflag) -{ - return (physio(swstrategy, NULL, dev, 0, minphys, uio)); -} - /* * swstrategy: * |