summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcth <none@none>2006-07-22 14:55:09 -0700
committercth <none@none>2006-07-22 14:55:09 -0700
commit6f84fed5adadb9b854b3f7100b25ac8d57edcd57 (patch)
treed222fc3e431abc8c9ce485b8d5624f3b9ac6f055
parent0b69c2f001a429251e2d38f25aca860396551214 (diff)
downloadillumos-gate-6f84fed5adadb9b854b3f7100b25ac8d57edcd57.tar.gz
6384832 bioclone representation of bp_mapin buffer could be misinterpreted
-rw-r--r--usr/src/uts/common/os/bio.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/usr/src/uts/common/os/bio.c b/usr/src/uts/common/os/bio.c
index 554f3d2bf5..a828f28272 100644
--- a/usr/src/uts/common/os/bio.c
+++ b/usr/src/uts/common/os/bio.c
@@ -2,9 +2,8 @@
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
- * Common Development and Distribution License, Version 1.0 only
- * (the "License"). You may not use this file except in compliance
- * with the License.
+ * Common Development and Distribution License (the "License").
+ * You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* or http://www.opensolaris.org/os/licensing.
@@ -20,7 +19,7 @@
* CDDL HEADER END
*/
/*
- * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
@@ -2043,8 +2042,7 @@ bioclone(struct buf *bp, off_t off, size_t len, dev_t dev, daddr_t blkno,
B_ABRWRITE)
/*
- * the cloned buffer does not inherit the B_REMAPPED flag. A separate
- * bp_mapin(9F) has to be done to get a kernel mapping.
+ * The cloned buffer does not inherit the B_REMAPPED flag.
*/
bufp->b_flags = (bp->b_flags & BUF_CLONE_FLAGS) | B_BUSY;
bufp->b_bcount = len;
@@ -2062,6 +2060,8 @@ bioclone(struct buf *bp, off_t off, size_t len, dev_t dev, daddr_t blkno,
bufp->b_shadow = bp->b_shadow +
btop(((uintptr_t)bp->b_un.b_addr & PAGEOFFSET) + off);
bufp->b_un.b_addr = (caddr_t)((uintptr_t)bp->b_un.b_addr + off);
+ if (bp->b_flags & B_REMAPPED)
+ bufp->b_proc = NULL;
} else {
if (bp->b_flags & B_PAGEIO) {
struct page *pp;