From 0852c97fec9ca7211a8aef67322a9c38c43d5ef8 Mon Sep 17 00:00:00 2001 From: Filipe Manana Date: Mon, 18 Aug 2025 22:40:20 -0400 Subject: [PATCH] btrfs: send: make fs_path_len() inline and constify its argument [ Upstream commit 920e8ee2bfcaf886fd8c0ad9df097a7dddfeb2d8 ] The helper function fs_path_len() is trivial and doesn't need to change its path argument, so make it inline and constify the argument. Signed-off-by: Filipe Manana Reviewed-by: David Sterba Signed-off-by: David Sterba Signed-off-by: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- fs/btrfs/send.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/btrfs/send.c b/fs/btrfs/send.c index a512e1628dc53..c25eb4416a671 100644 --- a/fs/btrfs/send.c +++ b/fs/btrfs/send.c @@ -478,7 +478,7 @@ static void fs_path_free(struct fs_path *p) kfree(p); } -static int fs_path_len(struct fs_path *p) +static inline int fs_path_len(const struct fs_path *p) { return p->end - p->start; } -- 2.47.3