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 */ diff --git a/configure b/configure index f839c2a557..f498a37f9a 100755 --- a/configure +++ b/configure @@ -433,7 +433,7 @@ vdi="yes" vvfat="yes" qed="yes" parallels="yes" -sheepdog="yes" +sheepdog="no" libxml2="" debug_mutex="no" libpmem="" @@ -1830,7 +1830,7 @@ disabled with --disable-FEATURE, default is enabled if available: vvfat vvfat image format support qed qed image format support parallels parallels image format support - sheepdog sheepdog block driver support + sheepdog sheepdog block driver support (deprecated) crypto-afalg Linux AF_ALG crypto backend driver capstone capstone disassembler support debug-mutex mutex debugging support @@ -6729,6 +6729,7 @@ if test "$parallels" = "yes" ; then echo "CONFIG_PARALLELS=y" >> $config_host_mak fi if test "$sheepdog" = "yes" ; then + add_to deprecated_features "sheepdog" echo "CONFIG_SHEEPDOG=y" >> $config_host_mak fi if test "$pty_h" = "yes" ; then diff --git a/docs/system/deprecated.rst b/docs/system/deprecated.rst index 09ec8b1ae8..2ac3bfd5e9 100644 --- a/docs/system/deprecated.rst +++ b/docs/system/deprecated.rst @@ -390,6 +390,15 @@ The above, converted to the current supported format:: json:{"file.driver":"rbd", "file.pool":"rbd", "file.image":"name"} +``sheepdog`` driver (since 5.2.0) +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +The ``sheepdog`` block device driver is deprecated. The corresponding upstream +server project is no longer actively maintained. Users are recommended to switch +to an alternative distributed block device driver such as RBD. The +``qemu-img convert`` command can be used to liberate existing data by moving +it out of sheepdog volumes into an alternative storage backend. + linux-user mode CPUs --------------------