[coreboot] qemu-armv7: code execution out of RAM or ROM using latest QEMU

Piotr Król pietrushnic at gmail.com
Thu Aug 14 01:51:19 CEST 2014

On Mon, Aug 11, 2014 at 04:00:19PM -0700, ron minnich wrote:

During debugging I found that stack is initialized in range
0x40000-0x7FF00 (using .Stack and .Stack_size).

When coreboot code is executed:

+- armv7_invalidate_caches
  +- icache_invalidate_all
  +- dcache_invalidate_all
    +- dcache_foreach <- here we have ldmia instruction that cause
    execution out of RAM/ROM

I see that SP value change but stack memory dump (x/50x 0x7FE00) show
all 0xffffffff. So my questions are:
- how to check on qemu-system-arm that stack was correctly initialized and
  works fine ? - it looks like instruction like 
  stmdb   sp!, {r0, r1, r4, r5, r6, r7, r9, r10, r11, lr} 
  is unable to dump register values on the stack

- is above range initialized for stack really correct for qemu ? -
  memory map show that in that range flash0 is mapped (for '-bios'
  option), when I memsaved this range I get all 0xffffffff, or maybe I'm
  confusing some different types of memory ?


More information about the coreboot mailing list