]> git.proxmox.com Git - mirror_zfs.git/commit
dbuf: Handle arcbuf assignment after block cloning
authorAlexander Motin <mav@FreeBSD.org>
Tue, 12 Dec 2023 20:53:59 +0000 (15:53 -0500)
committerGitHub <noreply@github.com>
Tue, 12 Dec 2023 20:53:59 +0000 (12:53 -0800)
commit86063d90319ac8a785d81ba7e3f8037a7f5389f3
tree261008f9939c6a93628db22e66669c2f2a238620
parentf4b97c1e009006bce43de5ccaf9326f572bf8b7a
dbuf: Handle arcbuf assignment after block cloning

In some cases dbuf_assign_arcbuf() may be called on a block that
was recently cloned.  If it happened in current TXG we must undo
the block cloning first, since the only one dirty record per TXG
can't and shouldn't mean both cloning and overwrite same time.

Reviewed-by: Kay Pedersen <mail@mkwg.de>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Alexander Motin <mav@FreeBSD.org>
Sponsored by: iXsystems, Inc.
Closes #15653
module/zfs/dbuf.c