Commit 3ec39abd authored by Akinobu Mita's avatar Akinobu Mita Committed by Linus Torvalds

raid6test: use prandom_bytes()

Use prandom_bytes() to generate random bytes for test data.
Signed-off-by: default avatarAkinobu Mita <akinobu.mita@gmail.com>
Cc: Dan Williams <djbw@fb.com>
Cc: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 713e00a3
......@@ -46,15 +46,10 @@ static void callback(void *param)
static void makedata(int disks)
{
int i, j;
int i;
for (i = 0; i < disks; i++) {
for (j = 0; j < PAGE_SIZE/sizeof(u32); j += sizeof(u32)) {
u32 *p = page_address(data[i]) + j;
*p = random32();
}
prandom_bytes(page_address(data[i]), PAGE_SIZE);
dataptrs[i] = data[i];
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment