diff options
author | Alon Levy <alevy@redhat.com> | 2012-09-04 12:37:14 +0300 |
---|---|---|
committer | Alon Levy <alevy@redhat.com> | 2012-09-04 12:37:24 +0300 |
commit | bded52d5d343281ffb06761397cdecf6623020b0 (patch) | |
tree | 146bb83287bad3d844a8fd4ff89d659277732979 | |
parent | 2eb1fa89ac3c327074a71f9ee93cbf9a05f94b65 (diff) |
(wip) add red_dtrace.dwip/dtrace
-rw-r--r-- | server/Makefile.am | 8 | ||||
-rw-r--r-- | server/red_dtrace.d | 3 | ||||
-rw-r--r-- | server/red_worker.c | 4 |
3 files changed, 15 insertions, 0 deletions
diff --git a/server/Makefile.am b/server/Makefile.am index 18a9d8a7..d6438544 100644 --- a/server/Makefile.am +++ b/server/Makefile.am @@ -91,8 +91,16 @@ libspice_server_la_SOURCES = \ spicevmc.c \ zlib_encoder.c \ zlib_encoder.h \ + red_dtrace.d \ + red_dtrace.h \ $(NULL) +.d.o: + libtool --mode=compile --tag=CC dtrace -o $@ -G -s $< + +.d.h: + dtrace -o $@ -h -s $< + if SUPPORT_TUNNEL libspice_server_la_SOURCES += \ red_tunnel_worker.c \ diff --git a/server/red_dtrace.d b/server/red_dtrace.d new file mode 100644 index 00000000..f0ea8408 --- /dev/null +++ b/server/red_dtrace.d @@ -0,0 +1,3 @@ +provider spice_server { + probe red_marshall_monitors_config(MonitorsConfig *monitors_config); +}; diff --git a/server/red_worker.c b/server/red_worker.c index eee9915d..40591c31 100644 --- a/server/red_worker.c +++ b/server/red_worker.c @@ -81,6 +81,8 @@ #include "main_channel.h" #include "migration_protocol.h" +#include "red_dtrace.h" + //#define COMPRESS_STAT //#define DUMP_BITMAP //#define PIPE_DEBUG @@ -8849,6 +8851,8 @@ static void red_marshall_monitors_config(RedChannelClient *rcc, SpiceMarshaller SpiceMsgDisplayMonitorsConfig *msg = spice_malloc0(sizeof(*msg) + heads_size); int count = 0; // ignore monitors_config->count, it may contain zero width monitors, remove them now + SPICE_SERVER_RED_MARSHALL_MONITORS_CONFIG(monitors_config); + red_channel_client_init_send_data(rcc, SPICE_MSG_DISPLAY_MONITORS_CONFIG, NULL); for (i = 0 ; i < monitors_config->count; ++i) { if (monitors_config->heads[i].width == 0 || monitors_config->heads[i].height == 0) { |