aboutsummaryrefslogtreecommitdiff
path: root/gdb/target.h
diff options
context:
space:
mode:
authorVladimir Prus <vladimir@codesourcery.com>2008-08-19 13:22:14 +0000
committerVladimir Prus <vladimir@codesourcery.com>2008-08-19 13:22:14 +0000
commit9908b56683c3fce81b58ff5ee888741790f516d0 (patch)
tree05b062f89b7a634c46c5830d54824e00df366c40 /gdb/target.h
parentc6ebd6cf9956565b8b2c3e14a54dea6c467f48d4 (diff)
downloadgdb-9908b56683c3fce81b58ff5ee888741790f516d0.zip
gdb-9908b56683c3fce81b58ff5ee888741790f516d0.tar.gz
gdb-9908b56683c3fce81b58ff5ee888741790f516d0.tar.bz2
Make sure target supports non-stop.
* infcmd.c (run_command_1, attach_command): If non-stop mode is requested, verify the target supports it. * linux-nat.c (linux_nat_supports_non_stop): New. (linux_nat_add_target): Register the above. * target.c (find_default_supports_non_stop) (target_supports_non_stop): New. (init_dummy_target): Register find_default_supports_non_stop. * target.h (struct target_ops): New field to_supports_non_stop. (target_supports_non_stop): New.
Diffstat (limited to 'gdb/target.h')
-rw-r--r--gdb/target.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/gdb/target.h b/gdb/target.h
index 350a7c4..067c031 100644
--- a/gdb/target.h
+++ b/gdb/target.h
@@ -422,6 +422,7 @@ struct target_ops
int (*to_is_async_p) (void);
void (*to_async) (void (*) (enum inferior_event_type, void *), void *);
int (*to_async_mask) (int);
+ int (*to_supports_non_stop) (void);
int (*to_find_memory_regions) (int (*) (CORE_ADDR,
unsigned long,
int, int, int,
@@ -966,6 +967,8 @@ extern int target_async_permitted;
/* Is the target in asynchronous execution mode? */
#define target_is_async_p() (current_target.to_is_async_p ())
+int target_supports_non_stop (void);
+
/* Put the target in async mode with the specified callback function. */
#define target_async(CALLBACK,CONTEXT) \
(current_target.to_async ((CALLBACK), (CONTEXT)))