diff options
author | Sami Tolvanen <samitolvanen@google.com> | 2015-03-18 11:52:14 -0400 |
---|---|---|
committer | Mike Snitzer <snitzer@redhat.com> | 2015-04-15 12:10:22 -0400 |
commit | 65ff5b7ddf0541f2b6e5cc59c47bfbf6cbcd91b8 (patch) | |
tree | 2a5391011a315f42e409a33d8238544451484c14 /Documentation/device-mapper | |
parent | 0e0e32c16cfd2eeaf4fd4f16aa6cccd1333ce1e0 (diff) |
dm verity: add error handling modes for corrupted blocks
Add device specific modes to dm-verity to specify how corrupted
blocks should be handled. The following modes are defined:
- DM_VERITY_MODE_EIO is the default behavior, where reading a
corrupted block results in -EIO.
- DM_VERITY_MODE_LOGGING only logs corrupted blocks, but does
not block the read.
- DM_VERITY_MODE_RESTART calls kernel_restart when a corrupted
block is discovered.
In addition, each mode sends a uevent to notify userspace of
corruption and to allow further recovery actions.
The driver defaults to previous behavior (DM_VERITY_MODE_EIO)
and other modes can be enabled with an additional parameter to
the verity table.
Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Diffstat (limited to 'Documentation/device-mapper')
-rw-r--r-- | Documentation/device-mapper/verity.txt | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/Documentation/device-mapper/verity.txt b/Documentation/device-mapper/verity.txt index 9884681535ee..64ccc5a079a5 100644 --- a/Documentation/device-mapper/verity.txt +++ b/Documentation/device-mapper/verity.txt | |||
@@ -11,6 +11,7 @@ Construction Parameters | |||
11 | <data_block_size> <hash_block_size> | 11 | <data_block_size> <hash_block_size> |
12 | <num_data_blocks> <hash_start_block> | 12 | <num_data_blocks> <hash_start_block> |
13 | <algorithm> <digest> <salt> | 13 | <algorithm> <digest> <salt> |
14 | [<#opt_params> <opt_params>] | ||
14 | 15 | ||
15 | <version> | 16 | <version> |
16 | This is the type of the on-disk hash format. | 17 | This is the type of the on-disk hash format. |
@@ -62,6 +63,22 @@ Construction Parameters | |||
62 | <salt> | 63 | <salt> |
63 | The hexadecimal encoding of the salt value. | 64 | The hexadecimal encoding of the salt value. |
64 | 65 | ||
66 | <#opt_params> | ||
67 | Number of optional parameters. If there are no optional parameters, | ||
68 | the optional paramaters section can be skipped or #opt_params can be zero. | ||
69 | Otherwise #opt_params is the number of following arguments. | ||
70 | |||
71 | Example of optional parameters section: | ||
72 | 1 ignore_corruption | ||
73 | |||
74 | ignore_corruption | ||
75 | Log corrupted blocks, but allow read operations to proceed normally. | ||
76 | |||
77 | restart_on_corruption | ||
78 | Restart the system when a corrupted block is discovered. This option is | ||
79 | not compatible with ignore_corruption and requires user space support to | ||
80 | avoid restart loops. | ||
81 | |||
65 | Theory of operation | 82 | Theory of operation |
66 | =================== | 83 | =================== |
67 | 84 | ||