summaryrefslogtreecommitdiffstats
path: root/sys/dev/ata/ata-disk.c
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2003-02-21 19:00:48 +0000
committerphk <phk@FreeBSD.org>2003-02-21 19:00:48 +0000
commit02e550fabbccfb3ee4ca8b767f672f042bce9239 (patch)
tree0a783f7251946cbeba07417df9c459d72a6aa14e /sys/dev/ata/ata-disk.c
parentc6646c2f7da7d39f3506c8ff46b821f065dc318f (diff)
downloadFreeBSD-src-02e550fabbccfb3ee4ca8b767f672f042bce9239.zip
FreeBSD-src-02e550fabbccfb3ee4ca8b767f672f042bce9239.tar.gz
NO_GEOM cleanup:
Retire the "d_dump_t" and use the "dumper_t" type instead. Dumper_t takes a void * as first arg which is more general than the dev_t taken by d_dump_t. (Remember: we could have net-dumpers if somebody wrote us one!) Define the convention for GEOM controlled disk devices to be that the first argument to the dumper function is the struct disk pointer. Change device drivers accordingly.
Diffstat (limited to 'sys/dev/ata/ata-disk.c')
-rw-r--r--sys/dev/ata/ata-disk.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/sys/dev/ata/ata-disk.c b/sys/dev/ata/ata-disk.c
index 6478171..13906ab 100644
--- a/sys/dev/ata/ata-disk.c
+++ b/sys/dev/ata/ata-disk.c
@@ -55,7 +55,7 @@
static d_open_t adopen;
static d_close_t adclose;
static d_strategy_t adstrategy;
-static d_dump_t addump;
+static dumper_t addump;
static struct cdevsw ad_cdevsw = {
/* open */ adopen,
/* close */ adclose,
@@ -315,12 +315,15 @@ adstrategy(struct bio *bp)
}
static int
-addump(dev_t dev, void *virtual, vm_offset_t physical, off_t offset, size_t length)
+addump(void *arg, void *virtual, vm_offset_t physical, off_t offset, size_t length)
{
- struct ad_softc *adp = dev->si_drv1;
+ struct ad_softc *adp;
struct ad_request request;
static int once;
+ struct disk *dp;
+ dp = arg;
+ adp = dp->d_dev->si_drv1;
if (!adp)
return ENXIO;
OpenPOWER on IntegriCloud