Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 140947
b: refs/heads/master
c: d2e8254
h: refs/heads/master
i:
  140945: 72273fc
  140943: 9dd4656
v: v3
  • Loading branch information
Ingo Molnar committed Mar 13, 2009
1 parent f7fb7ef commit 24fd741
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 899039e8746bb9a09b6487ddb8ab2275ce9d0256
refs/heads/master: d2e82546ae98eee353fae57e389f487586fe380d
2 changes: 1 addition & 1 deletion trunk/Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
VERSION = 2
PATCHLEVEL = 6
SUBLEVEL = 29
EXTRAVERSION = -rc7
EXTRAVERSION = -rc8
NAME = Erotic Pickled Herring

# *DOCUMENTATION*
Expand Down
16 changes: 8 additions & 8 deletions trunk/lib/bitmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -948,15 +948,15 @@ static int __reg_op(unsigned long *bitmap, int pos, int order, int reg_op)
*/
int bitmap_find_free_region(unsigned long *bitmap, int bits, int order)
{
int pos; /* scans bitmap by regions of size order */
int pos, end; /* scans bitmap by regions of size order */

for (pos = 0; pos < bits; pos += (1 << order))
if (__reg_op(bitmap, pos, order, REG_OP_ISFREE))
break;
if (pos == bits)
return -ENOMEM;
__reg_op(bitmap, pos, order, REG_OP_ALLOC);
return pos;
for (pos = 0 ; (end = pos + (1 << order)) <= bits; pos = end) {
if (!__reg_op(bitmap, pos, order, REG_OP_ISFREE))
continue;
__reg_op(bitmap, pos, order, REG_OP_ALLOC);
return pos;
}
return -ENOMEM;
}
EXPORT_SYMBOL(bitmap_find_free_region);

Expand Down

0 comments on commit 24fd741

Please sign in to comment.