Add gdb_setup to target for arbitrary gdb commands
[riscv-tests.git] / debug / testlib.py
index f511088cf53e81c8fb9607db2c7aa3405e6d2b48..c44a763f212837bfe509e941a07d36f303f19d0a 100644 (file)
@@ -622,6 +622,9 @@ class GdbTest(BaseTest):
             thread = random.choice(self.gdb.threads())
             self.gdb.thread(thread)
 
+        for cmd in self.target.gdb_setup:
+            self.gdb.command(cmd)
+
         # FIXME: OpenOCD doesn't handle PRIV now
         #self.gdb.p("$priv=3")