diff options
author | dg <dg@FreeBSD.org> | 1999-01-22 09:07:32 +0000 |
---|---|---|
committer | dg <dg@FreeBSD.org> | 1999-01-22 09:07:32 +0000 |
commit | 416e7bfc5a6e4f73ffb52bd0875bc1d76b73ef9f (patch) | |
tree | fb11eab57e7025bc61b29305670e91e9e60a9dfc /sys/ufs | |
parent | e4e8fec98ae986357cdc208b04557dba55a59266 (diff) | |
download | FreeBSD-src-416e7bfc5a6e4f73ffb52bd0875bc1d76b73ef9f.zip FreeBSD-src-416e7bfc5a6e4f73ffb52bd0875bc1d76b73ef9f.tar.gz |
Gutted softdep_deallocate_dependencies and replaced it with a panic. It
turns out to not be useful to unwind the dependencies and continue in
the face of a fatal error.
Also changed the log() to a printf() in softdep_error() so that it will
be output in the case of a impending panic.
Submitted by: Kirk McKusick <mckusick@mckusick.com>
Diffstat (limited to 'sys/ufs')
-rw-r--r-- | sys/ufs/ffs/ffs_softdep.c | 44 |
1 files changed, 3 insertions, 41 deletions
diff --git a/sys/ufs/ffs/ffs_softdep.c b/sys/ufs/ffs/ffs_softdep.c index 433cafe..c82f929 100644 --- a/sys/ufs/ffs/ffs_softdep.c +++ b/sys/ufs/ffs/ffs_softdep.c @@ -54,7 +54,7 @@ * SUCH DAMAGE. * * from: @(#)ffs_softdep.c 9.28 (McKusick) 8/8/98 - * $Id: ffs_softdep.c,v 1.19 1999/01/06 18:18:04 bde Exp $ + * $Id: ffs_softdep.c,v 1.20 1999/01/07 16:14:10 bde Exp $ */ /* @@ -4178,43 +4178,8 @@ void softdep_deallocate_dependencies(bp) struct buf *bp; { - struct worklist *wk; - - if ((bp->b_flags & B_ERROR) == 0) - panic("softdep_deallocate_dependencies: dangling deps"); softdep_error(bp->b_vp->v_mount->mnt_stat.f_mntonname, bp->b_error); - ACQUIRE_LOCK(&lk); - while ((wk = LIST_FIRST(&bp->b_dep)) != NULL) { - WORKLIST_REMOVE(wk); - FREE_LOCK(&lk); - switch (wk->wk_type) { - /* - * XXX - should really clean up, but for now we will - * just leak memory and not worry about it. Also should - * mark the filesystem permanently dirty so that it will - * force fsck to be run (though this would best be done - * in the mainline code). - */ - case D_PAGEDEP: - case D_INODEDEP: - case D_BMSAFEMAP: - case D_ALLOCDIRECT: - case D_INDIRDEP: - case D_ALLOCINDIR: - case D_MKDIR: -#ifdef DEBUG - printf("Lost type %s\n", TYPENAME(wk->wk_type)); -#endif - break; - default: - panic("%s: Unexpected type %s", - "softdep_deallocate_dependencies", - TYPENAME(wk->wk_type)); - /* NOTREACHED */ - } - ACQUIRE_LOCK(&lk); - } - FREE_LOCK(&lk); + panic("softdep_deallocate_dependencies: dangling deps"); } /* @@ -4225,9 +4190,6 @@ softdep_error(func, error) char *func; int error; { - /* XXX should do something better! */ - log(LOG_ERR, "%s: got error %d while accessing filesystem\n", - func, error); + printf("%s: got error %d while accessing filesystem\n", func, error); } - |