From ecae04e1df45d8ea47f700fde6cb1782c143f5d1 Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Tue, 17 Dec 2013 21:39:36 -0700 Subject: [PATCH] Add target_ops argument to to_trace_init 2014-02-19 Tom Tromey * target.h (struct target_ops) : Add argument. (target_trace_init): Add argument. * target.c (update_current_target): Update. * remote.c (remote_trace_init): Add 'self' argument. --- gdb/ChangeLog | 7 +++++++ gdb/remote.c | 2 +- gdb/target.c | 2 +- gdb/target.h | 4 ++-- 4 files changed, 11 insertions(+), 4 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index a15a8f3f7d..33394b271d 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,10 @@ +2014-02-19 Tom Tromey + + * target.h (struct target_ops) : Add argument. + (target_trace_init): Add argument. + * target.c (update_current_target): Update. + * remote.c (remote_trace_init): Add 'self' argument. + 2014-02-19 Tom Tromey * target.h (struct target_ops) : Add argument. diff --git a/gdb/remote.c b/gdb/remote.c index 866c5c00f9..0e12567c38 100644 --- a/gdb/remote.c +++ b/gdb/remote.c @@ -10326,7 +10326,7 @@ remote_can_run_breakpoint_commands (struct target_ops *self) } static void -remote_trace_init (void) +remote_trace_init (struct target_ops *self) { putpkt ("QTinit"); remote_get_noisy_reply (&target_buf, &target_buf_size); diff --git a/gdb/target.c b/gdb/target.c index a4c04194e7..b34ef9c407 100644 --- a/gdb/target.c +++ b/gdb/target.c @@ -849,7 +849,7 @@ update_current_target (void) (int (*) (struct target_ops *)) return_zero); de_fault (to_trace_init, - (void (*) (void)) + (void (*) (struct target_ops *)) tcomplain); de_fault (to_download_tracepoint, (void (*) (struct bp_location *)) diff --git a/gdb/target.h b/gdb/target.h index 626da3e4a5..76d2a8a76c 100644 --- a/gdb/target.h +++ b/gdb/target.h @@ -756,7 +756,7 @@ struct target_ops /* Tracepoint-related operations. */ /* Prepare the target for a tracing run. */ - void (*to_trace_init) (void); + void (*to_trace_init) (struct target_ops *); /* Send full details of a tracepoint location to the target. */ void (*to_download_tracepoint) (struct bp_location *location); @@ -1781,7 +1781,7 @@ extern char *target_fileio_read_stralloc (const char *filename); /* Tracepoint-related operations. */ #define target_trace_init() \ - (*current_target.to_trace_init) () + (*current_target.to_trace_init) (¤t_target) #define target_download_tracepoint(t) \ (*current_target.to_download_tracepoint) (t) -- 2.34.1