aboutsummaryrefslogtreecommitdiff
path: root/block
diff options
context:
space:
mode:
Diffstat (limited to 'block')
-rw-r--r--block/sheepdog.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/block/sheepdog.c b/block/sheepdog.c
index 25111d5a70..a45c73826d 100644
--- a/block/sheepdog.c
+++ b/block/sheepdog.c
@@ -242,6 +242,16 @@ typedef struct SheepdogInode {
*/
#define FNV1A_64_INIT ((uint64_t)0xcbf29ce484222325ULL)
+static void deprecation_warning(void)
+{
+ static bool warned;
+
+ if (!warned) {
+ warn_report("the sheepdog block driver is deprecated");
+ warned = true;
+ }
+}
+
/*
* 64 bit Fowler/Noll/Vo FNV-1a hash code
*/
@@ -1548,6 +1558,8 @@ static int sd_open(BlockDriverState *bs, QDict *options, int flags,
char *buf = NULL;
QemuOpts *opts;
+ deprecation_warning();
+
s->bs = bs;
s->aio_context = bdrv_get_aio_context(bs);
@@ -2007,6 +2019,8 @@ static int sd_co_create(BlockdevCreateOptions *options, Error **errp)
assert(options->driver == BLOCKDEV_DRIVER_SHEEPDOG);
+ deprecation_warning();
+
s = g_new0(BDRVSheepdogState, 1);
/* Steal SocketAddress from QAPI, set NULL to prevent double free */