diff options
| author | Matthew Dillon <dillon@FreeBSD.org> | 1999-09-20 16:19:24 +0000 |
|---|---|---|
| committer | Matthew Dillon <dillon@FreeBSD.org> | 1999-09-20 16:19:24 +0000 |
| commit | d909b5635d25e0f8f1c8470e40dc0d4df32a4520 (patch) | |
| tree | c4158052a22b494d8980eb12e4cda7f3ed0c37a3 | |
| parent | 43834dfd27f6833464f15deb2ce0d69017ed439a (diff) | |
Notes
| -rw-r--r-- | sys/kern/vfs_bio.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/sys/kern/vfs_bio.c b/sys/kern/vfs_bio.c index 2f8f85a53b30f..9de72003c2ba0 100644 --- a/sys/kern/vfs_bio.c +++ b/sys/kern/vfs_bio.c @@ -861,11 +861,13 @@ brelse(struct buf * bp) if (bp->b_flags & B_LOCKED) bp->b_flags &= ~B_ERROR; - if ((bp->b_flags & (B_READ | B_ERROR)) == B_ERROR) { + if ((bp->b_flags & (B_READ | B_ERROR | B_INVAL)) == B_ERROR) { /* * Failed write, redirty. Must clear B_ERROR to prevent - * pages from being scrapped. Note: B_INVAL is ignored - * here but will presumably be dealt with later. + * pages from being scrapped. If B_INVAL is set then + * this case is not run and the next case is run to + * destroy the buffer. B_INVAL can occur if the buffer + * is outside the range supported by the underlying device. */ bp->b_flags &= ~B_ERROR; bdirty(bp); |
