]> granicus.if.org Git - zfs/commit
Encrypted dnode blocks should be prefetched raw
authorTom Caputi <tcaputi@datto.com>
Sat, 31 Mar 2018 18:11:48 +0000 (14:11 -0400)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Sat, 31 Mar 2018 18:11:48 +0000 (11:11 -0700)
commit4515b1d01c936b8cf156e20ba42cdb8916bca80b
tree7a21c01a2306c93da79d5f261fd3a6a3af36026f
parent77d8a0f1a4d0b2f59cee63088f7987cb38e66538
Encrypted dnode blocks should be prefetched raw

Encrypted dnode blocks are always initially read as raw data and
converted to decrypted data when an encrypted bonus buffer is
needed. This allows the DMU to be used for things like fetching
the DMU master node without requiring keys to be loaded. However,
dbuf_issue_final_prefetch() does not currently read the data as
raw. The end result of this is that prefetched dnode blocks are
read twice from disk: once decrypted and then again as raw data.
This patch corrects the issue by adding the flag when appropriate.

Reviewed by: Matt Ahrens <matt@delphix.com>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Tom Caputi <tcaputi@datto.com>
Closes #7362
module/zfs/dbuf.c