diff mbox

[6/6] btrfs: teach print_leaf about temporary item subtypes

Message ID 9f07e1d76eaeeddedcf9651395b4a8f870df31f0.1455209994.git.dsterba@suse.com (mailing list archive)
State Accepted
Headers show

Commit Message

David Sterba Feb. 11, 2016, 5:23 p.m. UTC
Signed-off-by: David Sterba <dsterba@suse.com>
---
 fs/btrfs/print-tree.c | 11 +++++++++++
 1 file changed, 11 insertions(+)
diff mbox

Patch

diff --git a/fs/btrfs/print-tree.c b/fs/btrfs/print-tree.c
index 7bd0bdfc9812..147dc6ca5de1 100644
--- a/fs/btrfs/print-tree.c
+++ b/fs/btrfs/print-tree.c
@@ -306,6 +306,17 @@  void btrfs_print_leaf(struct btrfs_root *root, struct extent_buffer *l)
 				printk(KERN_INFO "\t\tunknown persistent item\n");
 			}
 			break;
+		case BTRFS_TEMPORARY_ITEM_KEY:
+			printk(KERN_INFO "\t\ttemporary item objectid %llu offset %llu\n",
+					key.objectid, key.offset);
+			switch (key.objectid) {
+			case BTRFS_BALANCE_OBJECTID:
+				printk(KERN_INFO "\t\tbalance status\n");
+				break;
+			default:
+				printk(KERN_INFO "\t\tunknown temporary item\n");
+			}
+			break;
 		case BTRFS_DEV_REPLACE_KEY:
 			printk(KERN_INFO "\t\tdev replace\n");
 			break;