]> www.infradead.org Git - users/jedix/linux-maple.git/commit
vfs: link_path_walk: clarify and improve name hashing interface
authorLinus Torvalds <torvalds@linux-foundation.org>
Sun, 16 Jun 2024 17:38:35 +0000 (10:38 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 19 Jun 2024 19:35:57 +0000 (12:35 -0700)
commit631e1a710c0489e083d4f1276f6de787a5cf08fb
tree5d6b9ba7c68308d94a5e9e7e0e65822169aa63f0
parent7d286849a8de41c1aee2957e224c5802d3488c8d
vfs: link_path_walk: clarify and improve name hashing interface

Now that we clearly only care about the length of the name we just
parsed, we can simplify and clarify the interface to "name_hash()", and
move the actual nd->last field setting in there.

That makes everything simpler, and this way don't mix the hash and the
length together only to then immediately unmix them again.

We still eventually want the combined mixed "hashlen" for when we look
things up in the dentry cache, but inside link_path_walk() it's simpler
and clearer to just deal with the path component length.

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/namei.c