Artificial intelligent assistant

What pattern(s) does non-destructive badblocks -n write? `man badblocks` says: > > -n Use non-destructive read-write mode. By default only a non- > destructive read-only test is done. This option must not be > combined with the -w option, as they are mutually exclusive. > This answer says: > The non-destructive read-write test works by overwriting data, then reading to verify, and then writing the original data back afterwards. What pattern(s) are used by `-n` if none are explicitly specified by `-t`?

The default pattern with `-n` is a random pattern:


const unsigned int patterns[] = { ~0 };


(see `pattern_fill` for the equivalence to “random”).

In destructive mode, four patterns are used:


const unsigned int patterns[] = {0xaa, 0x55, 0xff, 0x00};

xcX3v84RxoQ-4GxG32940ukFUIEgYdPy 824bfeb258a6bd990c298d0073f1b6bd