* gdb.server/ext-attach.exp: Make sure gdb is disconnected.
* gdb.server/ext-run.exp: Make sure gdb is disconnected.
* gdb.server/file-transfer.exp: Make sure gdb is disconnected.
* gdb.server/server-mon.exp: Make sure gdb is disconnected.
* gdb.server/server-run.exp: Make sure gdb is disconnected.
* lib/gdbserver-support.exp (gdbserver_start_extended): Only
prepend "extended-" to $gdbserver_protocol if $gdbserver_protocol
doesn't start with "extended-" already.
+2012-02-15 Pedro Alves <palves@redhat.com>
+
+ * gdb.server/ext-attach.exp: Make sure gdb is disconnected.
+ * gdb.server/ext-run.exp: Make sure gdb is disconnected.
+ * gdb.server/file-transfer.exp: Make sure gdb is disconnected.
+ * gdb.server/server-mon.exp: Make sure gdb is disconnected.
+ * gdb.server/server-run.exp: Make sure gdb is disconnected.
+ * lib/gdbserver-support.exp (gdbserver_start_extended): Only
+ prepend "extended-" to $gdbserver_protocol if $gdbserver_protocol
+ doesn't start with "extended-" already.
+
2012-02-15 Pedro Alves <palves@redhat.com>
Support extended-remote. Avoid cascading timeouts.
gdb_load $binfile
gdb_reinitialize_dir $srcdir/$subdir
+# Make sure we're disconnected, in case we're testing with an
+# extended-remote board, therefore already connected.
+gdb_test "disconnect" ".*"
+
set target_exec [gdbserver_download_current_prog]
gdbserver_start_extended
gdb_load $binfile
gdb_reinitialize_dir $srcdir/$subdir
+# Make sure we're disconnected, in case we're testing with an
+# extended-remote board, therefore already connected.
+gdb_test "disconnect" ".*"
+
set target_exec [gdbserver_download_current_prog]
gdbserver_start_extended
gdb_load $binfile
gdb_reinitialize_dir $srcdir/$subdir
+# Make sure we're disconnected, in case we're testing with an
+# extended-remote board, therefore already connected.
+gdb_test "disconnect" ".*"
+
gdbserver_run ""
proc test_file_transfer { filename description } {
gdb_load $binfile
gdb_reinitialize_dir $srcdir/$subdir
+# Make sure we're disconnected, in case we're testing with an
+# extended-remote board, therefore already connected.
+gdb_test "disconnect" ".*"
+
gdbserver_run ""
gdb_test_multiple "monitor help" "monitor help" {
gdb_start
gdb_load $binfile
+# Make sure we're disconnected, in case we're testing with an
+# extended-remote board, therefore already connected.
+gdb_test "disconnect" ".*"
+
gdbserver_run ""
gdb_reinitialize_dir $srcdir/$subdir
global use_gdb_stub
set res [gdbserver_start "--multi" ""]
- set gdbserver_protocol "extended-[lindex $res 0]"
+ set gdbserver_protocol [lindex $res 0]
+ if { [string first "extended-" $gdbserver_protocol] != 0} {
+ set gdbserver_protocol "extended-$gdbserver_protocol"
+ }
set gdbserver_gdbport [lindex $res 1]
# Even if the board file is testing with target remote, our caller