Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 7 Aug 2012 20:16:10 +0000 (UTC)
From:      Jim Harris <jimharris@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r239132 - head/sys/geom
Message-ID:  <201208072016.q77KGAX9000968@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jimharris
Date: Tue Aug  7 20:16:10 2012
New Revision: 239132
URL: http://svn.freebsd.org/changeset/base/239132

Log:
  Clone BIO_ORDERED flag, for disk drivers (namely CAM) that try to
   consume it.
  
  Sponsored by: Intel
  Discussed with: gibbs, scottl

Modified:
  head/sys/geom/geom_io.c

Modified: head/sys/geom/geom_io.c
==============================================================================
--- head/sys/geom/geom_io.c	Tue Aug  7 18:50:33 2012	(r239131)
+++ head/sys/geom/geom_io.c	Tue Aug  7 20:16:10 2012	(r239132)
@@ -177,6 +177,12 @@ g_clone_bio(struct bio *bp)
 	if (bp2 != NULL) {
 		bp2->bio_parent = bp;
 		bp2->bio_cmd = bp->bio_cmd;
+		/*
+		 *  BIO_ORDERED flag may be used by disk drivers to enforce
+		 *  ordering restrictions, so this flag needs to be cloned.
+		 *  Other bio flags are not suitable for cloning.
+		 */
+		bp2->bio_flags = bp->bio_flags & BIO_ORDERED;
 		bp2->bio_length = bp->bio_length;
 		bp2->bio_offset = bp->bio_offset;
 		bp2->bio_data = bp->bio_data;



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