X-Git-Url: https://git.kernel.dk/?p=fio.git;a=blobdiff_plain;f=io_u.c;h=4d3116b7fd4fc0901f4419e8690270c2c18a2d43;hp=afc90de001f720d266d0ad612cb8c2d1873958f9;hb=1fbbf72e16c27a6fda636db3891a41cd37dc6666;hpb=fdba6ac393728b3f743013a6517a987fda79bd1a diff --git a/io_u.c b/io_u.c index afc90de0..4d3116b7 100644 --- a/io_u.c +++ b/io_u.c @@ -8,6 +8,7 @@ #include "fio.h" #include "hash.h" #include "verify.h" +#include "lib/rand.h" struct io_completion_data { int nr; /* input */ @@ -1217,7 +1218,7 @@ void io_u_fill_buffer(struct thread_data *td, struct io_u *io_u, if (!td->o.zero_buffers) { while ((void *) ptr - io_u->buf < max_bs) { - *ptr = rand() * GOLDEN_RATIO_PRIME; + *ptr = __rand(&__fio_rand_state); ptr++; } } else