diff options
| author | 2007-05-05 12:43:35 +0000 | |
|---|---|---|
| committer | 2007-05-05 12:43:35 +0000 | |
| commit | bb6f825e9ec61ed1105ef7296106d6a851a05819 (patch) | |
| tree | ca56bbbdd80f28dfb797b66cbd8f17f8fd1b82c8 /sys/kern/subr_disk.c | |
| parent | Properly ifdef debug bits to save a bit of space. (diff) | |
| download | wireguard-openbsd-bb6f825e9ec61ed1105ef7296106d6a851a05819.tar.xz wireguard-openbsd-bb6f825e9ec61ed1105ef7296106d6a851a05819.zip | |
Kill disk_find and disk_resetstat that noone uses. If you ever need
them, they are still in cvs.
Diffstat (limited to 'sys/kern/subr_disk.c')
| -rw-r--r-- | sys/kern/subr_disk.c | 46 |
1 files changed, 1 insertions, 45 deletions
diff --git a/sys/kern/subr_disk.c b/sys/kern/subr_disk.c index e0a01cce326..69d177b446a 100644 --- a/sys/kern/subr_disk.c +++ b/sys/kern/subr_disk.c @@ -1,4 +1,4 @@ -/* $OpenBSD: subr_disk.c,v 1.37 2007/05/04 23:21:23 deraadt Exp $ */ +/* $OpenBSD: subr_disk.c,v 1.38 2007/05/05 12:43:35 art Exp $ */ /* $NetBSD: subr_disk.c,v 1.17 1996/03/16 23:17:08 christos Exp $ */ /* @@ -243,25 +243,6 @@ disk_init(void) disk_count = disk_change = 0; } -/* - * Searches the disklist for the disk corresponding to the - * name provided. - */ -struct disk * -disk_find(char *name) -{ - struct disk *diskp; - - if ((name == NULL) || (disk_count <= 0)) - return (NULL); - - TAILQ_FOREACH(diskp, &disklist, dk_link) - if (strcmp(diskp->dk_name, name) == 0) - return (diskp); - - return (NULL); -} - int disk_construct(struct disk *diskp, char *lockname) { @@ -396,31 +377,6 @@ disk_unlock(struct disk *dk) rw_exit(&dk->dk_lock); } -/* - * Reset the metrics counters on the given disk. Note that we cannot - * reset the busy counter, as it may case a panic in disk_unbusy(). - * We also must avoid playing with the timestamp information, as it - * may skew any pending transfer results. - */ -void -disk_resetstat(struct disk *diskp) -{ - int s = splbio(); - - diskp->dk_rxfer = 0; - diskp->dk_rbytes = 0; - diskp->dk_wxfer = 0; - diskp->dk_wbytes = 0; - diskp->dk_seek = 0; - - microuptime(&diskp->dk_attachtime); - - timerclear(&diskp->dk_time); - - splx(s); -} - - int dk_mountroot(void) { |
