Sign in
nest-open-source
/
nest-learning-thermostat
/
5.5.1
/
linux-imx
/
1ba0449cae3331dce0ca0dedb32ae64e4ff99bd0
/
.
/
drivers
/
gpu
/
drm
/
nouveau
/
core
/
include
/
core
/
math.h
blob: f808131c5cd87e6077800b7ab08eb0d779cdec95 [
file
] [
log
] [
blame
]
#ifndef
__NOUVEAU_MATH_H__
#define
__NOUVEAU_MATH_H__
static
inline
int
log2i
(
u64
base
)
{
u64 temp
=
base
>>
1
;
int
log2
;
for
(
log2
=
0
;
temp
;
log2
++,
temp
>>=
1
)
{
}
return
(
base
&
(
base
-
1
))
?
log2
+
1
:
log2
;
}
#endif