Should OR in BDRV_WANT_ALLOCATED instead.
Actually there is not problem within the code right now as the value is
used as enum rather than flags but that is for now. Let us stay on the
safe side.
Fixes: c33159dec790 ("block: Expand block status mode from bool to flags")
Signed-off-by: Denis V. Lunev <[email protected]>
CC: Eric Blake <[email protected]>
CC: Stefan Hajnoczi <[email protected]>
---
NOTE: technically we can just remove extra BDRV_WANT_OFFSET_VALID but for me
proposed change seems more logically correct.
include/block/block-common.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/block/block-common.h b/include/block/block-common.h
index 895ea17541..3932ff8615 100644
--- a/include/block/block-common.h
+++ b/include/block/block-common.h
@@ -351,7 +351,7 @@ typedef enum {
#define BDRV_WANT_OFFSET_VALID BDRV_BLOCK_OFFSET_VALID
#define BDRV_WANT_ALLOCATED BDRV_BLOCK_ALLOCATED
#define BDRV_WANT_PRECISE (BDRV_WANT_ZERO | BDRV_WANT_OFFSET_VALID | \
- BDRV_WANT_OFFSET_VALID)
+ BDRV_WANT_ALLOCATED)
typedef QTAILQ_HEAD(BlockReopenQueue, BlockReopenQueueEntry) BlockReopenQueue;
--
2.53.0