]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
btrfs: output the reason for open_ctree() failure
authorQu Wenruo <wqu@suse.com>
Tue, 10 Dec 2024 04:53:06 +0000 (15:23 +1030)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 13 Mar 2025 11:50:16 +0000 (12:50 +0100)
commit51bcf530c6dc8699fafadc0255e6dae2156e0f5e
treee77f1c00ba8c787b0893cca809a3b7ceb76c9ce6
parentbbb7f49839b57d66ccaf7b5752d9b63d3031dd0a
btrfs: output the reason for open_ctree() failure

commit d0f038104fa37380e2a725e669508e43d0c503e9 upstream.

There is a recent ML report that mounting a large fs backed by hardware
RAID56 controller (with one device missing) took too much time, and
systemd seems to kill the mount attempt.

In that case, the only error message is:

  BTRFS error (device sdj): open_ctree failed

There is no reason on why the failure happened, making it very hard to
understand the reason.

At least output the error number (in the particular case it should be
-EINTR) to provide some clue.

Link: https://lore.kernel.org/linux-btrfs/9b9c4d2810abcca2f9f76e32220ed9a90febb235.camel@scientia.org/
Reported-by: Christoph Anton Mitterer <calestyo@scientia.org>
Cc: stable@vger.kernel.org
Reviewed-by: Filipe Manana <fdmanana@suse.com>
Signed-off-by: Qu Wenruo <wqu@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/btrfs/super.c