summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/task-analyzer.py
diff options
context:
space:
mode:
authorLeo Martins <loemra.dev@gmail.com>2024-08-30 23:24:55 +0300
committerDavid Sterba <dsterba@suse.com>2024-11-11 16:34:22 +0300
commit7c855e16ab72596d771355050ffe026e6b99f91c (patch)
treeed2808ca1dfe8f627548f271ab5cfe6d07db20f7 /tools/perf/scripts/python/task-analyzer.py
parent69673992b1aea5540199d9b8b658ede72f55a6cf (diff)
downloadlinux-7c855e16ab72596d771355050ffe026e6b99f91c.tar.xz
btrfs: remove conditional path allocation in btrfs_read_locked_inode()
Remove conditional path allocation from btrfs_read_locked_inode(). Add an ASSERT(path) to indicate it should never be called with a NULL path. Call btrfs_read_locked_inode() directly from btrfs_iget(). This causes code duplication between btrfs_iget() and btrfs_iget_path(), but I think this is justifiable as it removes the need for conditionally allocating the path inside of btrfs_read_locked_inode(). This makes the code easier to reason about and makes it clear who has the responsibility of allocating and freeing the path. Signed-off-by: Leo Martins <loemra.dev@gmail.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'tools/perf/scripts/python/task-analyzer.py')
0 files changed, 0 insertions, 0 deletions