HomeFreeBSD

Update outdated assertion from zio_write_compress

Description

Update outdated assertion from zio_write_compress

As part of some internal gang block testing within Delphix
we hit the assertion removed by this patch. The assertion
was triggered by a ZIO that had two copies and was a gang
block making the following expression equal to 3:

MIN(zp->zp_copies + BP_IS_GANG(bp), spa_max_replication(spa))

and failing when we expected the above to be equal to
BP_GET_NDVAS(bp).

The assertion is no longer valid since the following commit:

commit 14872aaa4f909d72c6b5e4105dadcfa13c7d9d66
Author: Matthew Ahrens <matthew.ahrens@delphix.com>
Date:   Mon Feb 6 09:37:06 2023 -0800

  EIO caused by encryption + recursive gang

The above commit changed gang block headers so they can't
have more than 2 copies but the assertion in question from
this PR was never updated.

Reviewed-by: George Wilson <george.wilson@delphix.com>
Reviewed-by: Matthew Ahrens <mahrens@delphix.com>
Signed-off-by: Serapheim Dimitropoulos <serapheim@delphix.com>
Closes #15180

Details

Provenance
Serapheim Dimitropoulos <serapheim@delphix.com>Authored on Aug 25 2023, 5:28 PM
GitHub <noreply@github.com>Committed on Aug 25 2023, 5:28 PM
Parents
rGeda3fcd56ff9: ZIL: Second attempt to reduce scope of zl_issuer_lock.
Branches
Unknown
Tags
Unknown

Event Timeline

GitHub <noreply@github.com> committed rGed39d668ea63: Update outdated assertion from zio_write_compress (authored by Serapheim Dimitropoulos <serapheim@delphix.com>).Aug 25 2023, 5:28 PM