Patchwork [1/4] block: add discard_zeroes and max_unmap to BlockDriverInfo

login
register
mail settings
Submitter Peter Lieven
Date July 15, 2013, 10:49 a.m.
Message ID <1373885375-13601-2-git-send-email-pl@kamp.de>
Download mbox | patch
Permalink /patch/258992/
State New
Headers show

Comments

Peter Lieven - July 15, 2013, 10:49 a.m.
Signed-off-by: Peter Lieven <pl@kamp.de>
---
 include/block/block.h |    5 +++++
 1 file changed, 5 insertions(+)

Patch

diff --git a/include/block/block.h b/include/block/block.h
index 297ec1e..aceb780 100644
--- a/include/block/block.h
+++ b/include/block/block.h
@@ -18,6 +18,11 @@  typedef struct BlockDriverInfo {
     /* offset at which the VM state can be saved (0 if not possible) */
     int64_t vm_state_offset;
     bool is_dirty;
+    /* do discarded blocks read back as zeroes? */
+    bool discard_zeroes;
+    /* maximum number of sectors that can be discarded at once */
+    int max_unmap;
+
 } BlockDriverInfo;
 
 typedef struct BlockFragInfo {