hyper-v: trace vmbus_request_offers()

Add tracepoint to CHANNELMSG_REQUESTOFFERS sender.

Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com>
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Vitaly Kuznetsov 2017-10-29 12:21:08 -07:00 committed by Greg Kroah-Hartman
parent c7924fb07a
commit d6706e6336
2 changed files with 11 additions and 1 deletions

View File

@ -1224,9 +1224,11 @@ int vmbus_request_offers(void)
msg->msgtype = CHANNELMSG_REQUESTOFFERS; msg->msgtype = CHANNELMSG_REQUESTOFFERS;
ret = vmbus_post_msg(msg, sizeof(struct vmbus_channel_message_header), ret = vmbus_post_msg(msg, sizeof(struct vmbus_channel_message_header),
true); true);
trace_vmbus_request_offers(ret);
if (ret != 0) { if (ret != 0) {
pr_err("Unable to request offers - %d\n", ret); pr_err("Unable to request offers - %d\n", ret);

View File

@ -122,6 +122,14 @@ TRACE_EVENT(vmbus_onversion_response,
TP_printk("version_supported %d", __entry->ver) TP_printk("version_supported %d", __entry->ver)
); );
TRACE_EVENT(vmbus_request_offers,
TP_PROTO(int ret),
TP_ARGS(ret),
TP_STRUCT__entry(__field(int, ret)),
TP_fast_assign(__entry->ret = ret),
TP_printk("sending ret %d", __entry->ret)
);
#undef TRACE_INCLUDE_PATH #undef TRACE_INCLUDE_PATH
#define TRACE_INCLUDE_PATH . #define TRACE_INCLUDE_PATH .
#undef TRACE_INCLUDE_FILE #undef TRACE_INCLUDE_FILE