Skip to content

Commit

Permalink
4188 assertion failed in dmu_tx_hold_free(): dn_datablkshift != 0
Browse files Browse the repository at this point in the history
Reviewed by: George Wilson <[email protected]>
Reviewed by: Christopher Siden <[email protected]>
Approved by: Garrett D'Amore <[email protected]>

Refences:
  https://www.illumos.org/issues/4188
  illumos/illumos-gate@bb411a0

Ported-by: Chris Dunlop <[email protected]>
Signed-off-by: Brian Behlendorf <[email protected]>
Closes openzfs#2091
  • Loading branch information
ahrens authored and behlendorf committed Jan 31, 2014
1 parent 8b46464 commit 2e7b765
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion module/zfs/dmu_tx.c
Original file line number Diff line number Diff line change
Expand Up @@ -656,9 +656,16 @@ dmu_tx_hold_free(dmu_tx_t *tx, uint64_t object, uint64_t off, uint64_t len)
uint64_t end = (off + len) >> shift;
uint64_t i;

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 (i = start; i <= end; i++) {
Expand Down

0 comments on commit 2e7b765

Please sign in to comment.