svn commit: r262180 - stable/9/sys/cddl/contrib/opensolaris/uts/common/fs/zfs

Andriy Gapon avg at FreeBSD.org
Tue Feb 18 15:45:03 UTC 2014


Author: avg
Date: Tue Feb 18 15:45:02 2014
New Revision: 262180
URL: http://svnweb.freebsd.org/changeset/base/262180

Log:
  MFC r259576: MFV r258923: 4188 assertion failed in dmu_tx_hold_free():
  dn_datablkshift != 0

Modified:
  stable/9/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c
Directory Properties:
  stable/9/sys/   (props changed)
  stable/9/sys/cddl/contrib/opensolaris/   (props changed)

Modified: stable/9/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c
==============================================================================
--- stable/9/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c	Tue Feb 18 15:39:59 2014	(r262179)
+++ stable/9/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c	Tue Feb 18 15:45:02 2014	(r262180)
@@ -636,9 +636,16 @@ dmu_tx_hold_free(dmu_tx_t *tx, uint64_t 
 		uint64_t start = off >> shift;
 		uint64_t end = (off + len) >> shift;
 
-		ASSERT(dn->dn_datablkshift != 0);
 		ASSERT(dn->dn_indblkshift != 0);
 
+		/*
+		 * dnode_reallocate() can result in an object with indirect
+		 * blocks having an odd data block size.  In this case,
+		 * just check the single block.
+		 */
+		if (dn->dn_datablkshift == 0)
+			start = end = 0;
+
 		zio = zio_root(tx->tx_pool->dp_spa,
 		    NULL, NULL, ZIO_FLAG_CANFAIL);
 		for (uint64_t i = start; i <= end; i++) {


More information about the svn-src-stable-9 mailing list