repo.or.cz
/
AROS.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
revert between 56095 -> 55830 in arch
[AROS.git]
/
workbench
/
hidds
/
nouveau
/
drm
/
drm-aros
/
drm_bufs.c
blob
cee4e6ba08bf968294672684080ec32140230d28
1
/*
2
Copyright 2009-2011, The AROS Development Team. All rights reserved.
3
$Id$
4
*/
5
6
#include
"drmP.h"
7
8
int
drm_order
(
unsigned long
size
)
9
{
10
int
order
;
11
unsigned long
tmp
;
12
13
for
(
order
=
0
,
tmp
=
size
>>
1
;
tmp
;
tmp
>>=
1
,
order
++) ;
14
15
if
(
size
& (
size
-
1
))
16
++
order
;
17
18
return
order
;
19
}
20