summaryrefslogtreecommitdiffstats
path: root/include/sys/zio.h
diff options
context:
space:
mode:
authorTom Caputi <[email protected]>2018-05-02 18:36:20 -0400
committerBrian Behlendorf <[email protected]>2018-05-02 15:36:20 -0700
commitbe9a5c355c819ac0f2aca1f8c30dc75164e10322 (patch)
treede57c7d931764c3abfc94422c14311b12f83c5e3 /include/sys/zio.h
parent9464b9591ea5cd61a4d6ef8e29c4597b48d16a77 (diff)
Add support for decryption faults in zinject
This patch adds the ability for zinject to trigger decryption and authentication faults in the ZIO and ARC layers. This functionality is exposed via the new "decrypt" error type, which may be provided for "data" object types. This patch also refactors some of the core encryption / decryption functions so that they have consistent prototypes, handle errors consistently, and do not have unused arguments. Reviewed-by: Brian Behlendorf <[email protected]> Signed-off-by: Tom Caputi <[email protected]> Closes #7474
Diffstat (limited to 'include/sys/zio.h')
-rw-r--r--include/sys/zio.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/sys/zio.h b/include/sys/zio.h
index dc6841d83..25c12fbcc 100644
--- a/include/sys/zio.h
+++ b/include/sys/zio.h
@@ -640,6 +640,8 @@ extern int zio_inject_list_next(int *id, char *name, size_t buflen,
struct zinject_record *record);
extern int zio_clear_fault(int id);
extern void zio_handle_panic_injection(spa_t *spa, char *tag, uint64_t type);
+extern int zio_handle_decrypt_injection(spa_t *spa, const zbookmark_phys_t *zb,
+ uint64_t type, int error);
extern int zio_handle_fault_injection(zio_t *zio, int error);
extern int zio_handle_device_injection(vdev_t *vd, zio_t *zio, int error);
extern int zio_handle_device_injections(vdev_t *vd, zio_t *zio, int err1,