aboutsummaryrefslogtreecommitdiff
path: root/sys/isa
diff options
context:
space:
mode:
authorPoul-Henning Kamp <phk@FreeBSD.org>2003-03-08 21:32:59 +0000
committerPoul-Henning Kamp <phk@FreeBSD.org>2003-03-08 21:32:59 +0000
commit80980460993d69177eb59aee1f6a15a4a65b04a4 (patch)
treeaa51483fba343aeeb6e1a38ed027be9f71d9d439 /sys/isa
parentae77078c256733f3d88ae49a84aa8af484a2fde5 (diff)
downloadsrc-80980460993d69177eb59aee1f6a15a4a65b04a4.tar.gz
src-80980460993d69177eb59aee1f6a15a4a65b04a4.zip
Allocate the devstat structure with devstat_new_entry().
Notes
Notes: svn path=/head/; revision=112004
Diffstat (limited to 'sys/isa')
-rw-r--r--sys/isa/fd.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/sys/isa/fd.c b/sys/isa/fd.c
index bb2cc86de2bb..dd0609a12290 100644
--- a/sys/isa/fd.c
+++ b/sys/isa/fd.c
@@ -313,7 +313,7 @@ struct fd_data {
int options; /* user configurable options, see fdcio.h */
struct callout_handle toffhandle;
struct callout_handle tohandle;
- struct devstat device_stats;
+ struct devstat *device_stats;
eventhandler_tag clonetag;
dev_t masterdev;
dev_t clonedevs[NUMDENS - 1];
@@ -1330,7 +1330,7 @@ fd_attach(device_t dev)
UID_ROOT, GID_OPERATOR, 0640, "fd%d", fd->fdu);
for (i = 0; i < NUMDENS - 1; i++)
fd->clonedevs[i] = NODEV;
- devstat_add_entry(&fd->device_stats, device_get_name(dev),
+ fd->device_stats = devstat_new_entry(device_get_name(dev),
device_get_unit(dev), 0, DEVSTAT_NO_ORDERED_TAGS,
DEVSTAT_TYPE_FLOPPY | DEVSTAT_TYPE_IF_OTHER,
DEVSTAT_PRIORITY_FD);
@@ -1345,7 +1345,7 @@ fd_detach(device_t dev)
fd = device_get_softc(dev);
untimeout(fd_turnoff, fd, fd->toffhandle);
- devstat_remove_entry(&fd->device_stats);
+ devstat_remove_entry(fd->device_stats);
destroy_dev(fd->masterdev);
for (i = 0; i < NUMDENS - 1; i++)
if (fd->clonedevs[i] != NODEV)
@@ -1724,7 +1724,7 @@ fdstrategy(struct bio *bp)
s = splbio();
bioqdisksort(&fdc->head, bp);
untimeout(fd_turnoff, fd, fd->toffhandle); /* a good idea */
- devstat_start_transaction(&fd->device_stats);
+ devstat_start_transaction(fd->device_stats);
device_busy(fd->dev);
fdstart(fdc);
splx(s);
@@ -2372,7 +2372,7 @@ fdstate(fdc_p fdc)
bp->bio_resid = 0;
fdc->bp = NULL;
device_unbusy(fd->dev);
- biofinish(bp, &fd->device_stats, 0);
+ biofinish(bp, fd->device_stats, 0);
fdc->fd = (fd_p) 0;
fdc->fdu = -1;
fdc->state = FINDWORK;
@@ -2530,7 +2530,7 @@ retrier(struct fdc_data *fdc)
fdc->bp = NULL;
fdc->fd->skip = 0;
device_unbusy(fd->dev);
- biofinish(bp, &fdc->fd->device_stats, 0);
+ biofinish(bp, fdc->fd->device_stats, 0);
fdc->state = FINDWORK;
fdc->flags |= FDC_NEEDS_RESET;
fdc->fd = (fd_p) 0;