Commit c65fdf03 authored by Alex Elder's avatar Alex Elder Committed by Greg Kroah-Hartman

greybus: tracing: fix module num_interfaces

A module's num_interfaces field is included in the data to be
recorded for tracing, but it's never assigned or reported.  Fix
its type to be size_t, to match its definition in the gb_module
structure.

Also correct a format length modifier used for a host device's
num_cports field.
Signed-off-by: default avatarAlex Elder <elder@linaro.org>
Reviewed-by: default avatarViresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@google.com>
parent 1ea3ed54
......@@ -250,18 +250,20 @@ DECLARE_EVENT_CLASS(gb_module,
TP_STRUCT__entry(
__field(int, hd_bus_id)
__field(u8, module_id)
__field(u8, num_interfaces)
__field(size_t, num_interfaces)
__field(int, disconnected) /* bool */
),
TP_fast_assign(
__entry->hd_bus_id = module->hd->bus_id;
__entry->module_id = module->module_id;
__entry->num_interfaces = module->num_interfaces;
__entry->disconnected = module->disconnected;
),
TP_printk("greybus: hd_bus_id=%d module_id=%hhu disconnected=%d",
__entry->hd_bus_id, __entry->module_id, __entry->disconnected)
TP_printk("greybus: hd_bus_id=%d module_id=%hhu num_interfaces=%zu disconnected=%d",
__entry->hd_bus_id, __entry->module_id,
__entry->num_interfaces, __entry->disconnected)
);
#define DEFINE_MODULE_EVENT(name) \
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment