]> git.proxmox.com Git - mirror_zfs.git/commit
dmu_zfetch: fix memory leak
authorMatthew Macy <mmacy@freebsd.org>
Sun, 13 Dec 2020 00:00:00 +0000 (16:00 -0800)
committerGitHub <noreply@github.com>
Sun, 13 Dec 2020 00:00:00 +0000 (16:00 -0800)
commit923d730329290c7dc8ae5b4d27c6ed01d24d9f4c
tree2e285cd70b66efb49072dfb7f3167e75617b3717
parentc76a40bfdaedd1eb2c037dfdf822ea5c4db97397
dmu_zfetch: fix memory leak

The last change caused the read completion callback to not be called
if the IO was still in progress. This change restores allocation
of the arc buf callback, but in the callback path checks the new
acb_nobuf field to know to skip buffer allocation.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Matt Macy <mmacy@FreeBSD.org>
Closes #11324
include/sys/arc_impl.h
module/zfs/arc.c