cmd: mem: Add a command to fill the memory with random data
PATCH v3 1/1 cmd: mem: Add a command to fill the memory with random data
This command fills the memory with data produced by rand().
Signed-off-by Jean-Jacques Hiblot <[email protected]>
---
changes in v3:
- Add a new CONFIG option that depends on CMD_MEM
changes in v2:
- Do not include the command if CONFIG_LIB_RAND is not set
- make do_random() static
cmd/Kconfig | 7 +++++++ cmd/mem.c | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 59 insertions(+)
cmd/Kconfig +7 -0
@@ -550,6 +550,13 @@ config CMD_MEMORY base - print or set address offset loop - initialize loop on address range +config CMD_RANDOM + bool "random" + default y + depends on CMD_MEMORY && (LIB_RAND || LIB_HW_RAND) + help + random - fill memory with random data + config CMD_MEMTEST bool "memtest" help
cmd/mem.c +52 -0
61 lines not on this page · raw message
Signature · 1 line
2.17.1
PATCH v3 1/1 cmd: mem: Add a command to fill the memory with random data
Quoted 3 lines · Jean-Jacques Hiblot
This command fills the memory with data produced by
rand().Signed-off-by Jean-Jacques Hiblot <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: not available URL: <http://lists.denx.de/pipermail/u-boot/attachments/20190718/ea30835e/attachment.sig>