aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc
diff options
context:
space:
mode:
Diffstat (limited to 'arch/powerpc')
-rw-r--r--arch/powerpc/lib/rheap.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/powerpc/lib/rheap.c b/arch/powerpc/lib/rheap.c
index 57bf991ccd6e..4bbda6b2be45 100644
--- a/arch/powerpc/lib/rheap.c
+++ b/arch/powerpc/lib/rheap.c
@@ -85,7 +85,8 @@ static int grow(rh_info_t * info, int max_blocks)
85 info->flags &= ~RHIF_STATIC_BLOCK; 85 info->flags &= ~RHIF_STATIC_BLOCK;
86 86
87 /* add all new blocks to the free list */ 87 /* add all new blocks to the free list */
88 for (i = 0, blk = block + info->max_blocks; i < new_blocks; i++, blk++) 88 blk = block + info->max_blocks - new_blocks;
89 for (i = 0; i < new_blocks; i++, blk++)
89 list_add(&blk->list, &info->empty_list); 90 list_add(&blk->list, &info->empty_list);
90 91
91 return 0; 92 return 0;