Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 56592
b: refs/heads/master
c: 1c2de47
h: refs/heads/master
v: v3
  • Loading branch information
Timur Tabi authored and Paul Mackerras committed May 17, 2007
1 parent fb20c33 commit 8280edc
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 15 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: 991eb43af989002d5c7f4a2ff2a6c806a912b51b
refs/heads/master: 1c2de47cd47daa033251dbb4a3643e7e87a681b0
22 changes: 8 additions & 14 deletions trunk/arch/powerpc/lib/rheap.c
Original file line number Diff line number Diff line change
Expand Up @@ -468,25 +468,19 @@ unsigned long rh_alloc_align(rh_info_t * info, int size, int alignment, const ch
if (blk->size == size) {
/* Move from free list to taken list */
list_del(&blk->list);
blk->owner = owner;
start = blk->start;

attach_taken_block(info, blk);
newblk = blk;
} else {
newblk = get_slot(info);
newblk->start = blk->start;
newblk->size = size;

return start;
/* blk still in free list, with updated start, size */
blk->start += size;
blk->size -= size;
}

newblk = get_slot(info);
newblk->start = blk->start;
newblk->size = size;
newblk->owner = owner;

/* blk still in free list, with updated start, size */
blk->start += size;
blk->size -= size;

start = newblk->start;

attach_taken_block(info, newblk);

/* for larger alignment return fixed up pointer */
Expand Down

0 comments on commit 8280edc

Please sign in to comment.