diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c index 3b931056edf5..2a4a2c19f22c 100644 --- a/sys/kern/vfs_subr.c +++ b/sys/kern/vfs_subr.c @@ -171,6 +171,16 @@ vinvalbuf(struct vnode *vp, int flags, kauth_cred_t cred, struct lwp *l, mutex_enter(&bufcache_lock); restart: for (bp = LIST_FIRST(&vp->v_dirtyblkhd); bp; bp = nbp) { + if (bp->b_vp != vp) { + if (bp->b_vp) + vprint("bp->b_vp", bp->b_vp); + else + printf("bp->b_vp is null\n"); + if (vp) + vprint("vp", vp); + else + printf("vp is null\n"); + } KASSERT(bp->b_vp == vp); nbp = LIST_NEXT(bp, b_vnbufs); error = bbusy(bp, catch_p, slptimeo, NULL); @@ -184,6 +194,16 @@ restart: } for (bp = LIST_FIRST(&vp->v_cleanblkhd); bp; bp = nbp) { + if (bp->b_vp != vp) { + if (bp->b_vp) + vprint("bp->b_vp", bp->b_vp); + else + printf("bp->b_vp is null\n"); + if (vp) + vprint("vp", vp); + else + printf("vp is null\n"); + } KASSERT(bp->b_vp == vp); nbp = LIST_NEXT(bp, b_vnbufs); error = bbusy(bp, catch_p, slptimeo, NULL);