From ba93f46cb49dfc21db436ccee98349eef25fbf9a Mon Sep 17 00:00:00 2001 From: Niels de Vos Date: Mon, 8 Jun 2020 10:21:30 +0200 Subject: [PATCH] rbd: add RBD_IMAGE_OPTION_FLATTEN for Mimic Signed-off-by: Niels de Vos --- rbd/options.go | 3 --- rbd/options_mimic.go | 12 ++++++++++++ 2 files changed, 12 insertions(+), 3 deletions(-) create mode 100644 rbd/options_mimic.go diff --git a/rbd/options.go b/rbd/options.go index 404968a..86620b9 100644 --- a/rbd/options.go +++ b/rbd/options.go @@ -69,9 +69,6 @@ const ( RbdImageOptionFeaturesClear = ImageOptionFeaturesClear // RbdImageOptionDataPool deprecated alias for ImageOptionDataPool RbdImageOptionDataPool = ImageOptionDataPool - - // introduced with Ceph Mimic - //RbdImageOptionFlatten = C.RBD_IMAGE_OPTION_FLATTEN ) // ImageOptions represents a group of configurable image options. diff --git a/rbd/options_mimic.go b/rbd/options_mimic.go new file mode 100644 index 0000000..5ea1c5b --- /dev/null +++ b/rbd/options_mimic.go @@ -0,0 +1,12 @@ +// +build !luminous + +package rbd + +// #include +import "C" + +const ( + // ImageOptionFlatten is the representation of RBD_IMAGE_OPTION_FLATTEN + // from librbd + ImageOptionFlatten = C.RBD_IMAGE_OPTION_FLATTEN +)