Skip to content
Snippets Groups Projects
Commit fccb8a61 authored by Marcos Paulo de Souza's avatar Marcos Paulo de Souza Committed by Greg Kroah-Hartman
Browse files

btrfs: introduce btrfs_lookup_match_dir


[ Upstream commit a7d1c5dc ]

btrfs_search_slot is called in multiple places in dir-item.c to search
for a dir entry, and then calling btrfs_match_dir_name to return a
btrfs_dir_item.

In order to reduce the number of callers of btrfs_search_slot, create a
common function that looks for the dir key, and if found call
btrfs_match_dir_item_name.

Signed-off-by: default avatarMarcos Paulo de Souza <mpdesouza@suse.com>
Reviewed-by: default avatarDavid Sterba <dsterba@suse.com>
Signed-off-by: default avatarDavid Sterba <dsterba@suse.com>
Stable-dep-of: 8dcbc261 ("btrfs: unify lookup return value when dir entry is missing")
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent aaf2d6b7
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment