OSDN Git Service

ftrace: Simplify the hash calculation
authorSteven Rostedt (VMware) <rostedt@goodmis.org>
Tue, 6 Oct 2020 00:21:14 +0000 (20:21 -0400)
committerSteven Rostedt (VMware) <rostedt@goodmis.org>
Thu, 8 Oct 2020 19:29:06 +0000 (15:29 -0400)
commitbe49313273211c47d1b317d6b2dbe02637c2794c
tree0387632d4bf0911a626e423e6c2abcc445069a55
parent59e65b3358f44d4d0134eca3b6c269f359f21cd5
ftrace: Simplify the hash calculation

No need to add a check to subtract the number of bits if bits is zero after
fls(). Just divide the size by two before calling it. This does give the
same answer for size of 0 and 1, but that's fine.

Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
kernel/trace/ftrace.c