leading_zerosul(): Fix bug

Signed-off-by: Alejandro Colomar <alx@kernel.org>
This commit is contained in:
Alejandro Colomar 2023-01-31 16:47:40 +01:00 committed by Iker Pedrosa
parent 2a61122b5e
commit 03bbe6c418

View File

@ -41,7 +41,7 @@ bit_ceil_wrapul(unsigned long x)
inline int
leading_zerosul(unsigned long x)
{
return (x == 0) ? ULONG_WIDTH : __builtin_clz(x);
return (x == 0) ? ULONG_WIDTH : __builtin_clzl(x);
}