Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 15 May 2012 10:09:31 +0000 (UTC)
From:      Grzegorz Bernacki <gber@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-projects@freebsd.org
Subject:   svn commit: r235470 - in projects/nand: . contrib/top share/mk sys/contrib/dev/acpica sys/i386/conf sys/kern
Message-ID:  <201205151009.q4FA9Vhc080465@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: gber
Date: Tue May 15 10:09:31 2012
New Revision: 235470
URL: http://svn.freebsd.org/changeset/base/235470

Log:
  IFC @235469

Modified:
  projects/nand/sys/kern/vfs_bio.c
Directory Properties:
  projects/nand/   (props changed)
  projects/nand/MAINTAINERS   (props changed)
  projects/nand/cddl/contrib/opensolaris/   (props changed)
  projects/nand/contrib/bind9/   (props changed)
  projects/nand/contrib/binutils/   (props changed)
  projects/nand/contrib/bzip2/   (props changed)
  projects/nand/contrib/com_err/   (props changed)
  projects/nand/contrib/compiler-rt/   (props changed)
  projects/nand/contrib/dialog/   (props changed)
  projects/nand/contrib/ee/   (props changed)
  projects/nand/contrib/expat/   (props changed)
  projects/nand/contrib/file/   (props changed)
  projects/nand/contrib/gcc/   (props changed)
  projects/nand/contrib/gdb/   (props changed)
  projects/nand/contrib/gdtoa/   (props changed)
  projects/nand/contrib/gnu-sort/   (props changed)
  projects/nand/contrib/groff/   (props changed)
  projects/nand/contrib/less/   (props changed)
  projects/nand/contrib/libarchive/   (props changed)
  projects/nand/contrib/libarchive/cpio/   (props changed)
  projects/nand/contrib/libarchive/libarchive/   (props changed)
  projects/nand/contrib/libarchive/libarchive_fe/   (props changed)
  projects/nand/contrib/libarchive/tar/   (props changed)
  projects/nand/contrib/libc++/   (props changed)
  projects/nand/contrib/libcxxrt/   (props changed)
  projects/nand/contrib/libpcap/   (props changed)
  projects/nand/contrib/libstdc++/   (props changed)
  projects/nand/contrib/llvm/   (props changed)
  projects/nand/contrib/llvm/tools/clang/   (props changed)
  projects/nand/contrib/ncurses/   (props changed)
  projects/nand/contrib/netcat/   (props changed)
  projects/nand/contrib/ntp/   (props changed)
  projects/nand/contrib/one-true-awk/   (props changed)
  projects/nand/contrib/openbsm/   (props changed)
  projects/nand/contrib/openpam/   (props changed)
  projects/nand/contrib/openresolv/   (props changed)
  projects/nand/contrib/pf/   (props changed)
  projects/nand/contrib/sendmail/   (props changed)
  projects/nand/contrib/tcpdump/   (props changed)
  projects/nand/contrib/tcsh/   (props changed)
  projects/nand/contrib/tnftp/   (props changed)
  projects/nand/contrib/top/   (props changed)
  projects/nand/contrib/top/install-sh   (props changed)
  projects/nand/contrib/tzcode/stdtime/   (props changed)
  projects/nand/contrib/tzcode/zic/   (props changed)
  projects/nand/contrib/tzdata/   (props changed)
  projects/nand/contrib/wpa/   (props changed)
  projects/nand/contrib/xz/   (props changed)
  projects/nand/crypto/heimdal/   (props changed)
  projects/nand/crypto/openssh/   (props changed)
  projects/nand/crypto/openssl/   (props changed)
  projects/nand/gnu/lib/   (props changed)
  projects/nand/gnu/usr.bin/binutils/   (props changed)
  projects/nand/gnu/usr.bin/cc/cc_tools/   (props changed)
  projects/nand/gnu/usr.bin/gdb/   (props changed)
  projects/nand/lib/libc/   (props changed)
  projects/nand/lib/libc/stdtime/   (props changed)
  projects/nand/lib/libutil/   (props changed)
  projects/nand/lib/libz/   (props changed)
  projects/nand/sbin/   (props changed)
  projects/nand/sbin/ipfw/   (props changed)
  projects/nand/share/man/man4/   (props changed)
  projects/nand/share/mk/bsd.arch.inc.mk   (props changed)
  projects/nand/share/zoneinfo/   (props changed)
  projects/nand/sys/   (props changed)
  projects/nand/sys/amd64/include/xen/   (props changed)
  projects/nand/sys/boot/   (props changed)
  projects/nand/sys/boot/i386/efi/   (props changed)
  projects/nand/sys/boot/ia64/efi/   (props changed)
  projects/nand/sys/boot/ia64/ski/   (props changed)
  projects/nand/sys/boot/powerpc/boot1.chrp/   (props changed)
  projects/nand/sys/boot/powerpc/ofw/   (props changed)
  projects/nand/sys/cddl/contrib/opensolaris/   (props changed)
  projects/nand/sys/conf/   (props changed)
  projects/nand/sys/contrib/dev/acpica/   (props changed)
  projects/nand/sys/contrib/dev/acpica/changes.txt   (props changed)
  projects/nand/sys/contrib/dev/acpica/common/   (props changed)
  projects/nand/sys/contrib/dev/acpica/compiler/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/debugger/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/disassembler/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/dispatcher/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/events/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/executer/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/hardware/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/namespace/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/parser/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/resources/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/tables/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/utilities/   (props changed)
  projects/nand/sys/contrib/dev/acpica/include/   (props changed)
  projects/nand/sys/contrib/dev/acpica/os_specific/   (props changed)
  projects/nand/sys/contrib/octeon-sdk/   (props changed)
  projects/nand/sys/contrib/pf/   (props changed)
  projects/nand/sys/contrib/x86emu/   (props changed)
  projects/nand/sys/i386/conf/XENHVM   (props changed)
  projects/nand/usr.bin/calendar/   (props changed)
  projects/nand/usr.bin/csup/   (props changed)
  projects/nand/usr.bin/procstat/   (props changed)
  projects/nand/usr.sbin/jail/   (props changed)
  projects/nand/usr.sbin/ndiscvt/   (props changed)
  projects/nand/usr.sbin/rtadvctl/   (props changed)
  projects/nand/usr.sbin/rtadvd/   (props changed)
  projects/nand/usr.sbin/rtsold/   (props changed)
  projects/nand/usr.sbin/zic/   (props changed)

Modified: projects/nand/sys/kern/vfs_bio.c
==============================================================================
--- projects/nand/sys/kern/vfs_bio.c	Tue May 15 09:55:15 2012	(r235469)
+++ projects/nand/sys/kern/vfs_bio.c	Tue May 15 10:09:31 2012	(r235470)
@@ -2640,8 +2640,8 @@ loop:
 	if (bp != NULL) {
 		int lockflags;
 		/*
-		 * Buffer is in-core.  If the buffer is not busy, it must
-		 * be on a queue.
+		 * Buffer is in-core.  If the buffer is not busy nor managed,
+		 * it must be on a queue.
 		 */
 		lockflags = LK_EXCLUSIVE | LK_SLEEPFAIL | LK_INTERLOCK;
 
@@ -2671,10 +2671,13 @@ loop:
 			bp->b_flags &= ~B_CACHE;
 		else if ((bp->b_flags & (B_VMIO | B_INVAL)) == 0)
 			bp->b_flags |= B_CACHE;
-		BO_LOCK(bo);
-		if (!(bp->b_flags & B_MANAGED))
+		if (bp->b_flags & B_MANAGED)
+			MPASS(bp->b_qindex == QUEUE_NONE);
+		else {
+			BO_LOCK(bo);
 			bremfree(bp);
-		BO_UNLOCK(bo);
+			BO_UNLOCK(bo);
+		}
 
 		/*
 		 * check for size inconsistancies for non-VMIO case.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201205151009.q4FA9Vhc080465>