svn commit: r206751 - stable/8/sys/kern

Andriy Gapon avg at FreeBSD.org
Sat Apr 17 11:06:43 UTC 2010


Author: avg
Date: Sat Apr 17 11:06:42 2010
New Revision: 206751
URL: http://svn.freebsd.org/changeset/base/206751

Log:
  MFC r205860,206097: correctly set b_offset for getblk(devvp)

Modified:
  stable/8/sys/kern/vfs_bio.c
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/amd64/include/xen/   (props changed)
  stable/8/sys/cddl/contrib/opensolaris/   (props changed)
  stable/8/sys/contrib/dev/acpica/   (props changed)
  stable/8/sys/contrib/pf/   (props changed)
  stable/8/sys/dev/xen/xenpci/   (props changed)

Modified: stable/8/sys/kern/vfs_bio.c
==============================================================================
--- stable/8/sys/kern/vfs_bio.c	Sat Apr 17 09:50:13 2010	(r206750)
+++ stable/8/sys/kern/vfs_bio.c	Sat Apr 17 11:06:42 2010	(r206751)
@@ -2678,7 +2678,7 @@ loop:
 		 */
 		if (flags & GB_NOCREAT)
 			return NULL;
-		bsize = bo->bo_bsize;
+		bsize = vn_isdisk(vp, NULL) ? DEV_BSIZE : bo->bo_bsize;
 		offset = blkno * bsize;
 		vmio = vp->v_object != NULL;
 		maxsize = vmio ? size + (offset & PAGE_MASK) : size;


More information about the svn-src-stable mailing list