diff options
author | liangzhen <zhen.liang@spacemit.com> | 2023-10-16 13:47:52 +0800 |
---|---|---|
committer | liangzhen <zhen.liang@spacemit.com> | 2023-10-16 13:47:52 +0800 |
commit | 4dfd2e7b4b6ef3f1dc134d299cc2ea4d2bbadab1 (patch) | |
tree | ba118d19cf517afb88cc6795b7937bd2f7777b94 /debug/gdbserver.py | |
parent | c36c814ae49610bc407a5c4e144866fa50e4510e (diff) | |
download | riscv-tests-4dfd2e7b4b6ef3f1dc134d299cc2ea4d2bbadab1.zip riscv-tests-4dfd2e7b4b6ef3f1dc134d299cc2ea4d2bbadab1.tar.gz riscv-tests-4dfd2e7b4b6ef3f1dc134d299cc2ea4d2bbadab1.tar.bz2 |
Make CLINT address configurable
Signed-off-by: liangzhen <zhen.liang@spacemit.com>
Diffstat (limited to 'debug/gdbserver.py')
-rwxr-xr-x | debug/gdbserver.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/debug/gdbserver.py b/debug/gdbserver.py index 3a6f932..e48b888 100755 --- a/debug/gdbserver.py +++ b/debug/gdbserver.py @@ -912,7 +912,7 @@ class RepeatReadTest(DebugTest): def test(self): self.gdb.b("main:start") self.gdb.c() - mtime_addr = 0x02000000 + 0xbff8 + mtime_addr = self.target.clint_addr + 0xbff8 count = 1024 output = self.gdb.command( f"monitor riscv repeat_read {count} 0x{mtime_addr:x} 4") @@ -1048,8 +1048,8 @@ class InterruptTest(GdbSingleHartTest): def postMortem(self): GdbSingleHartTest.postMortem(self) - self.gdb.p("*((long long*) 0x200bff8)") - self.gdb.p("*((long long*) 0x2004000)") + self.gdb.p(f"*((long long*) 0x{self.target.clint_addr + 0xbff8:x})") + self.gdb.p(f"*((long long*) 0x{self.target.clint_addr + 0x4000:x})") self.gdb.p("interrupt_count") self.gdb.p("local") |