Skip to content

Commit

Permalink
greybus: tracing: add interface mode_switch
Browse files Browse the repository at this point in the history
Add the value of an interface's mode_switch field to the information
tracked and reported for tracing.

Signed-off-by: Alex Elder <elder@linaro.org>
Reviewed-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
  • Loading branch information
Alex Elder authored and Greg Kroah-Hartman committed Jun 4, 2016
1 parent 14a36ae commit 6879dbf
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions drivers/staging/greybus/greybus_trace.h
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,7 @@ DECLARE_EVENT_CLASS(gb_interface,
__field(int, ejected) /* bool */
__field(int, active) /* bool */
__field(int, enabled) /* bool */
__field(int, mode_switch) /* bool */
),

TP_fast_assign(
Expand All @@ -185,12 +186,13 @@ DECLARE_EVENT_CLASS(gb_interface,
__entry->ejected = intf->ejected;
__entry->active = intf->active;
__entry->enabled = intf->enabled;
__entry->mode_switch = intf->mode_switch;
),

TP_printk("greybus: intf_id=%hhu device_id=%hhu module_id=%hhu D=%d J=%d A=%d E=%d",
TP_printk("greybus: intf_id=%hhu device_id=%hhu module_id=%hhu D=%d J=%d A=%d E=%d M=%d",
__entry->id, __entry->device_id, __entry->module_id,
__entry->disconnected, __entry->ejected, __entry->active,
__entry->enabled)
__entry->enabled, __entry->mode_switch)
);

#define DEFINE_INTERFACE_EVENT(name) \
Expand Down

0 comments on commit 6879dbf

Please sign in to comment.