Commit fcfa696b3a354ab1e16601683c61f671487aded7

Authored by Rob Herring
Committed by Albert ARIBAUD
1 parent 995b72ddda

ARM: increase lmb stack space reservation to 4KB

The bootm initrd image copy to ram can collide with the stack in cases
where the print buffer size is large (i.e. 1K). The result is intermittent
initrd decompression errors depending on the initrd size MOD 4KB since
the initrd start address is 4KB aligned.

Cc: Albert ARIBAUD <albert.u.boot@aribaud.net>
Signed-off-by: Rob Herring <rob.herring@calxeda.com>

Showing 1 changed file with 2 additions and 2 deletions Side-by-side Diff

arch/arm/lib/bootm.c
... ... @@ -69,8 +69,8 @@
69 69 sp = get_sp();
70 70 debug("## Current stack ends at 0x%08lx ", sp);
71 71  
72   - /* adjust sp by 1K to be safe */
73   - sp -= 1024;
  72 + /* adjust sp by 4K to be safe */
  73 + sp -= 4096;
74 74 lmb_reserve(lmb, sp,
75 75 gd->bd->bi_dram[0].start + gd->bd->bi_dram[0].size - sp);
76 76 }