@@ -1,3 +1,11 @@
+xfsprogs (5.14.0-release-2.1) unstable; urgency=medium
+
+ * Non-maintainer upload.
+ * Add 0001-Revert-xfs-Fix-fall-through-warnings-for-Clang.patch so that
+ xfslibs-dev doesn't define fallthrough globally anymore (Closes: #1000974).
+
+ -- Thomas Goirand <zigo@debian.org> Sun, 05 Dec 2021 18:47:33 +0100
+
xfsprogs (5.14.0-release-2) unstable; urgency=medium
* Replace the Debian-only #999879 fix by upstream patch
@@ -0,0 +1,343 @@
+From 1d67907760e0b4b53b894c443c70eef474dc7cce Mon Sep 17 00:00:00 2001
+From: Thomas Goirand <zigo@debian.org>
+Date: Sun, 5 Dec 2021 18:43:04 +0100
+Subject: [PATCH] Revert "xfs: Fix fall-through warnings for Clang"
+
+This reverts commit df9c7d8d8f3ed0785ed83e7fd0c7ddc92cbfbe15.
+---
+ include/linux.h | 21 ---------------------
+ libxfs/xfs_ag_resv.c | 4 ++--
+ libxfs/xfs_alloc.c | 2 +-
+ libxfs/xfs_da_btree.c | 2 +-
+ 4 files changed, 4 insertions(+), 25 deletions(-)
+
+Index: xfsprogs-5.14.0-release/include/linux.h
+===================================================================
+--- xfsprogs-5.14.0-release.orig/include/linux.h
++++ xfsprogs-5.14.0-release/include/linux.h
+@@ -359,25 +359,4 @@ fsmap_advance(
+ #include <asm-generic/mman-common.h>
+ #endif /* HAVE_MAP_SYNC */
+
+-/*
+- * Add the pseudo keyword 'fallthrough' so case statement blocks
+- * must end with any of these keywords:
+- * break;
+- * fallthrough;
+- * continue;
+- * goto <label>;
+- * return [expression];
+- *
+- * gcc: https://gcc.gnu.org/onlinedocs/gcc/Statement-Attributes.html#Statement-Attributes
+- */
+-#if defined __has_attribute
+-# if __has_attribute(__fallthrough__)
+-# define fallthrough __attribute__((__fallthrough__))
+-# else
+-# define fallthrough do {} while (0) /* fallthrough */
+-# endif
+-#else
+-# define fallthrough do {} while (0) /* fallthrough */
+-#endif
+-
+ #endif /* __XFS_LINUX_H__ */
+Index: xfsprogs-5.14.0-release/libxfs/xfs_ag_resv.c
+===================================================================
+--- xfsprogs-5.14.0-release.orig/libxfs/xfs_ag_resv.c
++++ xfsprogs-5.14.0-release/libxfs/xfs_ag_resv.c
+@@ -364,7 +364,7 @@ xfs_ag_resv_alloc_extent(
+ break;
+ default:
+ ASSERT(0);
+- fallthrough;
++ /* fall through */
+ case XFS_AG_RESV_NONE:
+ field = args->wasdel ? XFS_TRANS_SB_RES_FDBLOCKS :
+ XFS_TRANS_SB_FDBLOCKS;
+@@ -406,7 +406,7 @@ xfs_ag_resv_free_extent(
+ break;
+ default:
+ ASSERT(0);
+- fallthrough;
++ /* fall through */
+ case XFS_AG_RESV_NONE:
+ xfs_trans_mod_sb(tp, XFS_TRANS_SB_FDBLOCKS, (int64_t)len);
+ return;
+Index: xfsprogs-5.14.0-release/libxfs/xfs_alloc.c
+===================================================================
+--- xfsprogs-5.14.0-release.orig/libxfs/xfs_alloc.c
++++ xfsprogs-5.14.0-release/libxfs/xfs_alloc.c
+@@ -3170,7 +3170,7 @@ xfs_alloc_vextent(
+ }
+ args->agbno = XFS_FSB_TO_AGBNO(mp, args->fsbno);
+ args->type = XFS_ALLOCTYPE_NEAR_BNO;
+- fallthrough;
++ /* FALLTHROUGH */
+ case XFS_ALLOCTYPE_FIRST_AG:
+ /*
+ * Rotate through the allocation groups looking for a winner.
+Index: xfsprogs-5.14.0-release/libxfs/xfs_da_btree.c
+===================================================================
+--- xfsprogs-5.14.0-release.orig/libxfs/xfs_da_btree.c
++++ xfsprogs-5.14.0-release/libxfs/xfs_da_btree.c
+@@ -279,7 +279,7 @@ xfs_da3_node_read_verify(
+ __this_address);
+ break;
+ }
+- fallthrough;
++ /* fall through */
+ case XFS_DA_NODE_MAGIC:
+ fa = xfs_da3_node_verify(bp);
+ if (fa)
+Index: xfsprogs-5.14.0-release/growfs/xfs_growfs.c
+===================================================================
+--- xfsprogs-5.14.0-release.orig/growfs/xfs_growfs.c
++++ xfsprogs-5.14.0-release/growfs/xfs_growfs.c
+@@ -78,7 +78,7 @@ main(int argc, char **argv)
+ switch (c) {
+ case 'D':
+ dsize = strtoll(optarg, NULL, 10);
+- fallthrough;
++ /* fall through */
+ case 'd':
+ dflag = 1;
+ break;
+@@ -91,7 +91,7 @@ main(int argc, char **argv)
+ break;
+ case 'L':
+ lsize = strtoll(optarg, NULL, 10);
+- fallthrough;
++ /* fall through */
+ case 'l':
+ lflag = 1;
+ break;
+@@ -107,7 +107,7 @@ main(int argc, char **argv)
+ break;
+ case 'R':
+ rsize = strtoll(optarg, NULL, 10);
+- fallthrough;
++ /* fall through */
+ case 'r':
+ rflag = 1;
+ break;
+Index: xfsprogs-5.14.0-release/libxfs/xfs_attr.c
+===================================================================
+--- xfsprogs-5.14.0-release.orig/libxfs/xfs_attr.c
++++ xfsprogs-5.14.0-release/libxfs/xfs_attr.c
+@@ -483,7 +483,7 @@ xfs_attr_set_iter(
+ if (error)
+ return error;
+
+- fallthrough;
++ /* fall through */
+ case XFS_DAS_RM_LBLK:
+ /* Set state in case xfs_attr_rmtval_remove returns -EAGAIN */
+ dac->dela_state = XFS_DAS_RM_LBLK;
+@@ -496,7 +496,7 @@ xfs_attr_set_iter(
+ return -EAGAIN;
+ }
+
+- fallthrough;
++ /* fall through */
+ case XFS_DAS_RD_LEAF:
+ /*
+ * This is the last step for leaf format. Read the block with
+@@ -528,7 +528,7 @@ xfs_attr_set_iter(
+ return error;
+ }
+
+- fallthrough;
++ /* fall through */
+ case XFS_DAS_ALLOC_NODE:
+ /*
+ * If there was an out-of-line value, allocate the blocks we
+@@ -590,7 +590,7 @@ xfs_attr_set_iter(
+ if (error)
+ return error;
+
+- fallthrough;
++ /* fall through */
+ case XFS_DAS_RM_NBLK:
+ /* Set state in case xfs_attr_rmtval_remove returns -EAGAIN */
+ dac->dela_state = XFS_DAS_RM_NBLK;
+@@ -603,7 +603,7 @@ xfs_attr_set_iter(
+ return -EAGAIN;
+ }
+
+- fallthrough;
++ /* fall through */
+ case XFS_DAS_CLR_FLAG:
+ /*
+ * The last state for node format. Look up the old attr and
+@@ -1406,7 +1406,7 @@ xfs_attr_remove_iter(
+ state = dac->da_state;
+ }
+
+- fallthrough;
++ /* fall through */
+ case XFS_DAS_RMTBLK:
+ dac->dela_state = XFS_DAS_RMTBLK;
+
+@@ -1441,7 +1441,7 @@ xfs_attr_remove_iter(
+ return -EAGAIN;
+ }
+
+- fallthrough;
++ /* fall through */
+ case XFS_DAS_RM_NAME:
+ /*
+ * If we came here fresh from a transaction roll, reattach all
+@@ -1469,7 +1469,7 @@ xfs_attr_remove_iter(
+ return -EAGAIN;
+ }
+
+- fallthrough;
++ /* fall through */
+ case XFS_DAS_RM_SHRINK:
+ /*
+ * If the result is small enough, push it all into the inode.
+Index: xfsprogs-5.14.0-release/repair/dinode.c
+===================================================================
+--- xfsprogs-5.14.0-release.orig/repair/dinode.c
++++ xfsprogs-5.14.0-release/repair/dinode.c
+@@ -531,7 +531,7 @@ _("Fatal error: inode %" PRIu64 " - blkm
+ do_warn(
+ _("%s fork in ino %" PRIu64 " claims free block %" PRIu64 "\n"),
+ forkname, ino, (uint64_t) b);
+- fallthrough;
++ /* fall through */
+ case XR_E_INUSE1: /* seen by rmap */
+ case XR_E_UNKNOWN:
+ break;
+@@ -543,7 +543,7 @@ _("%s fork in ino %" PRIu64 " claims fre
+ case XR_E_INO1:
+ case XR_E_INUSE_FS1:
+ do_warn(_("rmap claims metadata use!\n"));
+- fallthrough;
++ /* fall through */
+ case XR_E_FS_MAP:
+ case XR_E_INO:
+ case XR_E_INUSE_FS:
+Index: xfsprogs-5.14.0-release/repair/scan.c
+===================================================================
+--- xfsprogs-5.14.0-release.orig/repair/scan.c
++++ xfsprogs-5.14.0-release/repair/scan.c
+@@ -732,7 +732,7 @@ _("%s freespace btree block claimed (sta
+ XR_E_FREE);
+ break;
+ }
+- fallthrough;
++ /* fall through */
+ default:
+ do_warn(
+ _("block (%d,%d-%d) multiply claimed by %s space tree, state - %d\n"),
+@@ -911,7 +911,7 @@ _("in use block (%d,%d-%d) mismatch in %
+ if (xfs_sb_version_hasreflink(&mp->m_sb) &&
+ !XFS_RMAP_NON_INODE_OWNER(owner))
+ break;
+- fallthrough;
++ /* fall through */
+ default:
+ do_warn(
+ _("unknown block (%d,%d-%d) mismatch on %s tree, state - %d,%" PRIx64 "\n"),
+Index: xfsprogs-5.14.0-release/repair/phase4.c
+===================================================================
+--- xfsprogs-5.14.0-release.orig/repair/phase4.c
++++ xfsprogs-5.14.0-release/repair/phase4.c
+@@ -317,7 +317,7 @@ phase4(xfs_mount_t *mp)
+ do_warn(
+ _("unknown block state, ag %d, blocks %u-%u\n"),
+ i, j, j + blen - 1);
+- fallthrough;
++ /* fall through */
+ case XR_E_UNKNOWN:
+ case XR_E_FREE:
+ case XR_E_INUSE:
+@@ -349,7 +349,7 @@ phase4(xfs_mount_t *mp)
+ do_warn(
+ _("unknown rt extent state, extent %" PRIu64 "\n"),
+ bno);
+- fallthrough;
++ /* fall through */
+ case XR_E_UNKNOWN:
+ case XR_E_FREE1:
+ case XR_E_FREE:
+Index: xfsprogs-5.14.0-release/scrub/repair.c
+===================================================================
+--- xfsprogs-5.14.0-release.orig/scrub/repair.c
++++ xfsprogs-5.14.0-release/scrub/repair.c
+@@ -133,7 +133,7 @@ action_list_find_mustfix(
+ alist->nr--;
+ list_move_tail(&aitem->list, &immediate_alist->list);
+ immediate_alist->nr++;
+- fallthrough;
++ /* fall through */
+ case XFS_SCRUB_TYPE_BNOBT:
+ case XFS_SCRUB_TYPE_CNTBT:
+ case XFS_SCRUB_TYPE_REFCNTBT:
+Index: xfsprogs-5.14.0-release/scrub/inodes.c
+===================================================================
+--- xfsprogs-5.14.0-release.orig/scrub/inodes.c
++++ xfsprogs-5.14.0-release/scrub/inodes.c
+@@ -204,7 +204,7 @@ _("Changed too many times during scan; g
+ }
+ case ECANCELED:
+ error = 0;
+- fallthrough;
++ /* fall through */
+ default:
+ goto err;
+ }
+Index: xfsprogs-5.14.0-release/scrub/scrub.c
+===================================================================
+--- xfsprogs-5.14.0-release.orig/scrub/scrub.c
++++ xfsprogs-5.14.0-release/scrub/scrub.c
+@@ -164,7 +164,7 @@ _("Filesystem is shut down, aborting."))
+ * and the other two should be reported via sm_flags.
+ */
+ str_liberror(ctx, error, _("Kernel bug"));
+- fallthrough;
++ /* fall through */
+ default:
+ /* Operational error. */
+ str_errno(ctx, descr_render(&dsc));
+@@ -316,7 +316,7 @@ scrub_meta_type(
+ ret = scrub_save_repair(ctx, alist, &meta);
+ if (ret)
+ return ret;
+- fallthrough;
++ /* fall through */
+ case CHECK_DONE:
+ return 0;
+ default:
+@@ -741,7 +741,7 @@ _("Filesystem is shut down, aborting."))
+ if (is_unoptimized(&oldm) ||
+ debug_tweak_on("XFS_SCRUB_FORCE_REPAIR"))
+ return CHECK_DONE;
+- fallthrough;
++ /* fall through */
+ case EINVAL:
+ /* Kernel doesn't know how to repair this? */
+ str_corrupt(ctx, descr_render(&dsc),
+@@ -761,7 +761,7 @@ _("Read-only filesystem; cannot make cha
+ /* Don't care if preen fails due to low resources. */
+ if (is_unoptimized(&oldm) && !needs_repair(&oldm))
+ return CHECK_DONE;
+- fallthrough;
++ /* fall through */
+ default:
+ /*
+ * Operational error. If the caller doesn't want us
+Index: xfsprogs-5.14.0-release/db/type.c
+===================================================================
+--- xfsprogs-5.14.0-release.orig/db/type.c
++++ xfsprogs-5.14.0-release/db/type.c
+@@ -307,7 +307,7 @@ handle_text(
+ {
+ switch (action) {
+ case DB_FUZZ:
+- fallthrough;
++ /* fall through */
+ case DB_WRITE:
+ dbprintf(_("text writing/fuzzing not supported.\n"));
+ break;
@@ -1,2 +1,3 @@
libfrog-fix-crc32c-self-test-code-on-cross-builds.patch
libxfs-fix-atomic64_t-poorly-for-32-bit-architectures.patch
+0001-Revert-xfs-Fix-fall-through-warnings-for-Clang.patch