All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: [PATCH] btrfs: make more ASSERTs verbose, part 3
@ 2026-04-07  3:59 kernel test robot
  0 siblings, 0 replies; 4+ messages in thread
From: kernel test robot @ 2026-04-07  3:59 UTC (permalink / raw)
  To: oe-kbuild; +Cc: lkp

:::::: 
:::::: Manual check reason: "likely FALSE maybe-used-uninitialized warning on old compiler"
:::::: 

BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
In-Reply-To: <20260331223659.2098718-1-dsterba@suse.com>
References: <20260331223659.2098718-1-dsterba@suse.com>
TO: David Sterba <dsterba@suse.com>
TO: linux-btrfs@vger.kernel.org
CC: David Sterba <dsterba@suse.com>

Hi David,

kernel test robot noticed the following build warnings:

[auto build test WARNING on kdave/for-next]
[also build test WARNING on next-20260403]
[cannot apply to linus/master v7.0-rc6]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/David-Sterba/btrfs-make-more-ASSERTs-verbose-part-3/20260402-233149
base:   https://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux.git for-next
patch link:    https://lore.kernel.org/r/20260331223659.2098718-1-dsterba%40suse.com
patch subject: [PATCH] btrfs: make more ASSERTs verbose, part 3
:::::: branch date: 3 days ago
:::::: commit date: 3 days ago
config: arm-randconfig-001-20260405 (https://download.01.org/0day-ci/archive/20260405/202604051438.4BSUbQVi-lkp@intel.com/config)
compiler: arm-linux-gnueabi-gcc (GCC) 11.5.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260405/202604051438.4BSUbQVi-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/r/202604051438.4BSUbQVi-lkp@intel.com/

Note: it may well be a FALSE warning. FWIW you are at least aware of it now.
http://gcc.gnu.org/wiki/Better_Uninitialized_Warnings

All warnings (new ones prefixed by >>):

   In file included from include/asm-generic/bug.h:31,
                    from arch/arm/include/asm/bug.h:60,
                    from include/linux/bug.h:5,
                    from include/linux/instrumented.h:10,
                    from include/linux/atomic/atomic-instrumented.h:17,
                    from include/linux/atomic.h:82,
                    from include/asm-generic/bitops/lock.h:5,
                    from arch/arm/include/asm/bitops.h:245,
                    from include/linux/bitops.h:67,
                    from include/linux/kernel.h:23,
                    from fs/btrfs/ioctl.c:6:
   fs/btrfs/ioctl.c: In function 'btrfs_ioctl_subvol_sync':
>> include/linux/printk.h:511:44: warning: 'root_flags' may be used uninitialized in this function [-Wmaybe-uninitialized]
     511 | #define printk(fmt, ...) printk_index_wrap(_printk, fmt, ##__VA_ARGS__)
         |                                            ^~~~~~~
   fs/btrfs/ioctl.c:4984:13: note: 'root_flags' was declared here
    4984 |         u64 root_flags;
         |             ^~~~~~~~~~


vim +/root_flags +511 include/linux/printk.h

337015573718b1 Chris Down      2021-06-15  459  
337015573718b1 Chris Down      2021-06-15  460  /*
337015573718b1 Chris Down      2021-06-15  461   * Some subsystems have their own custom printk that applies a va_format to a
337015573718b1 Chris Down      2021-06-15  462   * generic format, for example, to include a device number or other metadata
337015573718b1 Chris Down      2021-06-15  463   * alongside the format supplied by the caller.
337015573718b1 Chris Down      2021-06-15  464   *
337015573718b1 Chris Down      2021-06-15  465   * In order to store these in the way they would be emitted by the printk
337015573718b1 Chris Down      2021-06-15  466   * infrastructure, the subsystem provides us with the start, fixed string, and
337015573718b1 Chris Down      2021-06-15  467   * any subsequent text in the format string.
337015573718b1 Chris Down      2021-06-15  468   *
337015573718b1 Chris Down      2021-06-15  469   * We take a variable argument list as pr_fmt/dev_fmt/etc are sometimes passed
337015573718b1 Chris Down      2021-06-15  470   * as multiple arguments (eg: `"%s: ", "blah"`), and we must only take the
337015573718b1 Chris Down      2021-06-15  471   * first one.
337015573718b1 Chris Down      2021-06-15  472   *
337015573718b1 Chris Down      2021-06-15  473   * subsys_fmt_prefix must be known at compile time, or compilation will fail
337015573718b1 Chris Down      2021-06-15  474   * (since this is a mistake). If fmt or level is not known at compile time, no
337015573718b1 Chris Down      2021-06-15  475   * index entry will be made (since this can legitimately happen).
337015573718b1 Chris Down      2021-06-15  476   */
337015573718b1 Chris Down      2021-06-15  477  #define printk_index_subsys_emit(subsys_fmt_prefix, level, fmt, ...) \
337015573718b1 Chris Down      2021-06-15  478  	__printk_index_emit(fmt, level, subsys_fmt_prefix)
337015573718b1 Chris Down      2021-06-15  479  
337015573718b1 Chris Down      2021-06-15  480  #define printk_index_wrap(_p_func, _fmt, ...)				\
337015573718b1 Chris Down      2021-06-15  481  	({								\
337015573718b1 Chris Down      2021-06-15  482  		__printk_index_emit(_fmt, NULL, NULL);			\
337015573718b1 Chris Down      2021-06-15  483  		_p_func(_fmt, ##__VA_ARGS__);				\
337015573718b1 Chris Down      2021-06-15  484  	})
337015573718b1 Chris Down      2021-06-15  485  
337015573718b1 Chris Down      2021-06-15  486  
7d9e2661f26858 Jonathan Corbet 2021-07-25  487  /**
7d9e2661f26858 Jonathan Corbet 2021-07-25  488   * printk - print a kernel message
7d9e2661f26858 Jonathan Corbet 2021-07-25  489   * @fmt: format string
7d9e2661f26858 Jonathan Corbet 2021-07-25  490   *
7d9e2661f26858 Jonathan Corbet 2021-07-25  491   * This is printk(). It can be called from any context. We want it to work.
7d9e2661f26858 Jonathan Corbet 2021-07-25  492   *
7d9e2661f26858 Jonathan Corbet 2021-07-25  493   * If printk indexing is enabled, _printk() is called from printk_index_wrap.
7d9e2661f26858 Jonathan Corbet 2021-07-25  494   * Otherwise, printk is simply #defined to _printk.
7d9e2661f26858 Jonathan Corbet 2021-07-25  495   *
7d9e2661f26858 Jonathan Corbet 2021-07-25  496   * We try to grab the console_lock. If we succeed, it's easy - we log the
7d9e2661f26858 Jonathan Corbet 2021-07-25  497   * output and call the console drivers.  If we fail to get the semaphore, we
7d9e2661f26858 Jonathan Corbet 2021-07-25  498   * place the output into the log buffer and return. The current holder of
7d9e2661f26858 Jonathan Corbet 2021-07-25  499   * the console_sem will notice the new output in console_unlock(); and will
7d9e2661f26858 Jonathan Corbet 2021-07-25  500   * send it to the consoles before releasing the lock.
7d9e2661f26858 Jonathan Corbet 2021-07-25  501   *
7d9e2661f26858 Jonathan Corbet 2021-07-25  502   * One effect of this deferred printing is that code which calls printk() and
7d9e2661f26858 Jonathan Corbet 2021-07-25  503   * then changes console_loglevel may break. This is because console_loglevel
7d9e2661f26858 Jonathan Corbet 2021-07-25  504   * is inspected when the actual printing occurs.
7d9e2661f26858 Jonathan Corbet 2021-07-25  505   *
7d9e2661f26858 Jonathan Corbet 2021-07-25  506   * See also:
7d9e2661f26858 Jonathan Corbet 2021-07-25  507   * printf(3)
7d9e2661f26858 Jonathan Corbet 2021-07-25  508   *
7d9e2661f26858 Jonathan Corbet 2021-07-25  509   * See the vsnprintf() documentation for format string extensions over C99.
7d9e2661f26858 Jonathan Corbet 2021-07-25  510   */
337015573718b1 Chris Down      2021-06-15 @511  #define printk(fmt, ...) printk_index_wrap(_printk, fmt, ##__VA_ARGS__)
337015573718b1 Chris Down      2021-06-15  512  #define printk_deferred(fmt, ...)					\
337015573718b1 Chris Down      2021-06-15  513  	printk_index_wrap(_printk_deferred, fmt, ##__VA_ARGS__)
337015573718b1 Chris Down      2021-06-15  514  

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

^ permalink raw reply	[flat|nested] 4+ messages in thread
* [PATCH] btrfs: make more ASSERTs verbose, part 3
@ 2026-03-31 22:36 David Sterba
  2026-04-01 14:24 ` Filipe Manana
  0 siblings, 1 reply; 4+ messages in thread
From: David Sterba @ 2026-03-31 22:36 UTC (permalink / raw)
  To: linux-btrfs; +Cc: David Sterba

We have support for optional string to be printed in ASSERT() (added in
19468a623a9109 ("btrfs: enhance ASSERT() to take optional format
string")), it's not yet everywhere it could be so add a few more files.

Try to finish what was left after 1c094e6ccead7a ("btrfs: make a few
more ASSERTs verbose").

Signed-off-by: David Sterba <dsterba@suse.com>
---
 fs/btrfs/backref.c          |  4 ++--
 fs/btrfs/extent-tree.c      | 14 +++++++++-----
 fs/btrfs/extent_map.c       |  6 +++---
 fs/btrfs/fiemap.c           |  2 +-
 fs/btrfs/file-item.c        |  4 +++-
 fs/btrfs/file.c             | 10 +++++++---
 fs/btrfs/ioctl.c            |  3 ++-
 fs/btrfs/ordered-data.c     | 12 +++++++-----
 fs/btrfs/raid-stripe-tree.c |  7 +++++--
 fs/btrfs/reflink.c          |  5 +++--
 10 files changed, 42 insertions(+), 25 deletions(-)

diff --git a/fs/btrfs/backref.c b/fs/btrfs/backref.c
index 273924ca912c2f..2c25e5d86f3e42 100644
--- a/fs/btrfs/backref.c
+++ b/fs/btrfs/backref.c
@@ -2367,7 +2367,7 @@ int tree_backref_for_extent(unsigned long *ptr, struct extent_buffer *eb,
 		info = (struct btrfs_tree_block_info *)(ei + 1);
 		*out_level = btrfs_tree_block_level(eb, info);
 	} else {
-		ASSERT(key->type == BTRFS_METADATA_ITEM_KEY);
+		ASSERT(key->type == BTRFS_METADATA_ITEM_KEY, "key->type=%hhu", key->type);
 		*out_level = (u8)key->offset;
 	}
 
@@ -3199,7 +3199,7 @@ static int handle_direct_tree_backref(struct btrfs_backref_cache *cache,
 	struct btrfs_backref_node *upper;
 	struct rb_node *rb_node;
 
-	ASSERT(ref_key->type == BTRFS_SHARED_BLOCK_REF_KEY);
+	ASSERT(ref_key->type == BTRFS_SHARED_BLOCK_REF_KEY, "ref_key->type=%hhu", ref_key->type);
 
 	/* Only reloc root uses backref pointing to itself */
 	if (ref_key->objectid == ref_key->offset) {
diff --git a/fs/btrfs/extent-tree.c b/fs/btrfs/extent-tree.c
index 391fad41c3b6d9..a097ed8518645e 100644
--- a/fs/btrfs/extent-tree.c
+++ b/fs/btrfs/extent-tree.c
@@ -385,7 +385,7 @@ int btrfs_get_extent_inline_ref_type(const struct extent_buffer *eb,
 					return type;
 			}
 		} else {
-			ASSERT(is_data == BTRFS_REF_TYPE_ANY);
+			ASSERT(is_data == BTRFS_REF_TYPE_ANY, "is_data=%d", is_data);
 			return type;
 		}
 	}
@@ -2531,8 +2531,10 @@ int btrfs_cross_ref_exist(struct btrfs_inode *inode, u64 offset,
 				struct btrfs_key key;
 
 				btrfs_item_key_to_cpu(leaf, &key, path->slots[0]);
-				ASSERT(key.objectid == bytenr);
-				ASSERT(key.type == BTRFS_EXTENT_ITEM_KEY);
+				ASSERT(key.objectid == bytenr, "key.objectid=%llu",
+				       key.objectid);
+				ASSERT(key.type == BTRFS_EXTENT_ITEM_KEY, "key.type=%u",
+				       key.type);
 			}
 		}
 
@@ -4598,10 +4600,12 @@ static noinline int find_free_extent(struct btrfs_root *root,
 		/* Use dedicated sub-space_info for dedicated block group users. */
 		if (ffe_ctl->for_data_reloc) {
 			space_info = space_info->sub_group[0];
-			ASSERT(space_info->subgroup_id == BTRFS_SUB_GROUP_DATA_RELOC);
+			ASSERT(space_info->subgroup_id == BTRFS_SUB_GROUP_DATA_RELOC,
+			       "space_info->subgroup_id=%d", space_info->subgroup_id);
 		} else if (ffe_ctl->for_treelog) {
 			space_info = space_info->sub_group[0];
-			ASSERT(space_info->subgroup_id == BTRFS_SUB_GROUP_TREELOG);
+			ASSERT(space_info->subgroup_id == BTRFS_SUB_GROUP_TREELOG,
+			       "space_info->subgroup_id=%d", space_info->subgroup_id);
 		}
 	}
 	if (!space_info) {
diff --git a/fs/btrfs/extent_map.c b/fs/btrfs/extent_map.c
index 095a561d733f0c..93a0950293a335 100644
--- a/fs/btrfs/extent_map.c
+++ b/fs/btrfs/extent_map.c
@@ -717,7 +717,7 @@ int btrfs_add_extent_mapping(struct btrfs_inode *inode,
 	 * file offset. Here just do a sanity check.
 	 */
 	if (em->disk_bytenr == EXTENT_MAP_INLINE)
-		ASSERT(em->start == 0);
+		ASSERT(em->start == 0, "em->start=%llu", em->start);
 
 	ret = add_extent_mapping(inode, em, false);
 	/* it is possible that someone inserted the extent into the tree
@@ -761,7 +761,7 @@ int btrfs_add_extent_mapping(struct btrfs_inode *inode,
 		}
 	}
 
-	ASSERT(ret == 0 || ret == -EEXIST);
+	ASSERT(ret == 0 || ret == -EEXIST, "ret=%d", ret);
 	return ret;
 }
 
@@ -943,7 +943,7 @@ void btrfs_drop_extent_map_range(struct btrfs_inode *inode, u64 start, u64 end,
 
 				ret = add_extent_mapping(inode, split, modified);
 				/* Logic error, shouldn't happen. */
-				ASSERT(ret == 0);
+				ASSERT(ret == 0, "ret=%d", ret);
 				if (WARN_ON(ret != 0) && modified)
 					btrfs_set_inode_full_sync(inode);
 			}
diff --git a/fs/btrfs/fiemap.c b/fs/btrfs/fiemap.c
index 27d361c7adc4d8..6263e837093e42 100644
--- a/fs/btrfs/fiemap.c
+++ b/fs/btrfs/fiemap.c
@@ -112,7 +112,7 @@ static int emit_fiemap_extent(struct fiemap_extent_info *fieinfo,
 	u64 cache_end;
 
 	/* Set at the end of extent_fiemap(). */
-	ASSERT((flags & FIEMAP_EXTENT_LAST) == 0);
+	ASSERT((flags & FIEMAP_EXTENT_LAST) == 0, "flags=0x%u", flags);
 
 	if (!cache->cached)
 		goto assign;
diff --git a/fs/btrfs/file-item.c b/fs/btrfs/file-item.c
index d72249390030f4..82ae4a2afd3471 100644
--- a/fs/btrfs/file-item.c
+++ b/fs/btrfs/file-item.c
@@ -325,7 +325,9 @@ static int search_csum_tree(struct btrfs_fs_info *fs_info,
 
 	csum_start = key.offset;
 	csum_len = (itemsize / csum_size) * sectorsize;
-	ASSERT(in_range(disk_bytenr, csum_start, csum_len));
+	ASSERT(in_range(disk_bytenr, csum_start, csum_len),
+	       "disk_bytenr=%llu csum_start=%llu csum_len=%llu",
+	       disk_bytenr, csum_start, csum_len);
 
 found:
 	ret = (min(csum_start + csum_len, disk_bytenr + len) -
diff --git a/fs/btrfs/file.c b/fs/btrfs/file.c
index 06cc6e13cb621f..00318b9e5675d4 100644
--- a/fs/btrfs/file.c
+++ b/fs/btrfs/file.c
@@ -1227,8 +1227,11 @@ static int copy_one_range(struct btrfs_inode *inode, struct iov_iter *iter,
 		return ret;
 	reserved_len = ret;
 	/* Write range must be inside the reserved range. */
-	ASSERT(reserved_start <= start);
-	ASSERT(start + write_bytes <= reserved_start + reserved_len);
+	ASSERT(reserved_start <= start, "reserved_start=%llu start=%llu",
+	       reserved_start, start);
+	ASSERT(start + write_bytes <= reserved_start + reserved_len,
+	       "start=%llu write_bytes=%zu reserved_start=%llu reserved_len=%llu",
+	       start, write_bytes, reserved_start, reserved_len);
 
 again:
 	ret = balance_dirty_pages_ratelimited_flags(inode->vfs_inode.i_mapping,
@@ -2335,7 +2338,8 @@ static int btrfs_insert_replace_extent(struct btrfs_trans_handle *trans,
 			    btrfs_item_ptr_offset(leaf, slot),
 			    sizeof(struct btrfs_file_extent_item));
 	extent = btrfs_item_ptr(leaf, slot, struct btrfs_file_extent_item);
-	ASSERT(btrfs_file_extent_type(leaf, extent) != BTRFS_FILE_EXTENT_INLINE);
+	ASSERT(btrfs_file_extent_type(leaf, extent) != BTRFS_FILE_EXTENT_INLINE,
+	       "file_extent_type=%u", btrfs_file_extent_type(leaf, extent));
 	btrfs_set_file_extent_offset(leaf, extent, extent_info->data_offset);
 	btrfs_set_file_extent_num_bytes(leaf, extent, replace_len);
 	if (extent_info->is_new_extent)
diff --git a/fs/btrfs/ioctl.c b/fs/btrfs/ioctl.c
index b2e447f5005c16..312585d9e1cad0 100644
--- a/fs/btrfs/ioctl.c
+++ b/fs/btrfs/ioctl.c
@@ -5092,7 +5092,8 @@ static int btrfs_ioctl_subvol_sync(struct btrfs_fs_info *fs_info, void __user *a
 			return -ENOENT;
 
 		wait_for_deletion = true;
-		ASSERT(root_flags & BTRFS_ROOT_SUBVOL_DEAD);
+		ASSERT(root_flags & BTRFS_ROOT_SUBVOL_DEAD, "root_flags=0x%llx",
+		       root_flags);
 		sched_ret = schedule_timeout_interruptible(HZ);
 		/* Early wake up or error. */
 		if (sched_ret != 0)
diff --git a/fs/btrfs/ordered-data.c b/fs/btrfs/ordered-data.c
index d39f1c49d1cf8f..8ebd046b79569d 100644
--- a/fs/btrfs/ordered-data.c
+++ b/fs/btrfs/ordered-data.c
@@ -157,7 +157,8 @@ static struct btrfs_ordered_extent *alloc_ordered_extent(
 	       ((1U << BTRFS_ORDERED_NOCOW) | (1U << BTRFS_ORDERED_PREALLOC)));
 
 	/* Only one type flag can be set. */
-	ASSERT(has_single_bit_set(flags & BTRFS_ORDERED_EXCLUSIVE_FLAGS));
+	ASSERT(has_single_bit_set(flags & BTRFS_ORDERED_EXCLUSIVE_FLAGS),
+	       "flags=0x%lx", flags);
 
 	/* DIRECT cannot be set with COMPRESSED nor ENCODED. */
 	if (test_bit(BTRFS_ORDERED_DIRECT, &flags)) {
@@ -302,7 +303,7 @@ struct btrfs_ordered_extent *btrfs_alloc_ordered_extent(
 {
 	struct btrfs_ordered_extent *entry;
 
-	ASSERT((flags & ~BTRFS_ORDERED_TYPE_FLAGS) == 0);
+	ASSERT((flags & ~BTRFS_ORDERED_TYPE_FLAGS) == 0, "flags=0x%lx", flags);
 
 	/*
 	 * For regular writes, we just use the members in @file_extent.
@@ -1238,7 +1239,7 @@ struct btrfs_ordered_extent *btrfs_split_ordered_extent(
 
 	trace_btrfs_ordered_extent_split(inode, ordered);
 
-	ASSERT(!(flags & (1U << BTRFS_ORDERED_COMPRESSED)));
+	ASSERT(!(flags & (1U << BTRFS_ORDERED_COMPRESSED)), "flags=0x%lx", flags);
 
 	/*
 	 * The entire bio must be covered by the ordered extent, but we can't
@@ -1260,7 +1261,7 @@ struct btrfs_ordered_extent *btrfs_split_ordered_extent(
 	}
 	/* We cannot split partially completed ordered extents. */
 	if (ordered->bytes_left) {
-		ASSERT(!(flags & ~BTRFS_ORDERED_TYPE_FLAGS));
+		ASSERT(!(flags & ~BTRFS_ORDERED_TYPE_FLAGS), "flags=0x%lx", flags);
 		if (WARN_ON_ONCE(ordered->bytes_left != ordered->disk_num_bytes))
 			return ERR_PTR(-EINVAL);
 	}
@@ -1307,7 +1308,8 @@ struct btrfs_ordered_extent *btrfs_split_ordered_extent(
 	ordered->ram_bytes -= len;
 
 	if (test_bit(BTRFS_ORDERED_IO_DONE, &ordered->flags)) {
-		ASSERT(ordered->bytes_left == 0);
+		ASSERT(ordered->bytes_left == 0, "ordered->bytes_left=%llu",
+		       ordered->bytes_left);
 		new->bytes_left = 0;
 	} else {
 		ordered->bytes_left -= len;
diff --git a/fs/btrfs/raid-stripe-tree.c b/fs/btrfs/raid-stripe-tree.c
index 638c4ad572c996..03168f9c397e10 100644
--- a/fs/btrfs/raid-stripe-tree.c
+++ b/fs/btrfs/raid-stripe-tree.c
@@ -139,7 +139,8 @@ int btrfs_delete_raid_extent(struct btrfs_trans_handle *trans, u64 start, u64 le
 			btrfs_item_key_to_cpu(leaf, &key, slot);
 			found_start = key.objectid;
 			found_end = found_start + key.offset;
-			ASSERT(found_start <= start);
+			ASSERT(found_start <= start, "found_start=%llu start=%llu",
+			       found_start, start);
 		}
 
 		if (key.type != BTRFS_RAID_STRIPE_KEY)
@@ -239,7 +240,9 @@ int btrfs_delete_raid_extent(struct btrfs_trans_handle *trans, u64 start, u64 le
 			btrfs_partially_delete_raid_extent(trans, path, &key,
 							   key.offset - length,
 							   length);
-			ASSERT(key.offset - diff_end == length);
+			ASSERT(key.offset - diff_end == length,
+			       "key.offset=%llu diff_end=%llu length=%llu",
+			       key.offset, diff_end, length);
 			break;
 		}
 
diff --git a/fs/btrfs/reflink.c b/fs/btrfs/reflink.c
index 49865a46378091..1897816bf7f8db 100644
--- a/fs/btrfs/reflink.c
+++ b/fs/btrfs/reflink.c
@@ -69,7 +69,8 @@ static int copy_inline_to_page(struct btrfs_inode *inode,
 	struct address_space *mapping = inode->vfs_inode.i_mapping;
 	int ret;
 
-	ASSERT(IS_ALIGNED(file_offset, block_size));
+	ASSERT(IS_ALIGNED(file_offset, block_size), "file_offset=%llu block_size=%u",
+	       file_offset, block_size);
 
 	/*
 	 * We have flushed and locked the ranges of the source and destination
@@ -459,7 +460,7 @@ static int btrfs_clone(struct inode *src, struct inode *inode,
 		    key.objectid != btrfs_ino(BTRFS_I(src)))
 			break;
 
-		ASSERT(key.type == BTRFS_EXTENT_DATA_KEY);
+		ASSERT(key.type == BTRFS_EXTENT_DATA_KEY, "key.type=%u", key.type);
 
 		extent = btrfs_item_ptr(leaf, slot,
 					struct btrfs_file_extent_item);
-- 
2.53.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2026-04-07 22:40 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-04-07  3:59 [PATCH] btrfs: make more ASSERTs verbose, part 3 kernel test robot
  -- strict thread matches above, loose matches on Subject: below --
2026-03-31 22:36 David Sterba
2026-04-01 14:24 ` Filipe Manana
2026-04-07 22:40   ` David Sterba

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.