Skip to content

Commit 64ad614

Browse files
Andi KleenKuppuswamy Sathyanarayanan
authored andcommitted
tdx: Document tdx failure_inject sysfs parameters
Add documentation for the sysfs parameters for the TDX tdcall failure/random failure injection Signed-off-by: Andi Kleen <[email protected]>
1 parent bdf370d commit 64ad614

File tree

1 file changed

+25
-0
lines changed

1 file changed

+25
-0
lines changed

Documentation/fault-injection/fault-injection.rst

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,10 @@ Available fault injection capabilities
5252
status code is NVME_SC_INVALID_OPCODE with no retry. The status code and
5353
retry flag can be set via the debugfs.
5454

55+
- fail_tdx
56+
57+
inject errors and flipped bits into Intel TDX TDCALL responses.
58+
5559

5660
Configure fault-injection capabilities behavior
5761
-----------------------------------------------
@@ -195,6 +199,25 @@ configuration of fault-injection capabilities.
195199
use a negative errno, you better use 'printf' instead of 'echo', e.g.:
196200
$ printf %#x -12 > retval
197201

202+
- /sys/kernel/debug/fail_tdx/tdcall
203+
204+
enable flipping bits in TDX TDCALL responses
205+
206+
- /sys/kernel/debug/fail_tdx/tderrors
207+
208+
enable injecting errors in TDX TDCALL responses
209+
210+
- /sys/kernel/debug/fail_tdx/seed
211+
212+
set seed for random generator used for flipping bits in TDX TDCALL
213+
responses. Note that each CPU has its own independent random generator.
214+
215+
- /sys/kernel/debug/fail_tdx/num_change_bits
216+
217+
number of bits to change with tdcall=1 in TDX TDCALL responses.
218+
when set to 64 the whole value is replaced with a randon number.
219+
otherwise the number of bits specified are randomly flipped.
220+
198221
Boot option
199222
^^^^^^^^^^^
200223

@@ -208,6 +231,8 @@ use the boot option::
208231
fail_futex=
209232
mmc_core.fail_request=<interval>,<probability>,<space>,<times>
210233

234+
fail_tdx= [seed:N,][tdcall:1,][tderrors:1,][numbits:XX],<interval>,<probability>,<space>,<times>
235+
211236
proc entries
212237
^^^^^^^^^^^^
213238

0 commit comments

Comments
 (0)