btrfs: set the lockdep class for log tree extent buffers
authorJosef Bacik <josef@toxicpanda.com>
Mon, 10 Aug 2020 15:42:31 +0000 (11:42 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 9 Sep 2020 17:14:25 +0000 (19:14 +0200)
commit6d12fbd0c4b7bb481f581110cd171a908317d585
treef03562c2b139810b0ef981f0c0f7ea902db27aa0
parent7ad3d8ad569c622746dc613243c1471eeb425e2c
btrfs: set the lockdep class for log tree extent buffers

commit d3beaa253fd6fa40b8b18a216398e6e5376a9d21 upstream.

These are special extent buffers that get rewound in order to lookup
the state of the tree at a specific point in time.  As such they do not
go through the normal initialization paths that set their lockdep class,
so handle them appropriately when they are created and before they are
locked.

CC: stable@vger.kernel.org # 4.4+
Reviewed-by: Filipe Manana <fdmanana@suse.com>
Signed-off-by: Josef Bacik <josef@toxicpanda.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/ctree.c