diff options
author | Josef Bacik <josef@toxicpanda.com> | 2022-07-26 23:24:03 +0300 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2022-08-17 17:19:10 +0300 |
commit | 0a27a0474d146eb79e09ec88bf0d4229f4cfc1b8 (patch) | |
tree | 8848cdfdbf7f0d95d1d9f1318ca55a7310e96714 /fs/btrfs/locking.h | |
parent | 85f02d6c856b9f3a0acf5219de6e32f58b9778eb (diff) | |
download | linux-0a27a0474d146eb79e09ec88bf0d4229f4cfc1b8.tar.xz |
btrfs: move lockdep class helpers to locking.c
These definitions exist in disk-io.c, which is not related to the
locking. Move this over to locking.h/c where it makes more sense.
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Signed-off-by: Josef Bacik <josef@toxicpanda.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/locking.h')
-rw-r--r-- | fs/btrfs/locking.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/fs/btrfs/locking.h b/fs/btrfs/locking.h index bbc45534ae9a..b21372cab840 100644 --- a/fs/btrfs/locking.h +++ b/fs/btrfs/locking.h @@ -131,4 +131,13 @@ void btrfs_drew_write_unlock(struct btrfs_drew_lock *lock); void btrfs_drew_read_lock(struct btrfs_drew_lock *lock); void btrfs_drew_read_unlock(struct btrfs_drew_lock *lock); +#ifdef CONFIG_DEBUG_LOCK_ALLOC +void btrfs_set_buffer_lockdep_class(u64 objectid, struct extent_buffer *eb, int level); +#else +static inline void btrfs_set_buffer_lockdep_class(u64 objectid, + struct extent_buffer *eb, int level) +{ +} +#endif + #endif |