diff options
author | Maciej W. Rozycki <macro@embecosm.com> | 2023-12-12 13:09:54 +0000 |
---|---|---|
committer | Jacob Bachmeyer <jcb@gnu.org> | 2023-12-12 20:45:59 -0600 |
commit | fbdcba42176e9f76c1d9e898347c91abd8b86df1 (patch) | |
tree | 08a0d3359eef3c680584a2cd6a00aa2e7f70c1a9 /config/gdb_stub.exp | |
parent | 34d6720bb9371ad885f8e642a77d869929db15d6 (diff) | |
download | dejagnu-fbdcba42176e9f76c1d9e898347c91abd8b86df1.zip dejagnu-fbdcba42176e9f76c1d9e898347c91abd8b86df1.tar.gz dejagnu-fbdcba42176e9f76c1d9e898347c91abd8b86df1.tar.bz2 |
Use `test_timeout' consistently across protocols
The `test_timeout' global parameter was added with commit 73db65f53795,
however for the `unix' protocol only and then only in the local case.
Update the remote case of the `unix' protocol, other protocols that use
various timeout sources, and the `qemu' board to take any `test_timeout'
setting into account as appropriate. Amend the manual accordingly.
* baseboards/qemu.exp (qemu_load): Respect global `test_timeout'
setting.
* config/gdb-comm.exp (gdb_comm_load): Likewise.
* config/gdb_stub.exp (gdb_stub_load): Likewise.
* config/sim.exp (sim_load): Likewise.
* config/unix.exp (unix_load): Likewise, in the remote case.
* doc/dejagnu.texi (Local configuration file): Update
accordingly.
Diffstat (limited to 'config/gdb_stub.exp')
-rw-r--r-- | config/gdb_stub.exp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/config/gdb_stub.exp b/config/gdb_stub.exp index 6ad22a1..be1369a 100644 --- a/config/gdb_stub.exp +++ b/config/gdb_stub.exp @@ -471,6 +471,7 @@ proc gdb_stub_wait { dest timeout } { } proc gdb_stub_load { dest prog args } { + global test_timeout global gdb_prompt set argnames { "command-line arguments" "input file" "output file" } @@ -480,14 +481,18 @@ proc gdb_stub_load { dest prog args } { } } + set wait_timeout 120 + if {[info exists test_timeout]} { + set wait_timeout $test_timeout + } + set result [remote_spawn $dest $prog] if { $result < 0 } { return [list "fail" "remote_spawn failed"] } - # FIXME: The value 120 should be a parameter. - set result [remote_wait $dest 120] + set result [remote_wait $dest $wait_timeout] set status [lindex $result 0] set output [lindex $result 1] |