aboutsummaryrefslogtreecommitdiff
path: root/sys/ufs
diff options
context:
space:
mode:
authorEdward Tomasz Napierala <trasz@FreeBSD.org>2012-10-28 18:53:28 +0000
committerEdward Tomasz Napierala <trasz@FreeBSD.org>2012-10-28 18:53:28 +0000
commitf1988d463c46639aee395ddc358d23c15b679836 (patch)
treea8274741ab2a30beb688f6a32bf3541d5b26f826 /sys/ufs
parenta93c5097c9b022581b216b02e779829f482f3782 (diff)
downloadsrc-f1988d463c46639aee395ddc358d23c15b679836.tar.gz
src-f1988d463c46639aee395ddc358d23c15b679836.zip
Fix two problems that caused instant panic when the device mounted
with softupdates went away. Note that this does not fix the problem entirely; I'm committing it now to make it easier for someone to pick up the work. Reviewed by: mckusick
Notes
Notes: svn path=/head/; revision=242259
Diffstat (limited to 'sys/ufs')
-rw-r--r--sys/ufs/ffs/ffs_softdep.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/sys/ufs/ffs/ffs_softdep.c b/sys/ufs/ffs/ffs_softdep.c
index c14af048dbd4..b4108203b886 100644
--- a/sys/ufs/ffs/ffs_softdep.c
+++ b/sys/ufs/ffs/ffs_softdep.c
@@ -13342,8 +13342,13 @@ softdep_deallocate_dependencies(bp)
if ((bp->b_ioflags & BIO_ERROR) == 0)
panic("softdep_deallocate_dependencies: dangling deps");
- softdep_error(bp->b_vp->v_mount->mnt_stat.f_mntonname, bp->b_error);
- panic("softdep_deallocate_dependencies: unrecovered I/O error");
+ if (bp->b_vp != NULL && bp->b_vp->v_mount != NULL)
+ softdep_error(bp->b_vp->v_mount->mnt_stat.f_mntonname, bp->b_error);
+ else
+ printf("softdep_deallocate_dependencies: "
+ "got error %d while accessing filesystem\n", bp->b_error);
+ if (bp->b_error != ENXIO)
+ panic("softdep_deallocate_dependencies: unrecovered I/O error");
}
/*