aboutsummaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
Diffstat (limited to 'config')
-rw-r--r--config/gdb-comm.exp5
-rw-r--r--config/gdb_stub.exp9
-rw-r--r--config/sim.exp4
-rw-r--r--config/unix.exp2
4 files changed, 15 insertions, 5 deletions
diff --git a/config/gdb-comm.exp b/config/gdb-comm.exp
index 909bb69..21893dc 100644
--- a/config/gdb-comm.exp
+++ b/config/gdb-comm.exp
@@ -253,7 +253,7 @@ proc gdb_comm_load { dest prog args } {
global GDB
global GDBFLAGS
global gdb_prompt
- global timeout
+ global test_timeout
set argnames { "command-line arguments" "input file" "output file" }
for { set x 0 } { $x < [llength $args] } { incr x } {
@@ -267,9 +267,10 @@ proc gdb_comm_load { dest prog args } {
return [list "untested" ""]
}
- # FIXME: The value 300 below should be a parameter.
if {[board_info $dest exists testcase_timeout]} {
set testcase_timeout [board_info $dest testcase_timeout]
+ } elseif {[info exists test_timeout]} {
+ set testcase_timeout $test_timeout
} else {
set testcase_timeout 300
}
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]
diff --git a/config/sim.exp b/config/sim.exp
index 520a2c0..ed5f67b 100644
--- a/config/sim.exp
+++ b/config/sim.exp
@@ -60,6 +60,8 @@ proc sim_wait { dest timeout } {
}
proc sim_load { dest prog args } {
+ global test_timeout
+
set inpfile ""
if { [llength $args] > 1 } {
if { [lindex $args 1] ne "" } {
@@ -75,6 +77,8 @@ proc sim_load { dest prog args } {
if {[board_info $dest exists sim_time_limit]} {
set sim_time_limit [board_info $dest sim_time_limit]
+ } elseif {[info exists test_timeout]} {
+ set sim_time_limit $test_timeout
} else {
set sim_time_limit 240
}
diff --git a/config/unix.exp b/config/unix.exp
index a3b1a10..b359b8b 100644
--- a/config/unix.exp
+++ b/config/unix.exp
@@ -133,7 +133,7 @@ proc unix_load { dest prog args } {
set remotecmd "$remotefile"
}
- set status [remote_exec $dest $remotefile $parg $inp]
+ set status [remote_exec $dest $remotefile $parg $inp "" $wait_timeout]
remote_file $dest delete $remotefile.o $remotefile
if { [lindex $status 0] < 0 } {
verbose -log "Couldn't execute $prog, [lindex $status 1]" 3