File open with O_DIRECT results in direct read, even if we do that synchronous from kernel.
iov_iter_get_pages() Signed-off-by: Kirill Tkhai <[email protected]> --- drivers/md/dm-ploop-bat.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/md/dm-ploop-bat.c b/drivers/md/dm-ploop-bat.c index f55956aab5a7..90ddba88494f 100644 --- a/drivers/md/dm-ploop-bat.c +++ b/drivers/md/dm-ploop-bat.c @@ -369,6 +369,7 @@ int ploop_read_delta_metadata(struct ploop *ploop, struct file *file, int ret; size = (PLOOP_MAP_OFFSET + ploop->nr_bat_entries) * sizeof(map_index_t); + size = ALIGN(size, PAGE_SIZE); /* file may be open as direct */ *d_hdr = vzalloc(size); if (!*d_hdr) { ret = -ENOMEM; _______________________________________________ Devel mailing list [email protected] https://lists.openvz.org/mailman/listinfo/devel
