Blame SOURCES/gdb-dlopen-stap-probe-6of9.patch

861f93
http://sourceware.org/ml/gdb-cvs/2013-06/msg00017.html
861f93
861f93
### src/gdb/ChangeLog	2013/06/04 13:02:15	1.15683
861f93
### src/gdb/ChangeLog	2013/06/04 13:10:53	1.15684
861f93
## -1,5 +1,21 @@
861f93
 2013-06-04  Gary Benson  <gbenson@redhat.com>
861f93
 
861f93
+	* target.h (target_ops): New field
861f93
+	"to_augmented_libraries_svr4_read".
861f93
+	(target_augmented_libraries_svr4_read): New macro.
861f93
+	* target.c (update_current_target): Handle
861f93
+	to_augmented_libraries_svr4_read.
861f93
+	* remote.c (remote_state): New field
861f93
+	"augmented_libraries_svr4_read".
861f93
+	(remote_augmented_libraries_svr4_read_feature): New function.
861f93
+	(remote_protocol_features): Add entry for
861f93
+	"augmented-libraries-svr4-read".
861f93
+	(remote_augmented_libraries_svr4_read): New function.
861f93
+	(init_remote_ops): Initialize
861f93
+	remote_ops.to_augmented_libraries_svr4_read.
861f93
+
861f93
+2013-06-04  Gary Benson  <gbenson@redhat.com>
861f93
+
861f93
 	* NEWS: Update.
861f93
 
861f93
 2013-06-04  Gary Benson  <gbenson@redhat.com>
861f93
--- src/gdb/remote.c	2013/05/30 09:29:18	1.552
861f93
+++ src/gdb/remote.c	2013/06/04 13:10:53	1.553
861f93
@@ -361,6 +361,10 @@
861f93
   /* True if the stub can collect strings using tracenz bytecode.  */
861f93
   int string_tracing;
861f93
 
861f93
+  /* True if the stub supports qXfer:libraries-svr4:read with a
861f93
+     non-empty annex.  */
861f93
+  int augmented_libraries_svr4_read;
861f93
+
861f93
   /* Nonzero if the user has pressed Ctrl-C, but the target hasn't
861f93
      responded to that.  */
861f93
   int ctrlc_pending_p;
861f93
@@ -3949,6 +3953,16 @@
861f93
   rs->string_tracing = (support == PACKET_ENABLE);
861f93
 }
861f93
 
861f93
+static void
861f93
+remote_augmented_libraries_svr4_read_feature
861f93
+  (const struct protocol_feature *feature,
861f93
+   enum packet_support support, const char *value)
861f93
+{
861f93
+  struct remote_state *rs = get_remote_state ();
861f93
+
861f93
+  rs->augmented_libraries_svr4_read = (support == PACKET_ENABLE);
861f93
+}
861f93
+
861f93
 static struct protocol_feature remote_protocol_features[] = {
861f93
   { "PacketSize", PACKET_DISABLE, remote_packet_size, -1 },
861f93
   { "qXfer:auxv:read", PACKET_DISABLE, remote_supported_packet,
861f93
@@ -3959,6 +3973,8 @@
861f93
     PACKET_qXfer_libraries },
861f93
   { "qXfer:libraries-svr4:read", PACKET_DISABLE, remote_supported_packet,
861f93
     PACKET_qXfer_libraries_svr4 },
861f93
+  { "augmented-libraries-svr4-read", PACKET_DISABLE,
861f93
+    remote_augmented_libraries_svr4_read_feature, -1 },
861f93
   { "qXfer:memory-map:read", PACKET_DISABLE, remote_supported_packet,
861f93
     PACKET_qXfer_memory_map },
861f93
   { "qXfer:spu:read", PACKET_DISABLE, remote_supported_packet,
861f93
@@ -11439,6 +11455,14 @@
861f93
   return btrace;
861f93
 }
861f93
 
861f93
+static int
861f93
+remote_augmented_libraries_svr4_read (void)
861f93
+{
861f93
+  struct remote_state *rs = get_remote_state ();
861f93
+
861f93
+  return rs->augmented_libraries_svr4_read;
861f93
+}
861f93
+
861f93
 static void
861f93
 init_remote_ops (void)
861f93
 {
861f93
@@ -11561,6 +11585,8 @@
861f93
   remote_ops.to_disable_btrace = remote_disable_btrace;
861f93
   remote_ops.to_teardown_btrace = remote_teardown_btrace;
861f93
   remote_ops.to_read_btrace = remote_read_btrace;
861f93
+  remote_ops.to_augmented_libraries_svr4_read =
861f93
+    remote_augmented_libraries_svr4_read;
861f93
 }
861f93
 
861f93
 /* Set up the extended remote vector by making a copy of the standard
861f93
--- src/gdb/target.c	2013/05/14 20:33:36	1.335
861f93
+++ src/gdb/target.c	2013/06/04 13:10:53	1.336
861f93
@@ -731,6 +731,7 @@
861f93
       INHERIT (to_traceframe_info, t);
861f93
       INHERIT (to_use_agent, t);
861f93
       INHERIT (to_can_use_agent, t);
861f93
+      INHERIT (to_augmented_libraries_svr4_read, t);
861f93
       INHERIT (to_magic, t);
861f93
       INHERIT (to_supports_evaluation_of_breakpoint_conditions, t);
861f93
       INHERIT (to_can_run_breakpoint_commands, t);
861f93
@@ -975,6 +976,9 @@
861f93
   de_fault (to_can_use_agent,
861f93
 	    (int (*) (void))
861f93
 	    return_zero);
861f93
+  de_fault (to_augmented_libraries_svr4_read,
861f93
+	    (int (*) (void))
861f93
+	    return_zero);
861f93
   de_fault (to_execution_direction, default_execution_direction);
861f93
 
861f93
 #undef de_fault
861f93
--- src/gdb/target.h	2013/05/14 20:33:36	1.262
861f93
+++ src/gdb/target.h	2013/06/04 13:10:53	1.263
861f93
@@ -941,6 +941,10 @@
861f93
        (inclusive) to function END (exclusive).  */
861f93
     void (*to_call_history_range) (ULONGEST begin, ULONGEST end, int flags);
861f93
 
861f93
+    /* Nonzero if TARGET_OBJECT_LIBRARIES_SVR4 may be read with a
861f93
+       non-empty annex.  */
861f93
+    int (*to_augmented_libraries_svr4_read) (void);
861f93
+
861f93
     int to_magic;
861f93
     /* Need sub-structure for target machine related rather than comm related?
861f93
      */
861f93
@@ -1809,6 +1813,9 @@
861f93
 #define target_can_use_agent() \
861f93
   (*current_target.to_can_use_agent) ()
861f93
 
861f93
+#define target_augmented_libraries_svr4_read() \
861f93
+  (*current_target.to_augmented_libraries_svr4_read) ()
861f93
+
861f93
 /* Command logging facility.  */
861f93
 
861f93
 #define target_log_command(p)						\