Re: [Qemu-devel] [PATCH v1] dump: Set correct vaddr for ELF dump

2019-01-08 Thread Laszlo Ersek
On 01/08/19 07:31, Jon Doron wrote: > Thank you for looking into this, perhaps I could change the patch (at > least in the C part not the python script) to something like: > -phdr.p_vaddr = cpu_to_dumpXX(s, memory_mapping->virt_addr); > +phdr.p_vaddr = cpu_to_dumpXX(s, memory_mapping->virt_

Re: [Qemu-devel] [PATCH v1] dump: Set correct vaddr for ELF dump

2019-01-07 Thread Jon Doron
Thank you for looking into this, perhaps I could change the patch (at least in the C part not the python script) to something like: -phdr.p_vaddr = cpu_to_dumpXX(s, memory_mapping->virt_addr); +phdr.p_vaddr = cpu_to_dumpXX(s, memory_mapping->virt_addr) ? cpu_to_dumpXX(s, memory_mapping->vir

Re: [Qemu-devel] [PATCH v1] dump: Set correct vaddr for ELF dump

2019-01-07 Thread Laszlo Ersek
On 01/07/19 13:14, Marc-André Lureau wrote: > Hi > > On Tue, Dec 25, 2018 at 5:52 PM Jon Doron wrote: >> >> vaddr needs to be equal to the paddr since the dump file represents the >> physical memory image. >> >> Without setting vaddr correctly, GDB would load all the different memory >> regions o

Re: [Qemu-devel] [PATCH v1] dump: Set correct vaddr for ELF dump

2019-01-07 Thread Marc-André Lureau
Hi On Tue, Dec 25, 2018 at 5:52 PM Jon Doron wrote: > > vaddr needs to be equal to the paddr since the dump file represents the > physical memory image. > > Without setting vaddr correctly, GDB would load all the different memory > regions on top of each other to vaddr 0, thus making GDB showing

[Qemu-devel] [PATCH v1] dump: Set correct vaddr for ELF dump

2018-12-25 Thread Jon Doron
vaddr needs to be equal to the paddr since the dump file represents the physical memory image. Without setting vaddr correctly, GDB would load all the different memory regions on top of each other to vaddr 0, thus making GDB showing the wrong memory data for a given address. Signed-off-by: Jon Do