Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit bdee8b28 authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman
Browse files

Revert "btrfs: add dmesg output for first mount and last unmount of a filesystem"

This reverts commit dd94ffab which is
commit 2db313205f8b96eea467691917138d646bb50aef upstream.

As pointed out by many, the disk_super structure is NOT initialized
before it is dereferenced in the function
fs/btrfs/disk-io.c:open_ctree() that this commit adds, so something went
wrong here.

Revert it for now until it gets straightened out.

Link: https://lore.kernel.org/r/5b0eb360-3765-40e1-854a-9da6d97eb405@roeck-us.net
Link: https://lore.kernel.org/r/20231209172836.GA2154579@dev-arch.thelio-3990X


Reported-by: default avatarGuenter Roeck <linux@roeck-us.net>
Reported-by: default avatarNathan Chancellor <nathan@kernel.org>
Cc: Anand Jain <anand.jain@oracle.com>
Cc: Qu Wenruo <wqu@suse.com>
Cc: David Sterba <dsterba@suse.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent dd9e8519
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -2829,7 +2829,6 @@ int open_ctree(struct super_block *sb,
		goto fail_alloc;
	}

	btrfs_info(fs_info, "first mount of filesystem %pU", disk_super->fsid);
	/*
	 * Verify the type first, if that or the checksum value are
	 * corrupted, we'll find out
+1 −4
Original line number Diff line number Diff line
@@ -291,10 +291,7 @@ void __btrfs_panic(struct btrfs_fs_info *fs_info, const char *function,

static void btrfs_put_super(struct super_block *sb)
{
	struct btrfs_fs_info *fs_info = btrfs_sb(sb);

	btrfs_info(fs_info, "last unmount of filesystem %pU", fs_info->fs_devices->fsid);
	close_ctree(fs_info);
	close_ctree(btrfs_sb(sb));
}

enum {