diff options
author | bde <bde@FreeBSD.org> | 1998-07-28 19:39:09 +0000 |
---|---|---|
committer | bde <bde@FreeBSD.org> | 1998-07-28 19:39:09 +0000 |
commit | 8f59e52f08b133a1d71386d1dc834fdb82ff122c (patch) | |
tree | 3b74614f4b3093d98fd16c71e36431932f71d9b7 /sys | |
parent | f60ba2125f0c5b877bf812913a7d2ae04ff3afec (diff) | |
download | FreeBSD-src-8f59e52f08b133a1d71386d1dc834fdb82ff122c.zip FreeBSD-src-8f59e52f08b133a1d71386d1dc834fdb82ff122c.tar.gz |
Set bp->b_resid for failed transfers in dscheck(). This is the
best place to set it, and the wd and wfd strategy routines don't
set it (for failed transfers) because they expect dscheck() to
initialize everything necessary. dscheck() has always set B_ERROR,
but this is not quite sufficient, because b_resid is used by physio()
to decide how much of a B_ERROR'ed i/o was done.
Diffstat (limited to 'sys')
-rw-r--r-- | sys/kern/subr_diskslice.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/kern/subr_diskslice.c b/sys/kern/subr_diskslice.c index cde5194..8dde7d6 100644 --- a/sys/kern/subr_diskslice.c +++ b/sys/kern/subr_diskslice.c @@ -43,7 +43,7 @@ * from: wd.c,v 1.55 1994/10/22 01:57:12 phk Exp $ * from: @(#)ufs_disksubr.c 7.16 (Berkeley) 5/4/91 * from: ufs_disksubr.c,v 1.8 1994/06/07 01:21:39 phk Exp $ - * $Id: subr_diskslice.c,v 1.51 1998/07/20 13:51:11 bde Exp $ + * $Id: subr_diskslice.c,v 1.52 1998/07/20 14:35:27 bde Exp $ */ #include "opt_devfs.h" @@ -281,6 +281,7 @@ if (labelsect != 0) Debugger("labelsect != 0 in dscheck()"); return (1); bad: + bp->b_resid = bp->b_bcount; bp->b_flags |= B_ERROR; return (-1); } |