Lines Matching refs:file_end

71     int64_t file_end;  member
152 s->file_end = s->zero_start = s->data_end = -EINVAL; in preallocate_open()
182 if (s->file_end < 0) { in preallocate_truncate_to_real_size()
183 s->file_end = bdrv_getlength(bs->file->bs); in preallocate_truncate_to_real_size()
184 if (s->file_end < 0) { in preallocate_truncate_to_real_size()
185 error_setg_errno(errp, -s->file_end, "Failed to get file length"); in preallocate_truncate_to_real_size()
186 return s->file_end; in preallocate_truncate_to_real_size()
190 if (s->data_end < s->file_end) { in preallocate_truncate_to_real_size()
195 s->file_end = ret; in preallocate_truncate_to_real_size()
198 s->file_end = s->data_end; in preallocate_truncate_to_real_size()
309 assert(s->file_end < 0); in has_prealloc_perms()
345 if (s->file_end < 0) { in handle_write()
346 s->file_end = s->data_end; in handle_write()
361 if (s->file_end < 0) { in handle_write()
362 s->file_end = bdrv_co_getlength(bs->file->bs); in handle_write()
363 if (s->file_end < 0) { in handle_write()
370 if (end <= s->file_end) { in handle_write()
378 want_merge_zero ? MIN(offset, s->file_end) : s->file_end, in handle_write()
390 s->file_end = ret; in handle_write()
394 s->file_end = prealloc_end; in handle_write()
432 if (s->file_end < 0) { in preallocate_co_truncate()
433 s->file_end = bdrv_co_getlength(bs->file->bs); in preallocate_co_truncate()
434 if (s->file_end < 0) { in preallocate_co_truncate()
436 return s->file_end; in preallocate_co_truncate()
447 if (offset <= s->file_end) { in preallocate_co_truncate()
461 if (s->file_end > s->data_end) { in preallocate_co_truncate()
465 s->file_end = ret; in preallocate_co_truncate()
470 s->file_end = s->data_end; in preallocate_co_truncate()
479 s->file_end = s->zero_start = s->data_end = ret; in preallocate_co_truncate()
484 s->file_end = s->zero_start = s->data_end = offset; in preallocate_co_truncate()
507 s->file_end = s->zero_start = s->data_end = ret; in preallocate_co_getlength()
538 s->data_end = s->file_end = s->zero_start = -EINVAL; in preallocate_drop_resize()
565 s->data_end = s->file_end = s->zero_start = in preallocate_set_perm()