summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
d537c08)
No need allocating a larger map than we need.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
return 0;
for_each_file(td, f, i) {
return 0;
for_each_file(td, f, i) {
- blocks = (f->real_file_size + td->o.rw_min_bs - 1) /
+ uint64_t file_size = min(f->real_file_size, f->io_size);
+
+ blocks = (file_size + td->o.rw_min_bs - 1) /
(unsigned long long) td->o.rw_min_bs;
if (td->o.random_generator == FIO_RAND_GEN_LFSR) {
unsigned long seed;
(unsigned long long) td->o.rw_min_bs;
if (td->o.random_generator == FIO_RAND_GEN_LFSR) {
unsigned long seed;