block: add wrappers for logical block provisioning information
authorPeter Lieven <pl@kamp.de>
Thu, 24 Oct 2013 10:06:54 +0000 (12:06 +0200)
committerKevin Wolf <kwolf@redhat.com>
Thu, 28 Nov 2013 09:30:51 +0000 (10:30 +0100)
commit4ce786914b745a144a9eda1ea33f3ff98328c527
tree2c20f0622ce18189318f265ab2224f7732b692fa
parente1a5c4bed44bc23f69f53883c657e31e150cab30
block: add wrappers for logical block provisioning information

This adds 2 wrappers to read the unallocated_blocks_are_zero and
can_write_zeroes_with_unmap info from the BDI. The wrappers are
required to check for the existence of a backing_hd and
if the devices are opened with the correct flags.

Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Peter Lieven <pl@kamp.de>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
block.c
include/block/block.h