summary refs log tree commit diff stats
path: root/hw/display/framebuffer.c
diff options
context:
space:
mode:
authorStefan Hajnoczi <stefanha@redhat.com>2019-03-07 16:49:41 +0000
committerStefan Hajnoczi <stefanha@redhat.com>2019-03-13 10:54:55 +0000
commitf357fcd890a8d6ced6d261338b859a41414561e9 (patch)
treea14417ab0d8d597603bead7821548c1ef05cf586 /hw/display/framebuffer.c
parent3f3bbfc7cef4490c5ed5550766a81e7d18f08db1 (diff)
downloadfocaccia-qemu-f357fcd890a8d6ced6d261338b859a41414561e9.tar.gz
focaccia-qemu-f357fcd890a8d6ced6d261338b859a41414561e9.zip
file-posix: add drop-cache=on|off option
Commit dd577a26ff03b6829721b1ffbbf9e7c411b72378 ("block/file-posix:
implement bdrv_co_invalidate_cache() on Linux") introduced page cache
invalidation so that cache.direct=off live migration is safe on Linux.

The invalidation takes a significant amount of time when the file is
large and present in the page cache.  Normally this is not the case for
cross-host live migration but it can happen when migrating between QEMU
processes on the same host.

On same-host migration we don't need to invalidate pages for correctness
anyway, so an option to skip page cache invalidation is useful.  I
investigated optimizing invalidation and detecting same-host migration,
but both are hard to achieve so a user-visible option will suffice.

As a bonus this option means that the cache invalidation feature will
now be detectable by libvirt via QMP schema introspection.

Suggested-by: Neil Skrypuch <neil@tembosocial.com>
Tested-by: Neil Skrypuch <neil@tembosocial.com>
Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Message-id: 20190307164941.3322-1-stefanha@redhat.com
Message-Id: <20190307164941.3322-1-stefanha@redhat.com>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'hw/display/framebuffer.c')
0 files changed, 0 insertions, 0 deletions