Skip to content
Snippets Groups Projects
Commit d59a05a4 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "linux-ramdump-parser-v2: Make page offset a property of the ramdump"

parents 599f3123 46976af8
No related branches found
No related tags found
No related merge requests found
...@@ -432,6 +432,7 @@ class RamDump(): ...@@ -432,6 +432,7 @@ class RamDump():
self.imem_fname = None self.imem_fname = None
self.gdbmi = gdbmi.GdbMI(self.gdb_path, self.vmlinux) self.gdbmi = gdbmi.GdbMI(self.gdb_path, self.vmlinux)
self.gdbmi.open() self.gdbmi.open()
self.page_offset = 0xc0000000
if ebi is not None: if ebi is not None:
# TODO sanity check to make sure the memory regions don't overlap # TODO sanity check to make sure the memory regions don't overlap
for file_path, start, end in ebi: for file_path, start, end in ebi:
...@@ -543,7 +544,7 @@ class RamDump(): ...@@ -543,7 +544,7 @@ class RamDump():
banner_addr = self.addr_lookup('linux_banner') banner_addr = self.addr_lookup('linux_banner')
if banner_addr is not None: if banner_addr is not None:
# Don't try virt to phys yet, compute manually # Don't try virt to phys yet, compute manually
banner_addr = banner_addr - 0xc0000000 + self.phys_offset banner_addr = banner_addr - self.page_offset + self.phys_offset
b = self.read_cstring(banner_addr, 256, False) b = self.read_cstring(banner_addr, 256, False)
if b is None: if b is None:
print_out_str('!!! Could not read banner address!') print_out_str('!!! Could not read banner address!')
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment