]> git.proxmox.com Git - mirror_qemu.git/commit
block/nfs: cache allocated filesize for read-only files
authorPeter Lieven <pl@kamp.de>
Thu, 27 Aug 2015 10:30:41 +0000 (12:30 +0200)
committerJeff Cody <jcody@redhat.com>
Fri, 25 Sep 2015 12:37:07 +0000 (08:37 -0400)
commit18a8056e0bc744e5dd2bb5cb998423b607d99f19
tree1be539c64fd3ef14f0c36de0dc04847fef092244
parent055c6f912c8d3cd9a901972ae432c47e5872f71a
block/nfs: cache allocated filesize for read-only files

If the file is readonly its not expected to grow so
save the blocking call to nfs_fstat_async and use
the value saved at connection time. Also important
the monitor (and thus the main loop) will not hang
if block device info is queried and the NFS share
is unresponsive.

Signed-off-by: Peter Lieven <pl@kamp.de>
Reviewed-by: Jeff Cody <jcody@redhat.com>
Reviewed-by: Max Reitz <mreitz@redhat.com>
Message-id: 1440671441-7978-1-git-send-email-pl@kamp.de
Signed-off-by: Jeff Cody <jcody@redhat.com>
block/nfs.c